feat: basic dialogue system and opening cutscene
This commit is contained in:
12
ennemy/armored_ennemy.gd
Normal file
12
ennemy/armored_ennemy.gd
Normal file
@ -0,0 +1,12 @@
|
||||
extends CharacterBody2D
|
||||
|
||||
@onready var animated_sprite: AnimatedSprite2D = $AnimatedSprite2D
|
||||
|
||||
func play_anim_run():
|
||||
animated_sprite.play("run")
|
||||
|
||||
func play_anim_idle():
|
||||
animated_sprite.play("idle")
|
||||
|
||||
func hit():
|
||||
animated_sprite.play("hit")
|
1
ennemy/armored_ennemy.gd.uid
Normal file
1
ennemy/armored_ennemy.gd.uid
Normal file
@ -0,0 +1 @@
|
||||
uid://dailpwkay2nu5
|
18
ennemy/armored_ennemy.tscn
Normal file
18
ennemy/armored_ennemy.tscn
Normal file
@ -0,0 +1,18 @@
|
||||
[gd_scene load_steps=4 format=3 uid="uid://c5ruphrd8ebuu"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dailpwkay2nu5" path="res://ennemy/armored_ennemy.gd" id="1_f4v0e"]
|
||||
[ext_resource type="SpriteFrames" uid="uid://i6035vm5ited" path="res://player/armored_spritesheet.tres" id="1_k1sc2"]
|
||||
[ext_resource type="Shape2D" uid="uid://6rhdwj5jxbxn" path="res://player/player_collision.tres" id="2_f4v0e"]
|
||||
|
||||
[node name="ArmoredEnnemy" type="CharacterBody2D"]
|
||||
script = ExtResource("1_f4v0e")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
position = Vector2(1, -28)
|
||||
sprite_frames = ExtResource("1_k1sc2")
|
||||
animation = &"jump"
|
||||
autoplay = "idle"
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
position = Vector2(0, -13)
|
||||
shape = ExtResource("2_f4v0e")
|
@ -1,21 +0,0 @@
|
||||
[gd_scene load_steps=3 format=3 uid="uid://cwxv8xl0hi31i"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://cn0crfbdlcoot" path="res://camera/camera.gd" id="1_f5lvx"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_7mycd"]
|
||||
size = Vector2(630, 340)
|
||||
|
||||
[node name="CameraHandler" type="Node2D"]
|
||||
script = ExtResource("1_f5lvx")
|
||||
|
||||
[node name="Area2D" type="Area2D" parent="."]
|
||||
collision_layer = 0
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"]
|
||||
shape = SubResource("RectangleShape2D_7mycd")
|
||||
|
||||
[node name="Camera2D" type="Camera2D" parent="."]
|
||||
|
||||
[connection signal="body_entered" from="Area2D" to="." method="_on_body_entered"]
|
||||
[connection signal="body_exited" from="Area2D" to="." method="_on_body_exited"]
|
Reference in New Issue
Block a user