Log In  


Cart #45407 | 2017-10-23 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

Obviously using FFTA sprites because I suck at pixel art.

Z changes between sprite control and cursor control.

Nothing much else.

3


Not sure how to update the uploaded cart though...


@kurokikaze Just submit a new cart like you did the first one. It will prompt if you want to submit a new cart or update an existing thread. Just choose to update the existing thread. It will provide a new cart code you can put into your main point.


Okay, time to update a bit.

I've added all 4 Babus sprites for 4 directions. Also, sprites are now drawn from a declared sprite objects, by iterating them, not just by hardcoded "place a here and b there".

I've also rewrote input (it's now unified between moving the player and moving the cursor). And camera is now faster the more it has to move.

With all the additions the engine code is under 1000 tokens now.

The moving range calculator and filler is written in JS (so it can be more easily covered by unit tests) and is ready to be rewritten in Lua. After that, I can move to walking animations and turn structure.


Added (very basic) movement animation. Units now have animation field storing necessary variables. Object of interest tracking still needs to be tweaked, as it now follows grid position of the player instead of current animated position. Also, I need to adjust for map height before animating, not after (needed for stepping up/down).


@kurokikaze: Been following this since I saw the cart pop up. And sticking animation frames in a container is a great way to cut down on animation routines, Especially if your sprites aren't in sequential order in the sprite sheet. IE: WalkAnims={5,15,32,23} or whatnot, Then call them with something like SPR(WalkAnims[Frame]) where you'd have frame updated in the update function.


Some more walking animations. I suck at pixelart though )



[Please log in to post a comment]