big buddy 2020-06-10 19:22 (Edited)
Howdy there y’all
I made some improvements to the code everything is a lot easier to read now in the barrel in the top left corner is going to be the health bar other than that not much has changed i’d like to know if you think the code is easy to read
GAMELEGEND 2020-06-10 20:28 (Edited)
what kind of game is it goin to be
big buddy 2020-06-10 23:34
The game I want to turn it into Is a survival game The combat Is Going to be very fast Reaction Time like a shoot out I want the goal of the game to get the most gold Maybe you Will be able to mine gold With TNT of course
Timo 2020-06-11 06:21
Nice sprite!
was8bit 2020-06-11 06:53
Cool :)
BlockHead 2020-06-11 07:12
I like the sprite
Timo 2020-06-13 08:27
In my opinion the code looks more complex than necessary. I would keep it more simple.
For animations you could use less IF and more maths. E.g:
Instead of (this is fake code)
IF TOGGLE=0 THEN F=30
IF TOGGLE=1 THEN F=32
You could write
F=30+TOGGLE*2
Timo 2020-06-13 08:31
For animations I usually use something like this:
C=10+(TIMER/2) MOD 4
In this example the 2 is the animation speed (the higher the slower), the 4 is the number of animation frames, and the 10 is the first character of the animation. For big sprites (2x2) you would multiply it like this:
C=10+((TIMER/2) MOD 4)*2
big buddy 2020-06-13 12:03
Cool thank you very much Timo I will definitely try and use more math instead of if then
was8bit 2020-06-13 13:43
Even if your graphic frames dont all line up sequentially, you could use an array to hold the actual character numbers, and index the array.... this can somtimes happen with 2x2 or biggger sprites that extend beyond the edge of the character set... using Timo's example...
DIM ANIFRAME(3)
FOR I=0 TO 3
READ ANIFRAME(I)
NEXT I
DATA 12,14,32,34
F=(TIMER/2) MOD 4
CellNum=ANIFRAME(F)
Or use CellNum=ANIFRAME((TIMER/2) MOD 4)