Cleaned up laser.gd and made plasma bool functional again

This commit is contained in:
Sage Vaillancourt 2018-05-23 04:31:03 -04:00
parent 845dc35e37
commit 2934ddd400
1 changed files with 4 additions and 10 deletions

View File

@ -7,25 +7,19 @@ export (int) var DAMAGE
var plasma = false var plasma = false
var current_pen = 0 var current_pen = 0
# class member variables go here, for example:
# var a = 2
# var b = "textvar"
func _on_Visibility_screen_exited(): func _on_Visibility_screen_exited():
queue_free() queue_free()
func _ready(): func _ready():
# Called every time the node is added to the scene.
# Initialization here
$AnimatedSprite.play() $AnimatedSprite.play()
connect("area_entered", self, "hit") connect("area_entered", self, "hit")
pass pass
func hit(who): func hit(who):
#if plasma == false:
# hide() if plasma == true:
# queue_free() pass
if current_pen > 0: elif current_pen > 0:
current_pen -= 1 current_pen -= 1
else: else:
hide() hide()