Disabling most of the player movement.
by Djekko Spurgin · in Torque 3D Professional · 05/14/2016 (9:44 am) · 2 replies
In my game I have a custom thread where the player will lay on there back (its hard to explain why but go with me here). the animation is done through a server side command and client side key bind. When I right click the player lays down and when i click again the player gets back up. This part is perfect and exactly how it needs to be.
BUT!
there player can still move around jump attack and so on. I need to know if there is a way to disable all other movement while the player is laying down and then enable it again when the player stands up.
BUT!
there player can still move around jump attack and so on. I need to know if there is a way to disable all other movement while the player is laying down and then enable it again when the player stands up.
About the author
Computer Game Development Student Lead Programmer Perplexed Studios
Torque Owner Richard Ranft
Roostertail Games
Create a new action map with your desired movement mappings, then when the player enters the new state just push your new action map. Then when the player leaves the state simply pop that action map.
To see this in action, just search in that same file for vehicleMap. This is how the system changes control schemes when a player enters and leaves a vehicle.