moved chat to new ChatPanel and added smooth bottom scrolling when new message is received
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://docnx7algl78k"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://bacaxh2y0sjss" path="res://ui/chat_message.gd" id="1_vmwh1"]
|
||||
|
||||
[node name="ChatMessage" type="MarginContainer" node_paths=PackedStringArray("text_label")]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
theme_override_constants/margin_left = 4
|
||||
theme_override_constants/margin_top = 2
|
||||
theme_override_constants/margin_right = 4
|
||||
theme_override_constants/margin_bottom = 2
|
||||
script = ExtResource("1_vmwh1")
|
||||
text_label = NodePath("MarginContainer/Label")
|
||||
|
||||
[node name="ColorRect" type="ColorRect" parent="."]
|
||||
show_behind_parent = true
|
||||
layout_mode = 2
|
||||
color = Color(1, 0.33, 0.33, 1)
|
||||
metadata/_edit_use_anchors_ = true
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
layout_mode = 2
|
||||
theme_override_constants/margin_left = 2
|
||||
theme_override_constants/margin_top = 2
|
||||
theme_override_constants/margin_right = 2
|
||||
theme_override_constants/margin_bottom = 2
|
||||
|
||||
[node name="Label" type="Label" parent="MarginContainer"]
|
||||
custom_minimum_size = Vector2(20, 10)
|
||||
layout_mode = 2
|
||||
text = "asdf asdufasdoiufoias doifaosid ofiuasoi djhfas df as f"
|
||||
autowrap_mode = 3
|
||||
Reference in New Issue
Block a user