ajout des mutation et refonte de l'inspecteur
* ajout des mutations #86 * changement de l'objectif #85 * refonte de l'inspecteur #71 * changement léger de la plantation * les plantes ne donnent que des graines de leurs espèces * refonte partielle du code, refacto
This commit is contained in:
57
gui/game/inspector/framed_info/framed_info.tscn
Normal file
57
gui/game/inspector/framed_info/framed_info.tscn
Normal file
@@ -0,0 +1,57 @@
|
||||
[gd_scene load_steps=7 format=3 uid="uid://dinju2m0oja38"]
|
||||
|
||||
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/ressources/default_theme.tres" id="1_1ddv5"]
|
||||
[ext_resource type="Script" uid="uid://ymn5layeoat8" path="res://gui/game/inspector/framed_info/scripts/framed_info.gd" id="1_7tmbd"]
|
||||
[ext_resource type="Texture2D" uid="uid://bsvxhafoxwmw0" path="res://common/icons/cube-3d-sphere.svg" id="2_7tmbd"]
|
||||
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/ressources/fonts/spincycle_ot.otf" id="3_1ddv5"]
|
||||
|
||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_7tmbd"]
|
||||
bg_color = Color(1, 1, 1, 0.78431374)
|
||||
|
||||
[sub_resource type="LabelSettings" id="LabelSettings_1ddv5"]
|
||||
font = ExtResource("3_1ddv5")
|
||||
font_size = 18
|
||||
|
||||
[node name="FramedInfo" type="PanelContainer"]
|
||||
self_modulate = Color(0.043137256, 0.07450981, 0.14901961, 1)
|
||||
offset_right = 275.0
|
||||
offset_bottom = 94.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 0
|
||||
theme_override_styles/panel = SubResource("StyleBoxFlat_7tmbd")
|
||||
script = ExtResource("1_7tmbd")
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
layout_mode = 2
|
||||
theme = ExtResource("1_1ddv5")
|
||||
|
||||
[node name="HFlowContainer" type="VBoxContainer" parent="MarginContainer"]
|
||||
layout_mode = 2
|
||||
theme_override_constants/separation = 10
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="MarginContainer/HFlowContainer"]
|
||||
layout_mode = 2
|
||||
theme_override_constants/separation = 10
|
||||
|
||||
[node name="Icon" type="TextureRect" parent="MarginContainer/HFlowContainer/HBoxContainer"]
|
||||
unique_name_in_owner = true
|
||||
custom_minimum_size = Vector2(20, 20)
|
||||
layout_mode = 2
|
||||
texture = ExtResource("2_7tmbd")
|
||||
expand_mode = 1
|
||||
stretch_mode = 5
|
||||
|
||||
[node name="Title" type="Label" parent="MarginContainer/HFlowContainer/HBoxContainer"]
|
||||
unique_name_in_owner = true
|
||||
layout_mode = 2
|
||||
text = "On mature"
|
||||
label_settings = SubResource("LabelSettings_1ddv5")
|
||||
|
||||
[node name="Desc" type="RichTextLabel" parent="MarginContainer/HFlowContainer"]
|
||||
unique_name_in_owner = true
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
theme = ExtResource("1_1ddv5")
|
||||
bbcode_enabled = true
|
||||
text = "On mature, do this and that and do this and that and do this and that"
|
||||
fit_content = true
|
||||
10
gui/game/inspector/framed_info/scripts/framed_info.gd
Normal file
10
gui/game/inspector/framed_info/scripts/framed_info.gd
Normal file
@@ -0,0 +1,10 @@
|
||||
extends PanelContainer
|
||||
|
||||
var framed_info :Inspector.FramedInfo = null : set = update_framed_info
|
||||
|
||||
func update_framed_info(f: Inspector.FramedInfo):
|
||||
framed_info = f
|
||||
%Icon.texture = f.icon
|
||||
%Title.text = f.title
|
||||
%Desc.text = f.description
|
||||
self_modulate = f.bg_color
|
||||
@@ -0,0 +1 @@
|
||||
uid://ymn5layeoat8
|
||||
Reference in New Issue
Block a user