mirror of
https://github.com/git-learning-game/oh-my-git.git
synced 2024-12-22 20:32:38 +01:00
Show level name above description
This commit is contained in:
parent
0b4c4f9449
commit
d555612791
2 changed files with 21 additions and 8 deletions
1
main.gd
1
main.gd
|
@ -60,6 +60,7 @@ func load_level(id):
|
|||
|
||||
var description = game.read_file(level_prefix+level+"/description")
|
||||
$LevelDescription.bbcode_text = description
|
||||
$LevelName.text = level
|
||||
|
||||
# We're actually destroying stuff here.
|
||||
# Make sure that active_repository is in a temporary directory.
|
||||
|
|
28
main.tscn
28
main.tscn
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=8 format=2]
|
||||
[gd_scene load_steps=9 format=2]
|
||||
|
||||
[ext_resource path="res://terminal.tscn" type="PackedScene" id=1]
|
||||
[ext_resource path="res://main.gd" type="Script" id=2]
|
||||
|
@ -6,6 +6,7 @@
|
|||
[ext_resource path="res://styles/alert_button.tres" type="StyleBox" id=4]
|
||||
[ext_resource path="res://fonts/default.tres" type="DynamicFont" id=5]
|
||||
[ext_resource path="res://text_editor.gd" type="Script" id=6]
|
||||
[ext_resource path="res://fonts/big.tres" type="DynamicFont" id=7]
|
||||
|
||||
[sub_resource type="StyleBoxFlat" id=1]
|
||||
bg_color = Color( 0.847059, 0.0666667, 0.0666667, 1 )
|
||||
|
@ -29,10 +30,10 @@ __meta__ = {
|
|||
[node name="Terminal" parent="." instance=ExtResource( 1 )]
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
margin_left = 1223.0
|
||||
margin_top = 484.0
|
||||
margin_right = 1898.0
|
||||
margin_bottom = 1059.0
|
||||
margin_left = 1218.0
|
||||
margin_top = 607.0
|
||||
margin_right = 1913.0
|
||||
margin_bottom = 1071.0
|
||||
|
||||
[node name="TextEditor" type="TextEdit" parent="."]
|
||||
visible = false
|
||||
|
@ -104,11 +105,22 @@ size_flags_horizontal = 3
|
|||
size_flags_vertical = 3
|
||||
label = "Your repository"
|
||||
|
||||
[node name="LevelName" type="RichTextLabel" parent="."]
|
||||
margin_left = 1224.0
|
||||
margin_top = 62.0
|
||||
margin_right = 1889.0
|
||||
margin_bottom = 128.0
|
||||
custom_fonts/normal_font = ExtResource( 7 )
|
||||
text = "Level name here!"
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="LevelDescription" type="RichTextLabel" parent="."]
|
||||
margin_left = 1224.0
|
||||
margin_top = 58.0
|
||||
margin_right = 1889.0
|
||||
margin_bottom = 472.0
|
||||
margin_top = 121.0
|
||||
margin_right = 1908.0
|
||||
margin_bottom = 605.0
|
||||
custom_fonts/normal_font = ExtResource( 5 )
|
||||
bbcode_enabled = true
|
||||
bbcode_text = "Level description here!"
|
||||
|
|
Loading…
Reference in a new issue