Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: JimmyD on Sun 14/09/2008 17:40:35

Title: Faster rotation speed on keyboard control...
Post by: JimmyD on Sun 14/09/2008 17:40:35
In my setting, I've got a player controlled by keyboard (continuous presses), and sometimes changing direction from left to right takes a bit longer than feels appropriate. Is there a way to alter the speed of rotation?
Title: Re: Faster rotation speed on keyboard control...
Post by: Akatosh on Tue 16/09/2008 20:25:28
If there is a way to alter rotation speed, it's none that I know of. You could build workaround by turning the "Player turns to face location" thing off and creating a script that turns the player "by hand". This is what I mean:


player.FaceLocation(player.x, player.y+10); //face down, -10 for facing up; set as you think is appropiate
Wait(5); //experimet with that delay
player.FaceLocation(player.x-10,player.y); //-10=left, +10=right


... or something among these lines. Hope that helps, and that my PDA didn't fuck up the formatting TOO much.
Title: Re: Faster rotation speed on keyboard control...
Post by: Akatosh on Tue 16/09/2008 20:30:16
(gaah, can't edit posts in this stupid mobile phone view! :()

Or did you mean something else? That code might not work, depending on how exactly you're handling "movement by continuous key pressing" and the like. Some more insight in your control system might be nice.