Animation and abit of gaming concept.

Blitz3D Forums/Blitz3D Beginners Area/Animation and abit of gaming concept.

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.



There seem to be somekind oh hik in the animation could you try to make it as perfect as possible? :(

my code
AppTitle "Samus Animation!?"
Graphics 640,480,16,1

; GLOBAL VAR

; IMAGES
Global SamusSprites=LoadAnimImage("images\MR_Samus.png",56,56,0,55)

If SamusSprites = 0 Then
	Notify "ERROR!"
	End
EndIf

MaskImage SamusSprites,255,255,255

; TYPES
Type Player
	Field HealthBanks
	Field Healt
	Field x#,y#
	Field jump
	Field gravity
End Type


; SET BUFFER
SetBuffer BackBuffer()
SFrame=11
DelayNum = 200
; MAIN LOOP
While Not KeyDown(1)

If SFrame=21 Then SFrame=11

DrawImage SamusSprites,0,0,SFrame

If mytimer+DelayNum < MilliSecs() Then
  mytimer = MilliSecs()
  SFrame = SFrame + 1
End If

Flip
Cls


Wend
End