Help with player dying

:slight_smile: ## Godot Version
Godot_V.4.2.2

Question

I have a player and a bullet, and when player interacts with bullet i want to player cant move around.I tried doing it on my own but it didnt worked.Take a
look:
var move = 0
func _physics_process(delta):
if move = 0:
var direction = Input.get_vector(“move_left”, “move_right”, “move_up”, “move_down”)
velocity = direction * 400
move_and_slide()
else:
print("I CANT MOVE)

then in the bullet script on the body_entered signal i autoload player,and typed
player.move = 1
I thought when changing the move variable the player couldnt move but it dosent works.If u have some easier way to do it please write it.Thanks

It seems you are missing an equal “=” symbol, do like this, if move == 0:

i did it,ty tho

Are you sure that the player.move changes when bullet collides? Try to print it.