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 / Rotating an Object

Author
Message
Bazza
20
Years of Service
User Offline
Joined: 24th Jul 2004
Location:
Posted: 22nd Aug 2004 21:00
Hi there

I am trying to do the snake game, I would like to know what command i should use to make my snake turn at 90 degrees when a key is pressed.

thank you
Kohaku
20
Years of Service
User Offline
Joined: 3rd May 2004
Location: The not very United Kingdom
Posted: 23rd Aug 2004 12:44


Infra-Dark
Bring the 20 liners back!
#coding, like coding, but with a #
bibz1st
21
Years of Service
User Offline
Joined: 2nd Jan 2003
Location:
Posted: 28th Aug 2004 19:50
that would keep rotating it until the key was not pressed
try this instead...

if rightkey()=1 and pressed=0
pressed=1
yrotate object 1, 90
endif
if rightkey()=0 then pressed =0

Login to post a reply

Server time is: 2024-11-27 08:50:44
Your offset time is: 2024-11-27 08:50:44