Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

2D All the way! / sprite animation speed

Author
Message
lokatsis
22
Years of Service
User Offline
Joined: 11th Feb 2004
Location: greece
Posted: 22nd Nov 2004 01:55
i want to animate some sprites using dbc but the speed is always faster than i want. i tried sync and wait commands but they influence the hole game. i want the speed of my speficic sprite to be low. can you help me?

THE AOOS
PiratSS
23
Years of Service
User Offline
Joined: 18th Oct 2002
Location:
Posted: 22nd Nov 2004 11:33
you need to use a custom sprite command that would use specific timer() intervals
Oneka
22
Years of Service
User Offline
Joined: 24th Apr 2004
Location: Hampton,VA
Posted: 23rd Nov 2004 04:24
or you could always just make a method to animate them yourself thats what I did


Making better games everday!
Oh yeah and just so you know its Oh-nek-a not One-ka!
13e
21
Years of Service
User Offline
Joined: 20th Oct 2004
Location: Here
Posted: 23rd Nov 2004 23:24 Edited at: 23rd Nov 2004 23:25
I'm sure adding more frames into your animation should make the animation slower?

If you get me?

I can't d/l your file, but I think should help?
dj chainz
21
Years of Service
User Offline
Joined: 25th Sep 2004
Location: England
Posted: 26th Nov 2004 02:52
Have a counter value that decreases from ,say, 5 to 1, in 1 step per loop. THen, simply call the animation sub only when the counter is 5. This will make the animation 5x as slow.

eg:
sync rate 50
counter = 5

do
dec counter
if counter<1 then counter=5
if counter=5 then gosub animation
sync
loop

animation:
return

For more info on stuff like this, see my blog!

I am the lead programmer at red spark studios
I also have a blog on how to make a game engine
http://www.dbgame.blogspot.com
lokatsis
22
Years of Service
User Offline
Joined: 11th Feb 2004
Location: greece
Posted: 27th Nov 2004 21:14
thanks for your help i;m gonna try it now!

THE AOOS

Login to post a reply

Server time is: 2026-06-11 14:48:49
Your offset time is: 2026-06-11 14:48:49