-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Tiago Treter
authored and
Tiago Treter
committed
Jun 6, 2022
1 parent
7963133
commit 03cc1b6
Showing
28 changed files
with
1,124 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
extends Resource | ||
class_name Dialog | ||
|
||
export(Array, String) var msg_queue: Array |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[ | ||
{"name": "Figura Oculta", "text": "Este será seu novo mundo! Hahahahahaha..."}, | ||
{"name": "Figura Oculta", "text": "Tudo que você precisa saber está diante de seus olhos. Hehehehe..."}, | ||
{"name": "Figura Oculta", "text": "Boa sorte na sua jornada. Hehe"} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[gd_resource type="Resource" load_steps=2 format=2] | ||
|
||
[ext_resource path="res://dialogs/Dialog.gd" type="Script" id=1] | ||
|
||
[resource] | ||
script = ExtResource( 1 ) | ||
msg_queue = [ "Seja muito bem vindo ao seu novo mundo! Hahahahaha..", "Tudo que você precisa saber está diante de seus olhos! Hahahahahahaha.", "Boa sorte na sua jornada. Hehe" ] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[remap] | ||
|
||
importer="texture" | ||
type="StreamTexture" | ||
path="res://.import/master.png-09f75ee96069732eb98ae3bbd4f15ed2.stex" | ||
metadata={ | ||
"vram_texture": false | ||
} | ||
|
||
[deps] | ||
|
||
source_file="res://images/enemy/master_of_the_game/master.png" | ||
dest_files=[ "res://.import/master.png-09f75ee96069732eb98ae3bbd4f15ed2.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=true | ||
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 | ||
process/normal_map_invert_y=false | ||
stream=false | ||
size_limit=0 | ||
detect_3d=true | ||
svg/scale=1.0 |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[remap] | ||
|
||
importer="texture" | ||
type="StreamTexture" | ||
path="res://.import/dialogbox_tile.png-5fbd0a69b414d15d956dafd730a6f34a.stex" | ||
metadata={ | ||
"vram_texture": false | ||
} | ||
|
||
[deps] | ||
|
||
source_file="res://images/fx/dialog/dialogbox_tile.png" | ||
dest_files=[ "res://.import/dialogbox_tile.png-5fbd0a69b414d15d956dafd730a6f34a.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=true | ||
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 | ||
process/normal_map_invert_y=false | ||
stream=false | ||
size_limit=0 | ||
detect_3d=true | ||
svg/scale=1.0 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[remap] | ||
|
||
importer="texture" | ||
type="StreamTexture" | ||
path="res://.import/white_light.png-0c6e06ae9fcea6cd863811b5e5781e47.stex" | ||
metadata={ | ||
"vram_texture": false | ||
} | ||
|
||
[deps] | ||
|
||
source_file="res://images/fx/light/white_light.png" | ||
dest_files=[ "res://.import/white_light.png-0c6e06ae9fcea6cd863811b5e5781e47.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=true | ||
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 | ||
process/normal_map_invert_y=false | ||
stream=false | ||
size_limit=0 | ||
detect_3d=true | ||
svg/scale=1.0 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[remap] | ||
|
||
importer="texture" | ||
type="StreamTexture" | ||
path="res://.import/bg.png-d660b645975eca2240ee5d5d87bab26b.stex" | ||
metadata={ | ||
"vram_texture": false | ||
} | ||
|
||
[deps] | ||
|
||
source_file="res://images/menu/bg.png" | ||
dest_files=[ "res://.import/bg.png-d660b645975eca2240ee5d5d87bab26b.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=true | ||
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 | ||
process/normal_map_invert_y=false | ||
stream=false | ||
size_limit=0 | ||
detect_3d=true | ||
svg/scale=1.0 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[remap] | ||
|
||
importer="texture" | ||
type="StreamTexture" | ||
path="res://.import/pzero.png-86e3dd26249912da8b3b21f3a1c3b7d7.stex" | ||
metadata={ | ||
"vram_texture": false | ||
} | ||
|
||
[deps] | ||
|
||
source_file="res://images/menu/pzero.png" | ||
dest_files=[ "res://.import/pzero.png-86e3dd26249912da8b3b21f3a1c3b7d7.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=true | ||
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 | ||
process/normal_map_invert_y=false | ||
stream=false | ||
size_limit=0 | ||
detect_3d=true | ||
svg/scale=1.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
[gd_scene load_steps=6 format=2] | ||
|
||
[ext_resource path="res://images/fx/dialog/dialogbox_tile.png" type="Texture" id=1] | ||
[ext_resource path="res://images/fonts/game_over.ttf" type="DynamicFontData" id=2] | ||
[ext_resource path="res://scripts/Dialog.gd" type="Script" id=3] | ||
|
||
[sub_resource type="DynamicFont" id=1] | ||
size = 50 | ||
font_data = ExtResource( 2 ) | ||
|
||
[sub_resource type="DynamicFont" id=2] | ||
size = 50 | ||
font_data = ExtResource( 2 ) | ||
|
||
[node name="Dialog" type="CanvasLayer"] | ||
script = ExtResource( 3 ) | ||
|
||
[node name="NinePatchRect" type="NinePatchRect" parent="."] | ||
margin_left = 128.0 | ||
margin_top = 51.0 | ||
margin_right = 896.0 | ||
margin_bottom = 179.0 | ||
texture = ExtResource( 1 ) | ||
patch_margin_left = 16 | ||
patch_margin_top = 16 | ||
patch_margin_right = 16 | ||
patch_margin_bottom = 16 | ||
|
||
[node name="Name" type="RichTextLabel" parent="NinePatchRect"] | ||
margin_left = 7.0 | ||
margin_top = -1.0 | ||
margin_right = 192.0 | ||
margin_bottom = 34.0 | ||
custom_fonts/normal_font = SubResource( 1 ) | ||
text = "Name" | ||
|
||
[node name="Message" type="RichTextLabel" parent="NinePatchRect"] | ||
margin_left = 17.0 | ||
margin_top = 26.0 | ||
margin_right = 751.0 | ||
margin_bottom = 152.0 | ||
custom_fonts/normal_font = SubResource( 2 ) | ||
text = "Message" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
extends NinePatchRect | ||
|
||
onready var text := $Text | ||
onready var timer := $Timer | ||
|
||
var msg_queue: Array = [] | ||
|
||
func _ready() -> void: | ||
text.bbcode_text = "" | ||
|
||
|
||
func _input(event): | ||
if event is InputEventKey and event.is_action_pressed("ui_accept"): | ||
show_message() | ||
|
||
|
||
func add_message(_msg: Array) -> void: | ||
if not visible: | ||
show() | ||
msg_queue.append_array(_msg) | ||
show_message() | ||
|
||
|
||
func show_message() -> void: | ||
if not timer.is_stopped(): | ||
text.visible_characters = text.bbcode_text.length() | ||
return | ||
|
||
if msg_queue.size() == 0: | ||
hide() | ||
return | ||
|
||
var _msg: String = msg_queue.pop_front() | ||
print(_msg) | ||
|
||
text.visible_characters = 0 | ||
text.bbcode_text = _msg | ||
timer.start() | ||
|
||
|
||
func _on_Timer_timeout(): | ||
if text.visible_characters == text.bbcode_text.length(): | ||
timer.stop() | ||
pass | ||
text.visible_characters += 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
[gd_scene load_steps=6 format=2] | ||
|
||
[ext_resource path="res://scenes/DialogBox.gd" type="Script" id=1] | ||
[ext_resource path="res://images/fx/dialog/dialogbox_tile.png" type="Texture" id=2] | ||
[ext_resource path="res://images/fonts/game_over.ttf" type="DynamicFontData" id=3] | ||
|
||
[sub_resource type="DynamicFont" id=1] | ||
font_data = ExtResource( 3 ) | ||
|
||
[sub_resource type="DynamicFont" id=2] | ||
size = 72 | ||
font_data = ExtResource( 3 ) | ||
|
||
[node name="DialogBox" type="NinePatchRect"] | ||
margin_left = 128.0 | ||
margin_top = 384.0 | ||
margin_right = 903.0 | ||
margin_bottom = 512.0 | ||
texture = ExtResource( 2 ) | ||
patch_margin_left = 16 | ||
patch_margin_top = 16 | ||
patch_margin_right = 16 | ||
patch_margin_bottom = 16 | ||
script = ExtResource( 1 ) | ||
|
||
[node name="Text" type="RichTextLabel" parent="."] | ||
margin_left = 29.0 | ||
margin_top = 20.0 | ||
margin_right = 736.0 | ||
margin_bottom = 178.0 | ||
custom_fonts/mono_font = SubResource( 1 ) | ||
custom_fonts/normal_font = SubResource( 2 ) | ||
visible_characters = 0 | ||
tab_size = 6 | ||
scroll_following = true | ||
|
||
[node name="Timer" type="Timer" parent="."] | ||
wait_time = 0.1 | ||
|
||
[connection signal="timeout" from="Timer" to="." method="_on_Timer_timeout"] |
Oops, something went wrong.