diff options
author | Marcelo Costa <> | 2024-01-27 16:16:37 -0300 |
---|---|---|
committer | Marcelo Costa <> | 2024-01-27 16:16:37 -0300 |
commit | 7f4fc3b59c286c7c50df43c4f75eab330955e4f3 (patch) | |
tree | 6bf06c3974ad96d3763fccd45ece54fa778c1236 | |
parent | 99b7a48dd674b0b62e21ca2f76caede42c20a308 (diff) | |
download | gamejam-ggj-2024-7f4fc3b59c286c7c50df43c4f75eab330955e4f3.tar.gz gamejam-ggj-2024-7f4fc3b59c286c7c50df43c4f75eab330955e4f3.tar.bz2 gamejam-ggj-2024-7f4fc3b59c286c7c50df43c4f75eab330955e4f3.zip |
MVP for Find Window Microgame
-rw-r--r-- | game/microgames/find_window/find_window.gd | 18 | ||||
-rw-r--r-- | game/microgames/find_window/find_window.tscn | 130 | ||||
-rw-r--r-- | game/microgames/find_window/msn_girlfriend.gd | 11 | ||||
-rw-r--r-- | game/microgames/find_window/msn_regular.gd | 6 | ||||
-rw-r--r-- | game/microgames/find_window/msn_regular.tscn | 23 | ||||
-rw-r--r-- | game/microgames/heart_break/heart_break.tscn | 12 |
6 files changed, 194 insertions, 6 deletions
diff --git a/game/microgames/find_window/find_window.gd b/game/microgames/find_window/find_window.gd new file mode 100644 index 0000000..9d2ca64 --- /dev/null +++ b/game/microgames/find_window/find_window.gd @@ -0,0 +1,18 @@ +extends Microgame + + +# Called when the node enters the scene tree for the first time. +func _ready(): + var windows = $AllWindows.get_children() + var max_windows = windows.size() - randi_range(0,2) + for i in max_windows: + var window = windows[i] + window.position = window.position + Vector2(randf_range(-100, 100), randf_range(-100,100)) + window.show() + $Timer.start(0.1) + await $Timer.timeout + + +func _on_send_button_button_down(): + %TextBoxMessage.hide() + %ChatMessage.show() diff --git a/game/microgames/find_window/find_window.tscn b/game/microgames/find_window/find_window.tscn new file mode 100644 index 0000000..6fe7233 --- /dev/null +++ b/game/microgames/find_window/find_window.tscn @@ -0,0 +1,130 @@ +[gd_scene load_steps=7 format=3 uid="uid://b8q2l65pajb3"] + +[ext_resource type="Script" path="res://game/microgames/find_window/find_window.gd" id="1_167ws"] +[ext_resource type="Texture2D" uid="uid://j0btxfrk2q8k" path="res://game/microgames/find_window/assets/Img_background_windows.png" id="1_w06df"] +[ext_resource type="Texture2D" uid="uid://7h0hokgsxon4" path="res://game/microgames/find_window/assets/Img_MSN_namoradinha.png" id="3_ekh6x"] +[ext_resource type="Script" path="res://game/microgames/find_window/msn_girlfriend.gd" id="4_ithnb"] +[ext_resource type="PackedScene" uid="uid://dxo3khe6emukf" path="res://game/microgames/find_window/msn_regular.tscn" id="4_t7t3v"] + +[sub_resource type="LabelSettings" id="LabelSettings_csx47"] +font_color = Color(0.443137, 0.443137, 0.443137, 1) + +[node name="FindWindow" type="Node"] +script = ExtResource("1_167ws") + +[node name="ImgBackgroundWindows" type="Sprite2D" parent="."] +position = Vector2(578, 326) +texture = ExtResource("1_w06df") + +[node name="AllWindows" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_right = 40.0 +offset_bottom = 40.0 + +[node name="ImgMsnNamoradinha" type="TextureRect" parent="AllWindows"] +visible = false +layout_mode = 0 +offset_left = 288.0 +offset_top = 121.0 +offset_right = 906.0 +offset_bottom = 579.0 +texture = ExtResource("3_ekh6x") +script = ExtResource("4_ithnb") + +[node name="SendButton" type="Button" parent="AllWindows/ImgMsnNamoradinha"] +layout_mode = 0 +offset_left = 352.0 +offset_top = 380.0 +offset_right = 479.0 +offset_bottom = 430.0 +text = "ENVIAR" + +[node name="TextBoxMessage" type="Label" parent="AllWindows/ImgMsnNamoradinha"] +unique_name_in_owner = true +layout_mode = 0 +offset_left = 31.0 +offset_top = 370.0 +offset_right = 87.0 +offset_bottom = 393.0 +text = "I LUV U" +label_settings = SubResource("LabelSettings_csx47") + +[node name="ChatMessage" type="Label" parent="AllWindows/ImgMsnNamoradinha"] +unique_name_in_owner = true +visible = false +layout_mode = 0 +offset_left = 29.0 +offset_top = 183.0 +offset_right = 85.0 +offset_bottom = 206.0 +text = "I LUV U" +label_settings = SubResource("LabelSettings_csx47") + +[node name="ImgMsnNormal" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 44.0 +offset_top = 98.0 +offset_right = 662.0 +offset_bottom = 556.0 + +[node name="ImgMsnNormal2" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 434.0 +offset_top = 84.0 +offset_right = 1052.0 +offset_bottom = 542.0 + +[node name="ImgMsnNormal3" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 349.0 +offset_top = 104.0 +offset_right = 967.0 +offset_bottom = 562.0 + +[node name="ImgMsnNormal4" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 258.0 +offset_top = 162.0 +offset_right = 876.0 +offset_bottom = 620.0 + +[node name="ImgMsnNormal5" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 258.0 +offset_top = 162.0 +offset_right = 876.0 +offset_bottom = 620.0 + +[node name="ImgMsnNormal6" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 258.0 +offset_top = 162.0 +offset_right = 876.0 +offset_bottom = 620.0 + +[node name="ImgMsnNormal7" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 258.0 +offset_top = 162.0 +offset_right = 876.0 +offset_bottom = 620.0 + +[node name="ImgMsnNormal8" parent="AllWindows" instance=ExtResource("4_t7t3v")] +visible = false +layout_mode = 0 +offset_left = 258.0 +offset_top = 162.0 +offset_right = 876.0 +offset_bottom = 620.0 + +[node name="Timer" type="Timer" parent="."] + +[connection signal="button_down" from="AllWindows/ImgMsnNamoradinha/SendButton" to="." method="_on_send_button_button_down"] diff --git a/game/microgames/find_window/msn_girlfriend.gd b/game/microgames/find_window/msn_girlfriend.gd new file mode 100644 index 0000000..d0ba84f --- /dev/null +++ b/game/microgames/find_window/msn_girlfriend.gd @@ -0,0 +1,11 @@ +extends TextureRect + + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + pass diff --git a/game/microgames/find_window/msn_regular.gd b/game/microgames/find_window/msn_regular.gd new file mode 100644 index 0000000..4747e85 --- /dev/null +++ b/game/microgames/find_window/msn_regular.gd @@ -0,0 +1,6 @@ +extends TextureRect + + + +func _on_button_button_down(): + queue_free() diff --git a/game/microgames/find_window/msn_regular.tscn b/game/microgames/find_window/msn_regular.tscn new file mode 100644 index 0000000..b24557d --- /dev/null +++ b/game/microgames/find_window/msn_regular.tscn @@ -0,0 +1,23 @@ +[gd_scene load_steps=3 format=3 uid="uid://dxo3khe6emukf"] + +[ext_resource type="Texture2D" uid="uid://cmomodj0c17sh" path="res://game/microgames/find_window/assets/Img_MSN_normal.png" id="1_55ksy"] +[ext_resource type="Script" path="res://game/microgames/find_window/msn_regular.gd" id="2_m5374"] + +[node name="ImgMsnNormal" type="TextureRect"] +texture = ExtResource("1_55ksy") +script = ExtResource("2_m5374") + +[node name="Button" type="Button" parent="."] +modulate = Color(1, 1, 1, 0) +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.918 +anchor_top = 0.039 +anchor_right = 0.918 +anchor_bottom = 0.039 +offset_left = -50.324 +offset_top = -18.862 +offset_right = 49.676 +offset_bottom = 31.138 + +[connection signal="button_down" from="Button" to="." method="_on_button_button_down"] diff --git a/game/microgames/heart_break/heart_break.tscn b/game/microgames/heart_break/heart_break.tscn index b130424..a36d36d 100644 --- a/game/microgames/heart_break/heart_break.tscn +++ b/game/microgames/heart_break/heart_break.tscn @@ -14,7 +14,7 @@ size = Vector2(20, 676) script = ExtResource("1_ia77r") [node name="PlayerHeart" parent="." instance=ExtResource("2_uwtaj")] -position = Vector2(553, 317) +position = Vector2(563, 338) [node name="Upper Boundary" type="StaticBody2D" parent="."] @@ -43,18 +43,18 @@ position = Vector2(574, 0) shape = SubResource("RectangleShape2D_upktn") [node name="Spiky" parent="." instance=ExtResource("3_dfa23")] -position = Vector2(182, 188) +position = Vector2(239, 249) [node name="Spiky2" parent="." instance=ExtResource("3_dfa23")] -position = Vector2(964, 218) +position = Vector2(891, 258) [node name="Spiky3" parent="." instance=ExtResource("3_dfa23")] -position = Vector2(235, 481) +position = Vector2(284, 531) [node name="Spiky4" parent="." instance=ExtResource("3_dfa23")] -position = Vector2(845, 496) +position = Vector2(821, 530) [node name="Spiky5" parent="." instance=ExtResource("3_dfa23")] -position = Vector2(570, 104) +position = Vector2(570, 97) [connection signal="body_entered" from="PlayerHeart" to="." method="_on_player_heart_body_entered"] |