worked on the custom dialog system
This commit is contained in:
@@ -21,14 +21,18 @@ Essential="*res://src/essential.cs"
|
||||
|
||||
[display]
|
||||
|
||||
window/size/viewport_width=1260
|
||||
window/size/viewport_height=720
|
||||
window/stretch/mode="canvas_items"
|
||||
window/size/viewport_width=1537
|
||||
window/size/viewport_height=864
|
||||
window/stretch/mode="viewport"
|
||||
|
||||
[dotnet]
|
||||
|
||||
project/assembly_name="RPG Test gd4"
|
||||
|
||||
[editor]
|
||||
|
||||
node_naming/name_casing=2
|
||||
|
||||
[filesystem]
|
||||
|
||||
import/blender/enabled=false
|
||||
|
@@ -4,20 +4,22 @@
|
||||
[ext_resource type="FontFile" uid="uid://cx6bvqk0ghmjv" path="res://assets/font/urbane-rounded-medium.otf" id="1_vlvkg"]
|
||||
|
||||
[node name="dialog_bubble" type="CanvasLayer"]
|
||||
visible = false
|
||||
script = ExtResource("1_txwv4")
|
||||
MyColor = "White"
|
||||
metadata/_edit_use_anchors_ = true
|
||||
|
||||
[node name="ColorRect" type="ColorRect" parent="."]
|
||||
anchors_preset = 12
|
||||
anchor_top = 1.0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 250.0
|
||||
offset_top = -190.0
|
||||
offset_right = -210.0
|
||||
offset_bottom = -20.0
|
||||
anchors_preset = -1
|
||||
anchor_left = 0.163
|
||||
anchor_top = 0.78
|
||||
anchor_right = 0.863
|
||||
anchor_bottom = 0.977
|
||||
offset_left = -0.531006
|
||||
offset_top = 0.0799561
|
||||
offset_right = 0.56897
|
||||
offset_bottom = -0.128052
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 0
|
||||
|
||||
[node name="TextLabel" type="Label" parent="."]
|
||||
anchors_preset = -1
|
||||
@@ -37,10 +39,15 @@ theme_override_font_sizes/font_size = 32
|
||||
text = "This is test text"
|
||||
|
||||
[node name="NameLabel" type="Label" parent="."]
|
||||
offset_left = 252.0
|
||||
offset_top = 532.0
|
||||
offset_right = 302.0
|
||||
offset_bottom = 558.0
|
||||
anchors_preset = -1
|
||||
anchor_left = 0.164
|
||||
anchor_top = 0.782
|
||||
anchor_right = 0.197
|
||||
anchor_bottom = 0.808
|
||||
offset_left = 0.259995
|
||||
offset_top = -0.430054
|
||||
offset_right = -0.39502
|
||||
offset_bottom = 0.0799561
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
theme_override_fonts/font = ExtResource("1_vlvkg")
|
||||
theme_override_font_sizes/font_size = 16
|
||||
|
3
scenes/gui/dialog_trigger_area.tscn
Normal file
3
scenes/gui/dialog_trigger_area.tscn
Normal file
@@ -0,0 +1,3 @@
|
||||
[gd_scene format=3 uid="uid://hkcebwbua6wm"]
|
||||
|
||||
[node name="dialog_trigger_area" type="Area2D"]
|
14
scenes/tiles/dialogdebug_cupcake.tscn
Normal file
14
scenes/tiles/dialogdebug_cupcake.tscn
Normal file
@@ -0,0 +1,14 @@
|
||||
[gd_scene load_steps=3 format=3 uid="uid://h8na2j1qthm4"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://p5ubildre2tg" path="res://assets/textures/debug/cupcake.png" id="1_imilm"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_pchpi"]
|
||||
size = Vector2(64, 58.5)
|
||||
|
||||
[node name="dialogdebug_cupcake" type="StaticBody2D"]
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("1_imilm")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource("RectangleShape2D_pchpi")
|
@@ -3,14 +3,13 @@ using System;
|
||||
|
||||
public partial class dialog_bubble : CanvasLayer
|
||||
{
|
||||
// Called when the node enters the scene tree for the first time.
|
||||
public override void _Ready()
|
||||
{
|
||||
Show();
|
||||
ImportString();
|
||||
}
|
||||
|
||||
// Called every frame. 'delta' is the elapsed time since the previous frame.
|
||||
public override void _Process(double delta)
|
||||
public void ImportString()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
13
src/scene-scripts/gui/dialog_trigger_area.cs
Normal file
13
src/scene-scripts/gui/dialog_trigger_area.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using Godot;
|
||||
using System;
|
||||
|
||||
public partial class dialog_trigger_area : Area2D
|
||||
{
|
||||
[Export(PropertyHint.File, "*json")]
|
||||
string dialogFile;
|
||||
public override void _Ready()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
}
|
@@ -1,11 +1,17 @@
|
||||
[gd_resource type="TileSet" load_steps=3 format=3 uid="uid://txl24cadn8t4"]
|
||||
[gd_resource type="TileSet" load_steps=5 format=3 uid="uid://txl24cadn8t4"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dk7fqaw2b3w1k" path="res://scenes/tiles/first_debug_tile.tscn" id="1_uxmn6"]
|
||||
[ext_resource type="PackedScene" uid="uid://h8na2j1qthm4" path="res://scenes/tiles/dialogdebug_cupcake.tscn" id="2_0cov5"]
|
||||
|
||||
[sub_resource type="TileSetScenesCollectionSource" id="TileSetScenesCollectionSource_h5u31"]
|
||||
resource_name = "test"
|
||||
scenes/0/scene = ExtResource("1_uxmn6")
|
||||
|
||||
[sub_resource type="TileSetScenesCollectionSource" id="TileSetScenesCollectionSource_xv32l"]
|
||||
resource_name = "dialogdebug"
|
||||
scenes/1/scene = ExtResource("2_0cov5")
|
||||
|
||||
[resource]
|
||||
tile_size = Vector2i(64, 64)
|
||||
sources/0 = SubResource("TileSetScenesCollectionSource_h5u31")
|
||||
sources/1 = SubResource("TileSetScenesCollectionSource_xv32l")
|
||||
|
Reference in New Issue
Block a user