Advertisement
Guest User

player

a guest
Dec 16th, 2023
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. extends CharacterBody2D
  2.  
  3. @onready var fx = $FX
  4. @onready var hotbar = $UI/Hotbar
  5.  
  6. func _physics_process(_delta):
  7. velocity = Input.get_vector("ui_left","ui_right","ui_up","ui_down") * 150
  8. move_and_slide()
  9.  
  10. func play_FX(skill):
  11. fx.play(skill.name)
  12.  
  13. func add_item(stats,skill):
  14. hotbar.add_item(stats,skill)
  15.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement