hitboxes
This commit is contained in:
parent
ef98662322
commit
8c773e4a6e
3 changed files with 7 additions and 0 deletions
|
@ -35,4 +35,7 @@ func _process(delta):
|
||||||
#if Input.get_joy_axis(0,JOY_AXIS_LEFT_Y) != 0:
|
#if Input.get_joy_axis(0,JOY_AXIS_LEFT_Y) != 0:
|
||||||
# velocity = Vector2.UP.rotated(rotation) * -400 * Input.get_joy_axis(0,JOY_AXIS_LEFT_Y)
|
# velocity = Vector2.UP.rotated(rotation) * -400 * Input.get_joy_axis(0,JOY_AXIS_LEFT_Y)
|
||||||
position += velocity * delta
|
position += velocity * delta
|
||||||
|
if position.x < 782 && position.x > 496:
|
||||||
|
if position.y < 468 && position.y > 270:
|
||||||
|
Global.live = 3
|
||||||
#pass
|
#pass
|
||||||
|
|
|
@ -42,4 +42,5 @@ func _process(delta):
|
||||||
#if Input.get_joy_axis(0,JOY_AXIS_LEFT_Y) != 0:
|
#if Input.get_joy_axis(0,JOY_AXIS_LEFT_Y) != 0:
|
||||||
# velocity = Vector2.UP.rotated(rotation) * -400 * Input.get_joy_axis(0,JOY_AXIS_LEFT_Y)
|
# velocity = Vector2.UP.rotated(rotation) * -400 * Input.get_joy_axis(0,JOY_AXIS_LEFT_Y)
|
||||||
position += velocity * delta
|
position += velocity * delta
|
||||||
|
print(position)
|
||||||
#pass
|
#pass
|
||||||
|
|
|
@ -35,4 +35,7 @@ func _process(delta):
|
||||||
#if Input.get_joy_axis(0,JOY_AXIS_LEFT_Y) != 0:
|
#if Input.get_joy_axis(0,JOY_AXIS_LEFT_Y) != 0:
|
||||||
# velocity = Vector2.UP.rotated(rotation) * -400 * Input.get_joy_axis(0,JOY_AXIS_LEFT_Y)
|
# velocity = Vector2.UP.rotated(rotation) * -400 * Input.get_joy_axis(0,JOY_AXIS_LEFT_Y)
|
||||||
position += velocity * delta
|
position += velocity * delta
|
||||||
|
if position.x < 782 && position.x > 496:
|
||||||
|
if position.y < 468 && position.y > 270:
|
||||||
|
Global.live = 2
|
||||||
#pass
|
#pass
|
||||||
|
|
Loading…
Reference in a new issue