Page 1 of 1

Jerky movement infinite x-tile

PostPosted: Thu May 03, 2007 9:45 pm
by d-soldier
SEE ATTATCHED IMAGE:

I've noticed a jerky motion in my current project on my "ground" image while is infinately x-tiled. I've adjusted various settings, and even exported the game to verify that it jerks during compiled gameplay as well. The actor's DRAW ACTOR SCRIPT is:
"xvelocity = -2;"
... every few seconds it jerks back and forth a couple pixels... My framerate is remains between 29/30, and there is no apparent cause, as it happens during various intervals of the moving actor (no specific point during the scrolling) Is there a better way to do this?

PostPosted: Fri May 04, 2007 12:10 am
by makslane
I think you need to change the x value, not xvelocity.

...

PostPosted: Fri May 04, 2007 12:24 am
by d-soldier
I just checked through the variables/functions sections and didnt see anything relating to xvalue... and the script editor doesn't seem to accecpt it as a command either.???

PostPosted: Fri May 04, 2007 12:28 am
by makslane
I mean the x position:

Code: Select all
x -= 2;


But, looking your code again, I see you don't change the xvelocity value every frame. So, you can set the xvelocity outside of the 'Draw Actor' event.

PostPosted: Fri May 04, 2007 12:28 am
by Sgt. Sparky
x -= 2;
xD
alot simpler than you think. :D
(funny name for setting an x value right? :P )

PostPosted: Fri May 04, 2007 12:29 am
by Sgt. Sparky
makslane posted it just before me! :lol:

thanks

PostPosted: Fri May 04, 2007 3:10 pm
by d-soldier
Thanks for the input fellas, I appreciate the help!