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.

Newcomers DBPro Corner / help with animation to keys

Author
Message
dark donkey
18
Years of Service
User Offline
Joined: 4th May 2006
Location:
Posted: 13th Nov 2006 22:23 Edited at: 14th Nov 2006 22:54
edit:
Also i have just added some code for an atak but that whant work either



the problem with this code is that when i pres up key the animation for the walk works fine but when i press space it plays the atak animation but then that disabels the walk animation




hi, i cant seem to get this code to work ive been trying to get it to work for about 3 hours now. heres the code

basicly what i am trying to do is when the up arrow key is pressed i whant onject 2 to play its animation,but this whant work.

http://www.darkdonkeygraphics.tk

Zeus
18
Years of Service
User Offline
Joined: 8th Jul 2006
Location: Atop Mount Olympus
Posted: 13th Nov 2006 22:26
You don't need if upkey()=0 because it only reads it when you press the upkey once. So take out:
if upkey()=0
stop object 2
endif
and see if it works
dark donkey
18
Years of Service
User Offline
Joined: 4th May 2006
Location:
Posted: 13th Nov 2006 22:30 Edited at: 13th Nov 2006 22:34
nope now when i press upkey it dosent play but when i take my finger off it it playes

edit got it to work

edit 2: is ther a disable key command cous i dont whant them to be able to use the down key

http://www.darkdonkeygraphics.tk

Bozzy
18
Years of Service
User Offline
Joined: 10th Sep 2006
Location: Birmingham, UK
Posted: 13th Nov 2006 23:12
just dont put it in the code i think... but dont ask me im just a newbie <<< see what i did there me...newbie... o never mind
Zeus
18
Years of Service
User Offline
Joined: 8th Jul 2006
Location: Atop Mount Olympus
Posted: 13th Nov 2006 23:46
Oops. Srry I guess I wuz wrong. I am a newbie too.
H4ck1d
18
Years of Service
User Offline
Joined: 27th Dec 2005
Location: Yes
Posted: 14th Nov 2006 00:28
I'm not a noob . Here, try this:



I've put in a variable to track whether you have already pressed down the up key. Check and see if this will work for you! Also, I added a do/loop, take it out if you already have a loop that this code is in. But the declaration, keyDown=0, should go outside whatever loop you have. Hope that helped!

-H4ck1d

dark donkey
18
Years of Service
User Offline
Joined: 4th May 2006
Location:
Posted: 14th Nov 2006 10:06
i got it to work, but i dont whant them to be able to use the downkey is ther any wat to disable it

http://www.darkdonkeygraphics.tk

dark donkey
18
Years of Service
User Offline
Joined: 4th May 2006
Location:
Posted: 14th Nov 2006 23:11
any one

http://www.darkdonkeygraphics.tk

Login to post a reply

Server time is: 2024-11-14 01:29:12
Your offset time is: 2024-11-14 01:29:12