🧱: Level 3

main
Ervan Lefevre 2 years ago
parent 5024b58f39
commit 1adc44150b
  1. 1
      nodes/npc/npc.gd
  2. 1
      nodes/obstacle/obstacle.gd
  3. 5
      nodes/player/player.gd
  4. 11
      scenes/poc.tscn

@ -54,6 +54,7 @@ func grabbed(by):
$shape.disabled = true
$fsm.set_physics_process(false)
reparent(by)
position.y = 0
func dropped():
$shape.disabled = false

@ -9,6 +9,7 @@ func grabbed(by):
sleeping = true
gravity_scale = 0
reparent(by)
position.y = 0
func dropped():
$shape.disabled = false

@ -191,8 +191,9 @@ func handle_sprite_orientation():
elif is_on_ceiling_only():
if velocity.x != 0:
$oriented_container.rotation = PI if (velocity.x > 0) else -PI
sprite.flip_h = velocity.x > 0
$oriented_container.rotation = 0 if (velocity.x > 0) else PI
sprite.flip_v = velocity.x > 0
sprite.flip_h = false
else:
if velocity.x != 0:
$oriented_container.rotation = 0 if (velocity.x > 0) else PI

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save