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 / I need some help with some movment code

Author
Message
GOD
21
Years of Service
User Offline
Joined: 23rd Apr 2003
Location: right there
Posted: 24th Jun 2004 02:35
What I want to happen is a sphere on the top of the screen moves side to side and every time it hits the side of the screen it swtiches position and moves back. I wrote some code that I though would be good but it doesnt seem to work. When the sphere gets to one side of the screen it starts spazing out and switching variables and not working. I tried a few things but it didnt seem to work. Thanks for any ideas or suggestions. The code is below. Its not all of it, just the important parts.
SandraD
20
Years of Service
User Offline
Joined: 30th May 2004
Location: Down on the corner, out in the street.
Posted: 24th Jun 2004 08:22
Take your "Emoving=1" out of the DO..LOOP. where it is now, the object starts to move back (emoving=2) then goes back to the Do, emoving gets set to 1 again and it starts moving back.

S.

Any truly great code should be indisguishable from magic.

Login to post a reply

Server time is: 2024-09-22 14:14:50
Your offset time is: 2024-09-22 14:14:50