Game data commit

This commit is contained in:
Segey Lapin
2019-07-17 16:01:38 +03:00
parent 6b063cb729
commit 16de47d454
97 changed files with 3092 additions and 0 deletions

20
proto1/master.gd Normal file
View File

@@ -0,0 +1,20 @@
extends KinematicBody2D
var motion : = Vector2()
enum {STATE_NORMAL, STATE_DIALOGUE}
var state = STATE_NORMAL
func _ready():
world.master_node = self
func _physics_process(delta):
match(state):
STATE_NORMAL:
var horizontal: float = Input.get_action_strength("move_east") - Input.get_action_strength("move_west")
var vertical: float = Input.get_action_strength("move_south") - Input.get_action_strength("move_north")
motion = Vector2(horizontal, vertical) * 140.5
motion = move_and_slide(motion)
func _process(delta):
match(state):
STATE_NORMAL:
if Input.is_action_just_pressed("action1"):
world.action1()