Initial Android commit

This commit is contained in:
OleSTEEP 2024-11-10 03:34:28 +03:00
commit 1e2b80c13d
8521 changed files with 231475 additions and 0 deletions

View file

@ -0,0 +1,8 @@
[gd_scene load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Editor/Events/Templates/EventTemplate.tscn" type="PackedScene" id=1]
[node name="ExampleCustomEvent" instance=ExtResource( 1 )]
[node name="OptionsControl" parent="PanelContainer/MarginContainer/VBoxContainer/Header" index="7"]
items = [ "Move Up", null, 0, false, false, 0, 0, null, "", false, "Move Down", null, 0, false, false, 1, 0, null, "", false, "", null, 0, false, false, 2, 0, null, "", false, "Remove", null, 0, false, false, 3, 0, null, "", false ]

View file

@ -0,0 +1,33 @@
tool
extends "res://addons/dialogic/Editor/Events/Parts/EventPart.gd"
onready var input_field = $InputField
func _ready():
input_field.connect("text_changed", self, "_on_InputField_text_changed")
pass
func load_data(data:Dictionary):
.load_data(data)
input_field.text = event_data["my_text_key"]
func get_preview():
return ""
func _on_InputField_text_changed(text):
event_data["my_text_key"] = text
data_changed()

View file

@ -0,0 +1,16 @@
[gd_scene load_steps=3 format=2]
[ext_resource path="res://addons/dialogic/Editor/Events/Parts/Text/CustomLineEdit.tscn" type="PackedScene" id=1]
[ext_resource path="res://addons/dialogic/Example Assets/CustomEvents/EventPart_Example.gd" type="Script" id=2]
[node name="EventPart_Example" type="HBoxContainer"]
margin_right = 40.0
margin_bottom = 40.0
script = ExtResource( 2 )
__meta__ = {
"_edit_use_anchors_": false
}
[node name="InputField" parent="." instance=ExtResource( 1 )]
margin_top = 6.0
margin_bottom = 33.0

View file

@ -0,0 +1,13 @@
extends Node
func handle_event(event_data, dialog_node):
" \n If this event should wait for dialog advance to occur, uncomment the WAITING line \n If this event should block the dialog from continuing, uncomment the WAITINT_INPUT line \n While other states exist, they generally are not neccesary, but include IDLE, TYPING, and ANIMATING \n "
pass
dialog_node._load_next_event()
dialog_node.set_state(dialog_node.state.READY)

View file

@ -0,0 +1,7 @@
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/Fonts/Overlock/Overlock-Black.ttf" type="DynamicFontData" id=1]
[resource]
size = 30
font_data = ExtResource( 1 )

View file

@ -0,0 +1,7 @@
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/Fonts/Overlock/Overlock-Regular.ttf" type="DynamicFontData" id=1]
[resource]
size = 30
font_data = ExtResource( 1 )

View file

@ -0,0 +1,7 @@
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/Fonts/Overlock/Overlock-Italic.ttf" type="DynamicFontData" id=1]
[resource]
size = 30
font_data = ExtResource( 1 )

View file

@ -0,0 +1,7 @@
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/Fonts/Overlock/Overlock-Black.ttf" type="DynamicFontData" id=1]
[resource]
size = 20
font_data = ExtResource( 1 )

View file

@ -0,0 +1,7 @@
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/Fonts/Overlock/Overlock-Black.ttf" type="DynamicFontData" id=1]
[resource]
size = 30
font_data = ExtResource( 1 )

View file

@ -0,0 +1,94 @@
Copyright (c) 2011, Dario Manuel Muhafara (http://www.tipo.net.ar),
with Reserved Font Names "Overlock" "Overlock SC"
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at:
http://scripts.sil.org/OFL
-----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
-----------------------------------------------------------
PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide
development of collaborative font projects, to support the font creation
efforts of academic and linguistic communities, and to provide a free and
open framework in which fonts may be shared and improved in partnership
with others.
The OFL allows the licensed fonts to be used, studied, modified and
redistributed freely as long as they are not sold by themselves. The
fonts, including any derivative works, can be bundled, embedded,
redistributed and/or sold with any software provided that any reserved
names are not used by derivative works. The fonts and derivatives,
however, cannot be released under any other type of license. The
requirement for fonts to remain under this license does not apply
to any document created using the fonts or their derivatives.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this license and clearly marked as such. This may
include source files, build scripts and documentation.
"Reserved Font Name" refers to any names specified as such after the
copyright statement(s).
"Original Version" refers to the collection of Font Software components as
distributed by the Copyright Holder(s).
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to a
new environment.
"Author" refers to any designer, engineer, programmer, technical
writer or other person who contributed to the Font Software.
PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining
a copy of the Font Software, to use, study, copy, merge, embed, modify,
redistribute, and sell modified and unmodified copies of the Font
Software, subject to the following conditions:
1) Neither the Font Software nor any of its individual components,
in Original or Modified Versions, may be sold by itself.
2) Original or Modified Versions of the Font Software may be bundled,
redistributed and/or sold with any software, provided that each copy
contains the above copyright notice and this license. These can be
included either as stand-alone text files, human-readable headers or
in the appropriate machine-readable metadata fields within text or
binary files as long as those fields can be easily viewed by the user.
3) No Modified Version of the Font Software may use the Reserved Font
Name(s) unless explicit written permission is granted by the corresponding
Copyright Holder. This restriction only applies to the primary font name as
presented to the users.
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
Software shall not be used to promote, endorse or advertise any
Modified Version, except to acknowledge the contribution(s) of the
Copyright Holder(s) and the Author(s) or with their explicit written
permission.
5) The Font Software, modified or unmodified, in part or in whole,
must be distributed entirely under this license, and must not be
distributed under any other license. The requirement for fonts to
remain under this license does not apply to any document created
using the Font Software.
TERMINATION
This license becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.

View file

@ -0,0 +1,7 @@
[gd_resource type="DynamicFont" load_steps=2 format=2]
[ext_resource path="res://Fonts/Overlock/Overlock-Black.ttf" type="DynamicFontData" id=1]
[resource]
size = 30
font_data = ExtResource( 1 )

View file

@ -0,0 +1,22 @@
[gd_scene load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/backgrounds/background-2.png" type="Texture" id=1]
[node name="DefaultBackground" type="Panel"]
self_modulate = Color( 1, 1, 1, 0 )
anchor_right = 1.0
anchor_bottom = 1.0
mouse_filter = 2
__meta__ = {
"_edit_use_anchors_": false
}
[node name="TextureRect" type="TextureRect" parent="."]
anchor_right = 1.0
anchor_bottom = 1.0
texture = ExtResource( 1 )
expand = true
stretch_mode = 1
__meta__ = {
"_edit_use_anchors_": false
}

View file

@ -0,0 +1,40 @@
[gd_resource type="Theme" load_steps=7 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/backgrounds/background-2.png" type="Texture" id=1]
[ext_resource path="res://addons/dialogic/Example Assets/Fonts/Overlock/Overlock-Black.ttf" type="DynamicFontData" id=2]
[sub_resource type="DynamicFont" id=5]
font_data = ExtResource( 2 )
[sub_resource type="StyleBoxTexture" id=4]
texture = ExtResource( 1 )
region_rect = Rect2( 0, 0, 1175, 263 )
margin_left = 5.0
margin_right = 5.0
margin_top = 5.0
margin_bottom = 5.0
modulate_color = Color( 1, 1, 1, 0.572549 )
[sub_resource type="StyleBoxTexture" id=1]
texture = ExtResource( 1 )
region_rect = Rect2( 0, 0, 1175, 263 )
margin_left = 5.0
margin_right = 5.0
margin_top = 5.0
margin_bottom = 5.0
[sub_resource type="StyleBoxTexture" id=3]
texture = ExtResource( 1 )
region_rect = Rect2( 0, 0, 1175, 263 )
margin_left = 5.0
margin_right = 5.0
margin_top = 5.0
margin_bottom = 5.0
modulate_color = Color( 0.113725, 0.105882, 0.105882, 0.764706 )
[resource]
Button/colors/font_color = Color( 1, 1, 1, 1 )
Button/fonts/font = SubResource( 5 )
Button/styles/hover = SubResource( 4 )
Button/styles/normal = SubResource( 1 )
Button/styles/pressed = SubResource( 3 )

View file

@ -0,0 +1,22 @@
[gd_scene load_steps=4 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/History/HistoryButton-theme.tres" type="Theme" id=1]
[sub_resource type="DynamicFontData" id=1]
font_path = "res://resources/fonts/TimesNewerRoman-Regular.otf"
[sub_resource type="DynamicFont" id=2]
font_data = SubResource( 1 )
[node name="HistoryButton" type="Button"]
anchor_top = 1.0
anchor_bottom = 1.0
margin_top = -20.0
margin_right = 58.0
theme = ExtResource( 1 )
custom_fonts/font = SubResource( 2 )
disabled = true
text = "History"
__meta__ = {
"_edit_use_anchors_": false
}

View file

@ -0,0 +1,15 @@
[gd_scene load_steps=2 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/History/HistoryButton-theme.tres" type="Theme" id=1]
[node name="HistoryButton" type="Button"]
anchor_top = 1.0
anchor_bottom = 1.0
margin_top = -20.0
margin_right = 58.0
theme = ExtResource( 1 )
disabled = true
text = "Return"
__meta__ = {
"_edit_use_anchors_": false
}

View file

@ -0,0 +1,89 @@
tool
extends PanelContainer
export (NodePath) var Audio_Button_Path = NodePath("HBoxContainer/PlayAudioButton")
export (NodePath) var Text_Label_Path = NodePath("HBoxContainer/RichTextLabel")
var audioPath = ""
var AudioButton
var TextLabel
onready var TextContainer = $HBoxContainer
onready var ColorRectElement = $ColorRect
onready var TextureRectElement = $TextureRect
" \n Example of a HistoryRow. Every time dialog is logged, a new row is created. \n You can extend this class to customize the logging experience as you see fit. \n \n This class can be edited or replaced as long as add_history is implemented \n"
class_name HistoryRow
func _ready():
TextLabel = get_node(Text_Label_Path)
AudioButton = get_node(Audio_Button_Path)
assert (TextLabel is RichTextLabel, "Text_Label must be a rich text label.")
assert (AudioButton is Button, "Audio_Button must be a button.")
func add_history(historyString, newAudio = ""):
TextLabel.append_bbcode(historyString)
audioPath = newAudio
if newAudio != "":
AudioButton.disabled = false
AudioButton.icon = load("res://addons/dialogic/Images/Event Icons/Main Icons/audio-event.svg")
AudioButton.flat = false
else :
AudioButton.disabled = true
AudioButton.focus_mode = FOCUS_NONE
func load_theme(theme:ConfigFile):
var theme_font = DialogicUtil.path_fixer_load(theme.get_value("text", "font", "res://addons/dialogic/Example Assets/Fonts/DefaultFont.tres"))
var alignment = theme.get_value("text", "alignment", 0)
if alignment <= 2:
TextContainer.alignment = BoxContainer.ALIGN_BEGIN
elif alignment <= 5:
TextContainer.alignment = BoxContainer.ALIGN_CENTER
elif alignment <= 8:
TextContainer.alignment = BoxContainer.ALIGN_END
var text_color = Color(theme.get_value("text", "color", "#ffffffff"))
TextLabel.set("custom_colors/default_color", text_color)
TextLabel.set("custom_colors/font_color_shadow", Color("#00ffffff"))
if theme.get_value("text", "shadow", false):
var text_shadow_color = Color(theme.get_value("text", "shadow_color", "#9e000000"))
TextLabel.set("custom_colors/font_color_shadow", text_shadow_color)
var shadow_offset = theme.get_value("text", "shadow_offset", Vector2(2, 2))
TextLabel.set("custom_constants/shadow_offset_x", shadow_offset.x)
TextLabel.set("custom_constants/shadow_offset_y", shadow_offset.y)
var text_margin = theme.get_value("text", "margin", Vector2(20, 10))
TextContainer.set("margin_left", text_margin.x)
TextContainer.set("margin_right", text_margin.x * - 1)
TextContainer.set("margin_top", text_margin.y)
TextContainer.set("margin_bottom", text_margin.y * - 1)
TextureRectElement.texture = DialogicUtil.path_fixer_load(theme.get_value("background", "image", "res://addons/dialogic/Example Assets/backgrounds/background-2.png"))
ColorRectElement.color = Color(theme.get_value("background", "color", "#ff000000"))
if theme.get_value("background", "modulation", false):
TextureRectElement.modulate = Color(theme.get_value("background", "modulation_color", "#ffffffff"))
else :
TextureRectElement.modulate = Color("#ffffffff")
ColorRectElement.visible = theme.get_value("background", "use_color", false)
TextureRectElement.visible = theme.get_value("background", "use_image", true)

View file

@ -0,0 +1,96 @@
[gd_scene load_steps=9 format=2]
[ext_resource path="res://addons/dialogic/Example Assets/History/HistoryRow.gd" type="Script" id=1]
[ext_resource path="res://addons/dialogic/Example Assets/backgrounds/background-2.png" type="Texture" id=2]
[sub_resource type="DynamicFontData" id=1]
font_path = "res://resources/fonts/TimesNewerRoman-Italic.otf"
[sub_resource type="DynamicFont" id=2]
size = 32
font_data = SubResource( 1 )
[sub_resource type="DynamicFontData" id=3]
font_path = "res://resources/fonts/TimesNewerRoman-Bold.otf"
[sub_resource type="DynamicFont" id=4]
size = 32
font_data = SubResource( 3 )
[sub_resource type="DynamicFontData" id=5]
font_path = "res://resources/fonts/TimesNewerRoman-Regular.otf"
[sub_resource type="DynamicFont" id=6]
size = 32
font_data = SubResource( 5 )
[node name="HistoryRow" type="PanelContainer"]
self_modulate = Color( 1, 1, 1, 0 )
rect_min_size = Vector2( 0, 28 )
size_flags_horizontal = 3
size_flags_vertical = 0
script = ExtResource( 1 )
[node name="ColorRect" type="ColorRect" parent="."]
visible = false
margin_left = 7.0
margin_top = 7.0
margin_right = 51.0
margin_bottom = 43.0
__meta__ = {
"_edit_use_anchors_": false
}
[node name="TextureRect" type="TextureRect" parent="."]
margin_left = 7.0
margin_top = 7.0
margin_right = 51.0
margin_bottom = 47.0
texture = ExtResource( 2 )
expand = true
stretch_mode = 1
__meta__ = {
"_edit_use_anchors_": false
}
[node name="HBoxContainer" type="HBoxContainer" parent="."]
margin_left = 7.0
margin_top = 7.0
margin_right = 51.0
margin_bottom = 47.0
size_flags_horizontal = 11
size_flags_vertical = 3
custom_constants/separation = 8
__meta__ = {
"_edit_use_anchors_": false
}
[node name="PlayAudioButton" type="Button" parent="HBoxContainer"]
margin_top = 2.0
margin_right = 36.0
margin_bottom = 38.0
rect_min_size = Vector2( 36, 36 )
size_flags_horizontal = 4
size_flags_vertical = 4
flat = true
expand_icon = true
__meta__ = {
"_edit_use_anchors_": false
}
[node name="RichTextLabel" type="RichTextLabel" parent="HBoxContainer"]
margin_left = 44.0
margin_right = 44.0
margin_bottom = 40.0
size_flags_horizontal = 3
size_flags_vertical = 3
custom_fonts/italics_font = SubResource( 2 )
custom_fonts/bold_font = SubResource( 4 )
custom_fonts/normal_font = SubResource( 6 )
bbcode_enabled = true
meta_underlined = false
fit_content_height = true
scroll_active = false
__meta__ = {
"_edit_use_anchors_": false
}

Binary file not shown.

View file

@ -0,0 +1,4 @@
Copyright (c) 2020 Tim Krief.
Typing sound effects by Tim Krief are licensed under a Creative
Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) License.

View file

@ -0,0 +1,12 @@
[gd_resource type="StyleBoxFlat" format=2]
[resource]
bg_color = Color( 0.160784, 0.160784, 0.160784, 1 )
corner_radius_top_left = 2
corner_radius_top_right = 2
corner_radius_bottom_right = 2
corner_radius_bottom_left = 2
expand_margin_left = 5.0
expand_margin_right = 5.0
expand_margin_top = 5.0
expand_margin_bottom = 5.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.5 KiB