Added Graphic for Blocks
This commit is contained in:
parent
71cbf96618
commit
b9eec60df7
21 changed files with 92 additions and 14 deletions
|
|
@ -5,6 +5,11 @@ extends Area2D
|
|||
@onready var raycastRight = $RaycastRight
|
||||
@onready var raycastTop = $RaycastTop
|
||||
|
||||
@onready var spriteBlock = $Block
|
||||
@onready var spriteSpecialBlock = $SpecialBlock
|
||||
@onready var spriteExpandBlock = $ExpandBlock
|
||||
@onready var spriteSpecialExpandedBlock = $SpecialExpandedBlock
|
||||
|
||||
@export var UID = 1
|
||||
|
||||
var secretPosition = Vector2()
|
||||
|
|
@ -56,3 +61,16 @@ func moveLeft():
|
|||
move(-64, 0)
|
||||
func moveRight():
|
||||
move(64, 0)
|
||||
|
||||
func setlook():
|
||||
match type:
|
||||
GLOBAL.BLOCKTYPES.LIGHT:
|
||||
if expand:
|
||||
spriteExpandBlock.show()
|
||||
else:
|
||||
spriteBlock.show()
|
||||
GLOBAL.BLOCKTYPES.HEAVY:
|
||||
if expand:
|
||||
spriteSpecialExpandedBlock.show()
|
||||
else:
|
||||
spriteSpecialBlock.show()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue