Add hero runtime
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=8 format=3 uid="uid://b1fxc23gkbqre"]
|
||||
[gd_scene load_steps=9 format=3 uid="uid://b1fxc23gkbqre"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/bootstrap/GameRoot.cs" id="1_game_root"]
|
||||
[ext_resource type="Script" path="res://scripts/debug/DebugOverlay.cs" id="2_debug_overlay"]
|
||||
@@ -7,6 +7,7 @@
|
||||
[ext_resource type="PackedScene" path="res://scenes/debug/SmokeScene.tscn" id="4_smoke"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/debug/ContentBrowser.tscn" id="5_content_browser"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/debug/DebugSandbox.tscn" id="6_debug_sandbox"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/debug/HeroSandbox.tscn" id="7_hero_sandbox"]
|
||||
|
||||
[node name="GameRoot" type="Node"]
|
||||
script = ExtResource("1_game_root")
|
||||
@@ -14,6 +15,7 @@ MenuScene = ExtResource("3_menu")
|
||||
SmokeScene = ExtResource("4_smoke")
|
||||
ContentBrowserScene = ExtResource("5_content_browser")
|
||||
DebugSandboxScene = ExtResource("6_debug_sandbox")
|
||||
HeroSandboxScene = ExtResource("7_hero_sandbox")
|
||||
|
||||
[node name="DebugCommandNode" type="Node" parent="."]
|
||||
process_mode = 3
|
||||
|
||||
88
godot/scenes/debug/HeroSandbox.tscn
Normal file
88
godot/scenes/debug/HeroSandbox.tscn
Normal file
@@ -0,0 +1,88 @@
|
||||
[gd_scene load_steps=4 format=3 uid="uid://dchtr3qrw2omq"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/debug/HeroSandboxController.cs" id="1_hero_sandbox"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/hero/Hero.tscn" id="2_hero"]
|
||||
[ext_resource type="Script" path="res://scripts/hero/HeroStateHudController.cs" id="3_hero_hud"]
|
||||
|
||||
[node name="HeroSandbox" type="Control"]
|
||||
process_mode = 3
|
||||
layout_mode = 3
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
script = ExtResource("1_hero_sandbox")
|
||||
|
||||
[node name="ButtonPanel" type="PanelContainer" parent="."]
|
||||
process_mode = 3
|
||||
layout_mode = 1
|
||||
anchors_preset = 10
|
||||
anchor_right = 1.0
|
||||
offset_left = 16.0
|
||||
offset_top = 16.0
|
||||
offset_right = -960.0
|
||||
offset_bottom = 704.0
|
||||
grow_horizontal = 2
|
||||
custom_minimum_size = Vector2(220, 0)
|
||||
|
||||
[node name="Scroll" type="ScrollContainer" parent="ButtonPanel"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Buttons" type="VBoxContainer" parent="ButtonPanel/Scroll"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Playfield" type="Control" parent="."]
|
||||
layout_mode = 1
|
||||
anchors_preset = 0
|
||||
offset_left = 260.0
|
||||
offset_top = 64.0
|
||||
offset_right = 960.0
|
||||
offset_bottom = 560.0
|
||||
|
||||
[node name="PlayBounds" type="ColorRect" parent="Playfield"]
|
||||
layout_mode = 0
|
||||
offset_left = 280.0
|
||||
offset_top = 96.0
|
||||
offset_right = 920.0
|
||||
offset_bottom = 516.0
|
||||
color = Color(0.1, 0.22, 0.28, 0.28)
|
||||
|
||||
[node name="Hero" parent="Playfield" instance=ExtResource("2_hero")]
|
||||
position = Vector2(600, 306)
|
||||
|
||||
[node name="HudPanel" type="PanelContainer" parent="."]
|
||||
process_mode = 3
|
||||
layout_mode = 1
|
||||
anchors_preset = 11
|
||||
anchor_left = 1.0
|
||||
anchor_right = 1.0
|
||||
offset_left = -348.0
|
||||
offset_top = 16.0
|
||||
offset_right = -16.0
|
||||
offset_bottom = 268.0
|
||||
grow_horizontal = 0
|
||||
script = ExtResource("3_hero_hud")
|
||||
|
||||
[node name="StateLabel" type="Label" parent="HudPanel"]
|
||||
layout_mode = 2
|
||||
text = "Hero: unbound"
|
||||
|
||||
[node name="LogPanel" type="PanelContainer" parent="."]
|
||||
process_mode = 3
|
||||
layout_mode = 1
|
||||
anchors_preset = 11
|
||||
anchor_left = 1.0
|
||||
anchor_right = 1.0
|
||||
offset_left = -348.0
|
||||
offset_top = 288.0
|
||||
offset_right = -16.0
|
||||
offset_bottom = 704.0
|
||||
grow_horizontal = 0
|
||||
|
||||
[node name="LogScroll" type="ScrollContainer" parent="LogPanel"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="LogLabel" type="Label" parent="LogPanel/LogScroll"]
|
||||
layout_mode = 2
|
||||
text = ""
|
||||
17
godot/scenes/hero/Hero.tscn
Normal file
17
godot/scenes/hero/Hero.tscn
Normal file
@@ -0,0 +1,17 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://b1dwy8sg78kxp"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/hero/HeroActor.cs" id="1_hero_actor"]
|
||||
|
||||
[node name="Hero" type="Node2D"]
|
||||
script = ExtResource("1_hero_actor")
|
||||
|
||||
[node name="Body" type="Polygon2D" parent="."]
|
||||
color = Color(0.2, 0.85, 1, 1)
|
||||
polygon = PackedVector2Array(-22, -14, 24, 0, -22, 14, -10, 0)
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
offset_left = -22.0
|
||||
offset_top = 18.0
|
||||
offset_right = 30.0
|
||||
offset_bottom = 41.0
|
||||
text = "Hero"
|
||||
Reference in New Issue
Block a user