trying to make sprite go to 'goalx' and accelerate within the limits of normal platform movement
can anybody see why this doesn't work (it's all one line, but it's line broken for readability):
Set Sprite Platform X Component of Motion
clamp(sprite('goalx')-sprite.x,
max((sprite[Platform].VectorX-(1000*timedelta*sprite[Platform].FloorAccRate)),0-sprite[Platform].MaxFloorSpeed),
min((sprite[Platform].VectorX+(1000*timedelta*sprite[Platform].FloorAccRate)),sprite[Platform].MaxFloorSpeed))[/code:lgay6mab]
here's an example cap of it not working
hover the mouse over the blue box to use regular platform controls with the arrow keys
or click somewhere to watch the sprite move with the algorithm above to where you clicked
[url]http://dl.dropbox.com/u/1013446/notwork.cap[/url]