Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- extends Node2D
- var PLAYERSTATE_PREV = ""
- var PLAYERSTATE = ""
- var PLAYERSTATE_NEXT = "ground"
- func _ready():
- set_process(true)
- pass
- func _process(delta):
- PLAYERSTATE_PREV = PLAYERSTATE
- PLAYERSTATE = PLAYERSTATE_NEXT
- if PLAYERSTATE == "ground":
- ground_state(delta)
- elif PLAYERSTATE =="air":
- air_state(delta)
- func ground_state(delta):
- print("i'm on the ground")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement