summaryrefslogtreecommitdiff
path: root/scenes
diff options
context:
space:
mode:
authorZoey Kitt <zoey.kitt@outlook.com>2024-11-15 19:15:43 -0600
committerZoey Kitt <zoey.kitt@outlook.com>2024-11-15 19:15:43 -0600
commitcdc892590b112dff319aa29337114cf076fb5cc2 (patch)
tree214d905347ef5ec32684b7455d4bec50003a551a /scenes
parenta74b70b168d8e77c44cfd0fed8813d118dbaaa63 (diff)
New window every second lol
Diffstat (limited to 'scenes')
-rw-r--r--scenes/main.gd9
-rw-r--r--scenes/main.tscn17
-rw-r--r--scenes/microgames/microgame_window.gd (renamed from scenes/closable_window.gd)0
-rw-r--r--scenes/microgames/microgame_window.tscn18
-rw-r--r--scenes/microgames/window_mvp.tscn (renamed from scenes/window_mvp.tscn)0
5 files changed, 27 insertions, 17 deletions
diff --git a/scenes/main.gd b/scenes/main.gd
index 258b1ab..642ec39 100644
--- a/scenes/main.gd
+++ b/scenes/main.gd
@@ -14,6 +14,9 @@ func _process(delta: float) -> void:
func _on_microgame_spawn_timer_timeout() -> void:
print("WAAAHAHAHA MICROGAMES")
- var window = Window.new()
- add_child(window)
-
+ var window_scene = preload("res://scenes/microgames/microgame_window.tscn")
+ var window_instance = window_scene.instantiate()
+ add_child(window_instance)
+ var microgame_scene = preload("res://scenes/microgames/window_mvp.tscn")
+ var microgame_instance = microgame_scene.instantiate()
+ window_instance.add_child(microgame_instance)
diff --git a/scenes/main.tscn b/scenes/main.tscn
index f76412c..6db30b0 100644
--- a/scenes/main.tscn
+++ b/scenes/main.tscn
@@ -1,9 +1,8 @@
-[gd_scene load_steps=5 format=3 uid="uid://d06d1vihf2oqp"]
+[gd_scene load_steps=4 format=3 uid="uid://d06d1vihf2oqp"]
[ext_resource type="Texture2D" uid="uid://b03ygtrwha22g" path="res://taytay/IMG_5199.jpeg" id="1_o2s48"]
[ext_resource type="Script" path="res://scenes/main.gd" id="1_y7a0r"]
-[ext_resource type="Script" path="res://scenes/closable_window.gd" id="2_2mdl3"]
-[ext_resource type="PackedScene" uid="uid://baukkysebggup" path="res://scenes/window_mvp.tscn" id="2_ls66h"]
+[ext_resource type="PackedScene" uid="uid://b2awdq32lxnef" path="res://scenes/microgames/microgame_window.tscn" id="3_ehgys"]
[node name="Node2D" type="Node2D"]
script = ExtResource("1_y7a0r")
@@ -13,16 +12,7 @@ position = Vector2(636.307, 381.672)
scale = Vector2(0.293995, 0.217148)
texture = ExtResource("1_o2s48")
-[node name="Window" type="Window" parent="."]
-title = "hiiiii"
-position = Vector2i(1710, 1112)
-size = Vector2i(1280, 720)
-content_scale_size = Vector2i(1280, 720)
-content_scale_mode = 1
-content_scale_aspect = 1
-script = ExtResource("2_2mdl3")
-
-[node name="WindowMvp" parent="Window" instance=ExtResource("2_ls66h")]
+[node name="Window" parent="." instance=ExtResource("3_ehgys")]
[node name="Score" type="Label" parent="."]
offset_top = 2.0
@@ -33,5 +23,4 @@ text = "Net worth: $"
[node name="Microgame spawn timer" type="Timer" parent="."]
autostart = true
-[connection signal="close_requested" from="Window" to="Window" method="_on_close_requested"]
[connection signal="timeout" from="Microgame spawn timer" to="." method="_on_microgame_spawn_timer_timeout"]
diff --git a/scenes/closable_window.gd b/scenes/microgames/microgame_window.gd
index 97e1e03..97e1e03 100644
--- a/scenes/closable_window.gd
+++ b/scenes/microgames/microgame_window.gd
diff --git a/scenes/microgames/microgame_window.tscn b/scenes/microgames/microgame_window.tscn
new file mode 100644
index 0000000..170e4c7
--- /dev/null
+++ b/scenes/microgames/microgame_window.tscn
@@ -0,0 +1,18 @@
+[gd_scene load_steps=3 format=3 uid="uid://b2awdq32lxnef"]
+
+[ext_resource type="Script" path="res://scenes/microgames/microgame_window.gd" id="1_8ce8l"]
+[ext_resource type="PackedScene" uid="uid://baukkysebggup" path="res://scenes/microgames/window_mvp.tscn" id="2_asfd5"]
+
+[node name="Window" type="Window"]
+auto_translate_mode = 1
+title = "hiiiii"
+position = Vector2i(1710, 1112)
+size = Vector2i(1280, 720)
+content_scale_size = Vector2i(1280, 720)
+content_scale_mode = 1
+content_scale_aspect = 1
+script = ExtResource("1_8ce8l")
+
+[node name="WindowMvp" parent="." instance=ExtResource("2_asfd5")]
+
+[connection signal="close_requested" from="." to="." method="_on_close_requested"]
diff --git a/scenes/window_mvp.tscn b/scenes/microgames/window_mvp.tscn
index da707d8..da707d8 100644
--- a/scenes/window_mvp.tscn
+++ b/scenes/microgames/window_mvp.tscn