0
Answered

Pause Player Movement during Hurt state

Syed Suhaib Zubair 2 months ago in Shooter updated 2 months ago 4

I have an issue. I am confuse how and which trigger should i use to stop player movement while i am in Hurt State.

if i am in a hurt state i want player to move but if i draw weapon in a hurt state i want to stop or pause player movement so the player can only aim and shoot. And again i holster weapon it can start moving in camera direction.

So please guide which trigger should i use and how to control the player movement.

Unity version:
2019
Game Creator version:
1.6
Answered

When you use the Trigger to draw or holster the weapon, simply use the Character Property action at the beginning and change the "Is Controllable" option on the Player set to False. This will make the Player stuck in its position and unable to move while drawing the weapon. 

After drawing the weapon, you can use the same Action to allow the player to move.

Its changing the whole state of player when i using "Is Controllable". I am saying that i want to to block only movement. i am saying that if i am in a hurt state and i am unarmed then i can walk in a hurt state. but when i draw weapon i want to block the movement so the player don't move only aim and fire towards the enemy or anything.  and when i holster the weapon or i am unarmed then it again start moving in hurt state.

Hope you understand what i am trying to say.

maybe you can set the speed of player as zero

if i set the speed to zero it keeps moving but too much slow. mean still move due to default character movement system.