Changing levels
I made it where if you beat phonephreak it moves you to the next level.
This commit is contained in:
1 parent
7ffc756b36
commit
61912a7df4
11 files changed
+95
-26
No files matched your search
@@ -330,24 +330,22 @@ func _physics_process(delta):
|
||||
if Input.is_action_just_pressed("gun"):
|
||||
weapon = 2
|
||||
GloblaData.weapon = 2
|
||||
if GloblaData.doing_puzzle == true:
|
||||
$".".global_position = $"../Marker2D2".global_position
|
||||
$Label.text = str(int(GloblaData.cassets))
|
||||
if Input.is_action_just_pressed("right"):
|
||||
dir = 1
|
||||
$ColorRect5.global_position = $Marker2D3.global_position
|
||||
$ColorRect5.rotation = 130
|
||||
if Input.is_action_just_pressed("left"):
|
||||
$ColorRect5.global_position = $Marker2D2.global_position
|
||||
$ColorRect5.rotation = -130
|
||||
dir = 0
|
||||
if GloblaData.doing_puzzle == false:
|
||||
if Input.is_action_just_pressed("right"):
|
||||
$ColorRect5.global_position = $Marker2D3.global_position
|
||||
$ColorRect5.rotation = 130
|
||||
dir = 1
|
||||
if Input.is_action_just_pressed("left"):
|
||||
$ColorRect5.global_position = $Marker2D2.global_position
|
||||
$ColorRect5.rotation = -130
|
||||
dir = 0
|
||||
if Input.is_action_just_pressed("fire") and weapon == 2:
|
||||
var instance = projectile.instantiate()
|
||||
if !dir:
|
||||
instance.speed = -instance.speed
|
||||
instance.position = $Marker2D.global_position
|
||||
GloblaData.level_1.add_child(instance)
|
||||
$"..".add_child(instance)
|
||||
elif Input.is_action_just_pressed("fire") and weapon == 1:
|
||||
$ColorRect5.rotation -= slash
|
||||
slash = -slash
|
||||
|
||||
Reference in new issue
Block a user