Ragna.roBrowser icon indicating copy to clipboard operation
Ragna.roBrowser copied to clipboard

Rendering order

Open MrAntares opened this issue 3 years ago • 7 comments

Effects should be ordered based on their distance to the camera and rendered from back to front, so that transparent effects can be rendered properly.

Same story with sky, water, sprites+sprite effects (entities) and effects. Since all of these rendered separately there should be something like a global rendering queue ordered by distance or something else clever. Right now there is a fixed order, but this doesn't work when there is transparent water + transparent sprite + transparent effect on top of each other. All of them should add together in transparency even if they are placed in reverse order from how they are rendered. Now in this case the first to render cuts out the later ones if they are behind it.

The solution shouldn't be resource intensive!

MrAntares avatar Feb 18 '22 11:02 MrAntares

It is also an issue in the new Sight and Runwatch effects... ..Annoying as hell

MrAntares avatar Feb 22 '22 09:02 MrAntares

Hey,

How is the progress with hardcoded effects? :)

juliolitwin avatar Feb 25 '22 17:02 juliolitwin

Hi! It is slowly coming together :) With the added base renderers i added it is more of a configuration and source finding issue.

The latest addition is also a new effect that uses this method :) https://github.com/MrAntares/Ragna.roBrowser/commit/b0ebc61e2f10954319cfc80e51a3e07406a40171

My biggest issue is finding all the resources and matching them to affects and matching the effects to skill. Today I have refactored the skill->effect mapping and it became relatively easy to see through all of it. Because of this I added a ton of effects that were already implemented, but not mapped.

If you enjoy tinkering with these things, feel free to fork this repository and add some things, just don't forget to push back haha :D

MrAntares avatar Feb 25 '22 18:02 MrAntares

Sorry for the delay in responding!

Amazing, I also considered the idea of being able to use some configuration file for hardcoded effects, but I believe that there are some effects that are out of the box, unfortunately.

I wish I could contribute, but unfortunately JS is not my strong, which is why I have my own project at Unity. x) I believe you were the one who came the furthest with the hardcoded effects.

But anyway, we can try to find a solution where we can contribute to each other's effects, where it can be reused.

I was trying to get the file information by REGEX, but it turned out to be spaghetti, so maybe the best thing is to develop a simple parser/token to read the .cpp/.h, so you don't have to do manual work .

Cheers!

juliolitwin avatar Feb 28 '22 18:02 juliolitwin

On my part, the most needed things are:

  • A complete effect table/list with effect IDs, what source files it uses (bmp,tga,spr,str), what sounds it uses (wav)
  • A complete skill<-effect and item<-effect mapping table/list

If it helps in your project, feel free to use the incomplete tables I expanded: https://github.com/MrAntares/Ragna.roBrowser/blob/master/src/DB/Effects/EffectTable.js https://github.com/MrAntares/Ragna.roBrowser/blob/master/src/DB/Skills/SkillEffect.js https://github.com/MrAntares/Ragna.roBrowser/blob/master/src/DB/Items/ItemEffect.js

My biggest problem is that in many cases I have to listen all the sunds all over again and again to figure out which sound is which, because even the english names are completely different from their actual use. For example wl_jackfrost.wav is actually not used in the Jackfrost skill, but in Diamond Dust and Ignition Break. I am starting to get sick of all the noises and explosions hearing them all over and over again just to find one sound :D My biggest advantage is that on our server I had a character in every class even before I started the development and I leveled them all, so I remember to many sounds and effects perfectly, but is is still a huge pain in the ass. Not to mention that I have to translate korean file names, convert them to hex and put them in the table manually, which is a huge waster of time. Sometimes I only have the Latin1 encoded gibberish filename, which I have to convert into hex, convert again into EUC-KR codepage, and translate the korean text just to figure out what it says, so I can check to an extent if the name matches the use. So as you can see a complete resource list would save us from HUGE manual work. 80+% of my time is resource finding when adding effects.

MrAntares avatar Mar 01 '22 08:03 MrAntares

@MrAntares Do you still use Discord? Me and Danilo (dev UnityRO) have a question regarding palettes (for example, hair), could you answer some questions?

juliolitwin avatar Mar 04 '22 14:03 juliolitwin

Some improvement for map effects in https://github.com/MrAntares/Ragna.roBrowser/commit/f116eb81e868b65b1f1e5717cd5cc77eef5a1c28 https://github.com/MrAntares/Ragna.roBrowser/commit/c7d9ad9245380e6f4dc59da1e6a36e1e70053cbd

We still need to order effects and entities and anything transparent using a better method. So far only entities are ordered properly.

MrAntares avatar Sep 23 '22 09:09 MrAntares