summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.md53
-rw-r--r--.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.stexbin0 -> 220 bytes
-rw-r--r--.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.md54
-rw-r--r--.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.stexbin114 -> 114 bytes
-rw-r--r--Godot_v3.2.3-stable_export_templates.tpz0
-rw-r--r--components/Level.gd33
-rw-r--r--components/textreveal.gd8
-rw-r--r--components/textrevealbox.gd12
-rw-r--r--components/textrevealbox.tscn17
-rw-r--r--project.godot8
-rw-r--r--scenes/introduction/check_mail.tscn101
-rw-r--r--scenes/introduction/come home.gd4
-rw-r--r--scenes/introduction/come home.tscn18
-rw-r--r--scenes/introduction/introduction.gd (renamed from scenes/introduction.gd)13
-rw-r--r--scenes/introduction/introduction.tscn (renamed from scenes/introduction.tscn)25
-rw-r--r--scenes/introduction/mail.gd5
-rw-r--r--scenes/introduction/mail.tscn21
-rw-r--r--scenes/menu.gd2
-rw-r--r--textures/colors/light_blue.pngbin547 -> 547 bytes
-rw-r--r--textures/colors/light_blue.xcfbin685 -> 685 bytes
-rw-r--r--textures/components/button/button.pngbin0 -> 639 bytes
-rw-r--r--textures/components/button/button.png.import34
-rw-r--r--textures/components/button/button.xcfbin0 -> 2457 bytes
23 files changed, 272 insertions, 36 deletions
diff --git a/.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.md5 b/.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.md5
new file mode 100644
index 0000000..66b5a15
--- /dev/null
+++ b/.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.md5
@@ -0,0 +1,3 @@
+source_md5="0a113feedc002d6ee1e8c9ad12aa8e47"
+dest_md5="d130d522e1cac3ce5f9d5479035d4a09"
+
diff --git a/.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.stex b/.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.stex
new file mode 100644
index 0000000..14f4d90
--- /dev/null
+++ b/.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.stex
Binary files differ
diff --git a/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.md5 b/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.md5
index dc1088e..dc2a9bc 100644
--- a/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.md5
+++ b/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.md5
@@ -1,3 +1,3 @@
-source_md5="e60421dadf5dadc72469f9ecb94e3258"
-dest_md5="0617ce744b60b4b57ca2027093d88ebe"
+source_md5="7b0f4ff8d1ead4082194a67cce6826be"
+dest_md5="6759fc66fe91c9772bdc95b039bdac18"
diff --git a/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.stex b/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.stex
index 3e53d28..674d116 100644
--- a/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.stex
+++ b/.import/light_blue.png-645c4b3f148d6489c3208794b1ff51bf.stex
Binary files differ
diff --git a/Godot_v3.2.3-stable_export_templates.tpz b/Godot_v3.2.3-stable_export_templates.tpz
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/Godot_v3.2.3-stable_export_templates.tpz
diff --git a/components/Level.gd b/components/Level.gd
index f9688a9..72366e1 100644
--- a/components/Level.gd
+++ b/components/Level.gd
@@ -4,6 +4,9 @@ class_name Level
signal lost_heart()
signal level_finished()
+onready var passwordfield = $password
+var trys = 0
+
func start():
print("Level starting.")
@@ -13,3 +16,33 @@ func lose_heart():
func finish_level():
emit_signal("level_finished")
+
+func login():
+ $Incorrect.visible = false
+ get_tree().change_scene("res://scenes/introduction/mail.tscn")
+ finish_level()
+
+func check_pw():
+ if passwordfield.text == "correct":
+ login()
+ else:
+ if passwordfield.text == "deeper" or trys == 10:
+ $Monolog2.start()
+ $Monolog1.visible = false
+ if trys == 20:
+ $Monolog3.start()
+ $Monolog2.visible = false
+ trys = trys + 1
+ $Incorrect.visible = true
+ passwordfield.text = ""
+
+func _on_Button_on_click():
+ check_pw()
+
+
+func _on_password_text_changed(new_text):
+ $Incorrect.visible = false
+
+
+func _on_password_text_entered(new_text):
+ check_pw()
diff --git a/components/textreveal.gd b/components/textreveal.gd
index e1fa4cc..7b96eb3 100644
--- a/components/textreveal.gd
+++ b/components/textreveal.gd
@@ -4,7 +4,10 @@ class_name TextReveal
signal finished_reveal()
export(String, MULTILINE) var to_render = "Text"
-export var speed = 100.0
+export var speed = 20.0
+
+export var xpos = 0
+export var ypos = 0
############
# INTERNAL #
@@ -19,6 +22,7 @@ var t = 0
# Called when the node enters the scene tree for the first time.
func _ready():
theme = preload("res://fonts/Flipps_Theme.tres")
+ rect_position = Vector2(xpos, ypos)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):
@@ -29,7 +33,7 @@ func _process(delta):
t -= additional
revealed += additional
text = to_render.substr(0, revealed)
- rect_position = -rect_size / 2
+ rect_position = -rect_size / 2 + Vector2(xpos, ypos)
if to_render.length() <= revealed:
started = false
finished = true
diff --git a/components/textrevealbox.gd b/components/textrevealbox.gd
new file mode 100644
index 0000000..175ac92
--- /dev/null
+++ b/components/textrevealbox.gd
@@ -0,0 +1,12 @@
+extends Node2D
+
+export(String, MULTILINE) var text = "Failed to load text :("
+export var autostart = true
+
+func _ready():
+ $TextReveal.to_render = text
+ if autostart:
+ $TextReveal.start()
+
+func start():
+ $TextReveal.start()
diff --git a/components/textrevealbox.tscn b/components/textrevealbox.tscn
new file mode 100644
index 0000000..386ede7
--- /dev/null
+++ b/components/textrevealbox.tscn
@@ -0,0 +1,17 @@
+[gd_scene load_steps=3 format=2]
+
+[ext_resource path="res://components/textreveal.gd" type="Script" id=1]
+[ext_resource path="res://components/textrevealbox.gd" type="Script" id=2]
+
+[node name="TextrevealBox" type="Node2D"]
+script = ExtResource( 2 )
+
+[node name="TextReveal" type="Label" parent="."]
+margin_left = -54.0
+margin_top = -28.0
+margin_right = 56.0
+margin_bottom = 21.0
+script = ExtResource( 1 )
+__meta__ = {
+"_edit_use_anchors_": false
+}
diff --git a/project.godot b/project.godot
index 4d91ce7..80d51c1 100644
--- a/project.godot
+++ b/project.godot
@@ -29,11 +29,6 @@ _global_script_classes=[ {
"language": "NativeScript",
"path": "res://git_api.gdns"
}, {
-"base": "CanvasLayer",
-"class": "Introduction",
-"language": "GDScript",
-"path": "res://scenes/introduction/introduction.gd"
-}, {
"base": "Node2D",
"class": "Level",
"language": "GDScript",
@@ -54,7 +49,6 @@ _global_script_class_icons={
"CameraTrackFollower": "",
"Card": "",
"GitAPI": "",
-"Introduction": "",
"Level": "",
"PathRenderer": "",
"TextReveal": ""
@@ -117,5 +111,5 @@ quality/intended_usage/framebuffer_allocation=0
quality/intended_usage/framebuffer_allocation.mobile=0
vram_compression/import_etc=true
vram_compression/import_etc2=false
-environment/default_clear_color=Color( 0.00392157, 0.176471, 0.329412, 1 )
+environment/default_clear_color=Color( 0.00392157, 0.0862745, 0.160784, 1 )
environment/default_environment="res://default_env.tres"
diff --git a/scenes/introduction/check_mail.tscn b/scenes/introduction/check_mail.tscn
new file mode 100644
index 0000000..6983820
--- /dev/null
+++ b/scenes/introduction/check_mail.tscn
@@ -0,0 +1,101 @@
+[gd_scene load_steps=6 format=2]
+
+[ext_resource path="res://components/Level.gd" type="Script" id=1]
+[ext_resource path="res://components/card/card.gd" type="Script" id=2]
+[ext_resource path="res://fonts/Flipps_Theme.tres" type="Theme" id=3]
+[ext_resource path="res://components/textrevealbox.tscn" type="PackedScene" id=4]
+[ext_resource path="res://components/button.tscn" type="PackedScene" id=5]
+
+[node name="Level" type="Node2D"]
+script = ExtResource( 1 )
+
+[node name="Card" type="Sprite" parent="."]
+position = Vector2( 640, 320 )
+script = ExtResource( 2 )
+width = 600
+height = 400
+
+[node name="username" type="LineEdit" parent="."]
+margin_left = 534.333
+margin_top = 241.937
+margin_right = 746.333
+margin_bottom = 283.937
+text = "Tom"
+editable = false
+__meta__ = {
+"_edit_use_anchors_": false
+}
+
+[node name="password" type="LineEdit" parent="."]
+margin_left = 534.333
+margin_top = 298.667
+margin_right = 746.333
+margin_bottom = 340.667
+secret = true
+placeholder_text = "Password"
+__meta__ = {
+"_edit_use_anchors_": false
+}
+
+[node name="Log in" parent="." instance=ExtResource( 5 )]
+position = Vector2( 640.861, 400.15 )
+text = "Log in"
+
+[node name="Monolog1" parent="." instance=ExtResource( 4 )]
+position = Vector2( 640, 600 )
+text = "Oh, shit, what was my password again?"
+
+[node name="Monolog2" parent="." instance=ExtResource( 4 )]
+position = Vector2( 640, 600 )
+text = "The password is deeper than *you think*..."
+autostart = false
+
+[node name="Monolog3" parent="." instance=ExtResource( 4 )]
+position = Vector2( 640, 600 )
+text = "The correct password is not incorrect."
+autostart = false
+
+[node name="Instuction" type="RichTextLabel" parent="."]
+margin_left = 963.0
+margin_top = 191.0
+margin_right = 1276.0
+margin_bottom = 420.0
+bbcode_enabled = true
+bbcode_text = "Fill in the form
+with a password
+*you think* is
+correct."
+text = "Fill in the form
+with a password
+*you think* is
+correct."
+__meta__ = {
+"_edit_use_anchors_": false
+}
+
+[node name="Incorrect" type="Label" parent="."]
+visible = false
+margin_left = 535.0
+margin_top = 440.858
+margin_right = 746.0
+margin_bottom = 478.858
+theme = ExtResource( 3 )
+text = "Incorrect."
+align = 1
+__meta__ = {
+"_edit_use_anchors_": false
+}
+
+[node name="DeepMail" type="Label" parent="."]
+margin_left = 534.0
+margin_top = 167.0
+margin_right = 747.0
+margin_bottom = 222.0
+text = "DeepMail"
+align = 1
+__meta__ = {
+"_edit_use_anchors_": false
+}
+[connection signal="text_changed" from="password" to="." method="_on_password_text_changed"]
+[connection signal="text_entered" from="password" to="." method="_on_password_text_entered"]
+[connection signal="on_click" from="Log in" to="." method="_on_Button_on_click"]
diff --git a/scenes/introduction/come home.gd b/scenes/introduction/come home.gd
new file mode 100644
index 0000000..9eb447c
--- /dev/null
+++ b/scenes/introduction/come home.gd
@@ -0,0 +1,4 @@
+extends Node2D
+
+func _on_CanvasLayer_next():
+ get_tree().change_scene("res://scenes/introduction/check_mail.tscn")
diff --git a/scenes/introduction/come home.tscn b/scenes/introduction/come home.tscn
new file mode 100644
index 0000000..c8a53a9
--- /dev/null
+++ b/scenes/introduction/come home.tscn
@@ -0,0 +1,18 @@
+[gd_scene load_steps=3 format=2]
+
+[ext_resource path="res://scenes/introduction/introduction.tscn" type="PackedScene" id=1]
+[ext_resource path="res://scenes/introduction/come home.gd" type="Script" id=2]
+
+[node name="Node2D" type="Node2D"]
+script = ExtResource( 2 )
+
+[node name="CanvasLayer" parent="." instance=ExtResource( 1 )]
+position = Vector2( 640, 360 )
+text = "28.07.2048
+06:26 PM
+
+Oh, what a day was that...
+
+Let's first check my mails now...
+"
+[connection signal="next" from="CanvasLayer" to="." method="_on_CanvasLayer_next"]
diff --git a/scenes/introduction.gd b/scenes/introduction/introduction.gd
index 383091b..f9d60d1 100644
--- a/scenes/introduction.gd
+++ b/scenes/introduction/introduction.gd
@@ -1,21 +1,24 @@
extends Level
+export(String, MULTILINE) var text = ""
+
+signal next()
# Called when the node enters the scene tree for the first time.
func _ready():
$Continue.visible = false
+ $TextReveal.to_render = text
$TextReveal.start()
-
-
func _on_TextReveal_finished_reveal():
$Continue.visible = true
$Skip.visible = false
+func _next():
+ emit_signal("next")
func _on_Button_on_click():
- get_tree().change_scene("res://scenes/levels/base_level.tscn")
-
+ _next()
func _on_Skip_on_click():
- get_tree().change_scene("res://scenes/levels/base_level.tscn")
+ _next()
diff --git a/scenes/introduction.tscn b/scenes/introduction/introduction.tscn
index fc5abc1..9bed978 100644
--- a/scenes/introduction.tscn
+++ b/scenes/introduction/introduction.tscn
@@ -1,12 +1,11 @@
[gd_scene load_steps=5 format=2]
[ext_resource path="res://components/textreveal.gd" type="Script" id=1]
-[ext_resource path="res://scenes/introduction.gd" type="Script" id=2]
+[ext_resource path="res://scenes/introduction/introduction.gd" type="Script" id=2]
[ext_resource path="res://components/button.tscn" type="PackedScene" id=3]
[ext_resource path="res://textures/backgrounds/background_grey.png" type="Texture" id=4]
[node name="CanvasLayer" type="Node2D"]
-position = Vector2( 654.009, 325.417 )
script = ExtResource( 2 )
[node name="background_grey" type="Sprite" parent="."]
@@ -14,34 +13,22 @@ texture = ExtResource( 4 )
[node name="TextReveal" type="Label" parent="."]
margin_left = -500.0
-margin_top = -16.0
+margin_top = -200.0
margin_right = 500.0
-margin_bottom = 366.0
+margin_bottom = 200.0
script = ExtResource( 1 )
__meta__ = {
"_edit_use_anchors_": false
}
-to_render = "Hi Tim,
-
-past monday, the following happend to me:
-
-I played deeper but lighter...
-
-this was just incredible. Try it out yourself.
-
-Kind reguards,
-
-Max"
-speed = 10.0
+to_render = "Failed to load Tex :("
[node name="Continue" parent="." instance=ExtResource( 3 )]
-position = Vector2( 10, 260 )
+position = Vector2( 0, 250 )
text = "Continue"
[node name="Skip" parent="." instance=ExtResource( 3 )]
-position = Vector2( 557.234, 339.165 )
+position = Vector2( 545.262, 293.882 )
text = "Skip"
-
[connection signal="finished_reveal" from="TextReveal" to="." method="_on_TextReveal_finished_reveal"]
[connection signal="on_click" from="Continue" to="." method="_on_Button_on_click"]
[connection signal="on_click" from="Skip" to="." method="_on_Skip_on_click"]
diff --git a/scenes/introduction/mail.gd b/scenes/introduction/mail.gd
new file mode 100644
index 0000000..4a57120
--- /dev/null
+++ b/scenes/introduction/mail.gd
@@ -0,0 +1,5 @@
+extends Node2D
+
+
+func _on_CanvasLayer_next():
+ get_tree().change_scene("res://scenes/levels/base_level.tscn")
diff --git a/scenes/introduction/mail.tscn b/scenes/introduction/mail.tscn
new file mode 100644
index 0000000..383f809
--- /dev/null
+++ b/scenes/introduction/mail.tscn
@@ -0,0 +1,21 @@
+[gd_scene load_steps=3 format=2]
+
+[ext_resource path="res://scenes/introduction/introduction.tscn" type="PackedScene" id=1]
+[ext_resource path="res://scenes/introduction/mail.gd" type="Script" id=2]
+
+[node name="Node2D" type="Node2D"]
+script = ExtResource( 2 )
+
+[node name="CanvasLayer" parent="." instance=ExtResource( 1 )]
+position = Vector2( 640, 360 )
+text = "Hey Tom,
+
+how are you going?
+Did you read that article in the newspaper this
+morning? Barak Obama himself stated to have
+seen some \"mysteriois actions\" around the streets in Washinton.
+They have to do with some data leaks in a datacenter nearby.
+But they could not give any more information, they wrote.
+
+Isn't that strange? I mean those time. Chaotic. Just chaotic."
+[connection signal="next" from="CanvasLayer" to="." method="_on_CanvasLayer_next"]
diff --git a/scenes/menu.gd b/scenes/menu.gd
index 7ce511c..e4f254e 100644
--- a/scenes/menu.gd
+++ b/scenes/menu.gd
@@ -15,4 +15,4 @@ func _on_Strart_on_click():
func _on_Outgoing_animation_finished(anim_name):
- get_tree().change_scene("res://scenes/introduction.tscn")
+ get_tree().change_scene("res://scenes/introduction/come home.tscn")
diff --git a/textures/colors/light_blue.png b/textures/colors/light_blue.png
index 7f571cc..edb2be2 100644
--- a/textures/colors/light_blue.png
+++ b/textures/colors/light_blue.png
Binary files differ
diff --git a/textures/colors/light_blue.xcf b/textures/colors/light_blue.xcf
index 556f961..acbd78d 100644
--- a/textures/colors/light_blue.xcf
+++ b/textures/colors/light_blue.xcf
Binary files differ
diff --git a/textures/components/button/button.png b/textures/components/button/button.png
new file mode 100644
index 0000000..dd9654f
--- /dev/null
+++ b/textures/components/button/button.png
Binary files differ
diff --git a/textures/components/button/button.png.import b/textures/components/button/button.png.import
new file mode 100644
index 0000000..9dcb709
--- /dev/null
+++ b/textures/components/button/button.png.import
@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="StreamTexture"
+path="res://.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.stex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://textures/components/button/button.png"
+dest_files=[ "res://.import/button.png-450ffa012e0be78adf7e3bea997e4f9c.stex" ]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_mode=0
+compress/bptc_ldr=0
+compress/normal_map=0
+flags/repeat=0
+flags/filter=false
+flags/mipmaps=false
+flags/anisotropic=false
+flags/srgb=2
+process/fix_alpha_border=true
+process/premult_alpha=false
+process/HDR_as_SRGB=false
+process/invert_color=false
+stream=false
+size_limit=0
+detect_3d=true
+svg/scale=1.0
diff --git a/textures/components/button/button.xcf b/textures/components/button/button.xcf
new file mode 100644
index 0000000..7074cd9
--- /dev/null
+++ b/textures/components/button/button.xcf
Binary files differ