A command to check if player is crouching?
A command to check if player is crouching?
I was just wondering if there is a script command to check whether the player is crouching or not. I have made functional scripted weapons for my game but the problem is this: When the player stands the weapons work fine but when he crouches the shooting point stays up there where it was when he was standing. I made the system just like ZenBudha's "Perfectly functioning flashlight", I just attached a FirePoint entity instead of a SpotLight and then a little script to deal with the triggers.
The reason is the flashlight is being controlled by an invisible pawn. So even though the player is crouching the pawn that the flashlight is connected to is not.
So you need to make the flashlight pawn check if the player is crouching somehow and then make it crouch.
As well I'm glad to see someone else using it for a scripted weapon as that was my original reason for getting it (with much help from others) to work in tht fashion.
So you need to make the flashlight pawn check if the player is crouching somehow and then make it crouch.
As well I'm glad to see someone else using it for a scripted weapon as that was my original reason for getting it (with much help from others) to work in tht fashion.
Fear not the textures for the almighty stylus is with thee - Book of Zen