Mega Shocked (./59):
Thanks for sharing your method for Sprite Scaling! In my case I am trying to Scale Sprite Pools.
I have modeled my projects around Sprite Pools but the missing link is scaling.
My hope is you will see although very wrong I did do my best to put elbow grease into this problem.
Again very much for the record appreciate what you have done for the community with this library!
I apologize in advance.
Mame files are here: https://www.dropbox.com/s/7zqkdo5vz4599ww/DDsprdmoMAME.zip?dl=0
Driver I used is in a .txt it needs to be patched into your hash folder via neogeo.xml
Source files are here: https://www.dropbox.com/s/f029ztwuxu7xxek/DDSpritePoolDemoSOURCE.zip?dl=0
I used banking so the syntax on functions is different than usual also NeoDev environment will need the bank stuff in place to compile the source .
*Syntax could be useful for people looking to incorporate banking into their projects.
*My projects use similar structs hoping it might be useful for someone to see how I group and declare variables.
Instructions for this broken demo
Joystick Instructions are plainly stated on the screen. Player 2 must be mapped.
Movement: Any character can be moved.
Y Sort: Function can be uncommented in "RenderSpritePool" (Compiled version has no Y sort)
Scale: Most interesting part of the demo
Hide/Show: Hide and Show Sprites and attempt to track their "way up" and "way down" sprite index. (Debug Info can commented to see what I was thinking)
All these things are kinda good if you only do one of the things mentioned above.
My suggestion is to do 1 thing listed below and reset the demo and try another thing.
When you combine things the demo starts to break.
1. Attempt to only SCALE sprites on your first run on the demo.
You will see jank sprite scaling (Probably the best part of this demo)
Looking closely strips have small gaps at times.
The anchoring is garbage.
I wish I could get insight on how to adjust the anchor point of the scale.
EX: How to scale a sprite from its direct center.
EX: How to scale a sprite anchoring the scale to the position of the sprites feet.
EX: Burnov is interesting because he has a frame that expands and contracts which will reveal Abobo's toe how can that be avoided.
2. On the second run Hide/Show Sprites....This was always supported by DATLib but in my case I am trying to re-index my variables to determine where sprites are on the list.
EX: Uncomment the Debug Statement in main to see the way I thought the list was working behind the scenes.
EX: I am a liar I swear I had scaling working with hide and show but you will find this is broken.
EX: Hide/Show Billy then Scale Billy and Abobo scales I am ashamed that I suck
Any insight on better techniques, how sprite pools work, anchoring scaling would be greatly appreciated.
What do you think about idea to recode this demo to racing game engine?