crash fix
This commit is contained in:
parent
b6375e04c8
commit
efd5738f70
6 changed files with 53 additions and 9 deletions
|
@ -29,7 +29,7 @@ func activate_plate():
|
|||
print("wird aktiviert")
|
||||
if not is_activated:
|
||||
is_activated = true
|
||||
if laser:
|
||||
if laser and weakref(laser).get_ref():
|
||||
laser.queue_free()
|
||||
# TODO: fix error when called again
|
||||
|
||||
|
|
|
@ -98,7 +98,7 @@ func _physics_process(delta):
|
|||
var box = get_slide_collision(i).get_collider() as Box
|
||||
if scale.x == 2:
|
||||
if box and velocity.y >= 0:
|
||||
box.velocity.x = velocity.x*0.8
|
||||
box.velocity.x = velocity.x*1.2
|
||||
else:
|
||||
if box and velocity.y >= 0 and box.scale.x < 2:
|
||||
box.velocity.x = velocity.x*0.8
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue