added a cheat console
This commit is contained in:
34
scenes/gui/console.tscn
Normal file
34
scenes/gui/console.tscn
Normal file
@@ -0,0 +1,34 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://bt4pohi6srcvi"]
|
||||
|
||||
[ext_resource type="Script" path="res://src/scene-scripts/console.cs" id="1_c6bre"]
|
||||
|
||||
[node name="console" type="CanvasLayer"]
|
||||
script = ExtResource("1_c6bre")
|
||||
|
||||
[node name="panel_container" type="PanelContainer" parent="."]
|
||||
anchors_preset = 10
|
||||
anchor_right = 1.0
|
||||
grow_horizontal = 2
|
||||
|
||||
[node name="v_box_container" type="VBoxContainer" parent="panel_container"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="rich_text_label" type="RichTextLabel" parent="panel_container/v_box_container"]
|
||||
custom_minimum_size = Vector2(0, 150)
|
||||
layout_mode = 2
|
||||
bbcode_enabled = true
|
||||
scroll_following = true
|
||||
|
||||
[node name="line_edit" type="LineEdit" parent="panel_container/v_box_container"]
|
||||
layout_mode = 2
|
||||
placeholder_text = "Type in cheat or command. Use \"help\" for help."
|
||||
max_length = 200
|
||||
clear_button_enabled = true
|
||||
flat = true
|
||||
draw_control_chars = true
|
||||
select_all_on_focus = true
|
||||
caret_blink = true
|
||||
caret_blink_interval = 0.5
|
||||
caret_force_displayed = true
|
||||
|
||||
[connection signal="text_submitted" from="panel_container/v_box_container/line_edit" to="." method="OnLineEditTextSubmitted"]
|
@@ -1,8 +1,9 @@
|
||||
[gd_scene load_steps=14 format=3 uid="uid://bxaheg7l4h1ip"]
|
||||
[gd_scene load_steps=15 format=3 uid="uid://bxaheg7l4h1ip"]
|
||||
|
||||
[ext_resource type="Script" path="res://src/scene-scripts/player.cs" id="1_qehox"]
|
||||
[ext_resource type="Texture2D" uid="uid://olceowuycu8c" path="res://assets/textures/debug/dummy-player-atlas.png" id="2_yu1q5"]
|
||||
[ext_resource type="PackedScene" uid="uid://bkm7365u1mm3o" path="res://scenes/gui/dialog_bubble.tscn" id="3_8f573"]
|
||||
[ext_resource type="PackedScene" uid="uid://bt4pohi6srcvi" path="res://scenes/gui/console.tscn" id="4_kw3hh"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_tokqm"]
|
||||
atlas = ExtResource("2_yu1q5")
|
||||
@@ -139,3 +140,6 @@ position = Vector2(0, 38)
|
||||
rotation = 1.57345
|
||||
shape = SubResource("CapsuleShape2D_38v5o")
|
||||
metadata/_edit_lock_ = true
|
||||
|
||||
[node name="console" parent="." instance=ExtResource("4_kw3hh")]
|
||||
visible = false
|
||||
|
Reference in New Issue
Block a user