diff --git a/Main_menu.gd b/Main_menu.gd index ae43b82..e936f08 100644 --- a/Main_menu.gd +++ b/Main_menu.gd @@ -47,16 +47,21 @@ func _process(_delta): else: # Set the Play_button to "Update" $Panel/Play_button.text = "Update" + + # Set the Local_version label + if local_version: + $Panel/Panel/Local_version.text = "Local Version: "+local_version + + if newest_version: + $Panel/Panel/Online_version.text = "Online Version: "+newest_version # When everything is loaded, func _ready(): # Randomize random = RandomNumberGenerator.new() random.randomize() - # Choose a background var background_num = random.randi_range(1, 2) - # Set the background $Background.texture = load("res://textures/backgrounds/background"+str(background_num)+".png") diff --git a/Main_menu.tscn b/Main_menu.tscn index 5260e87..7438073 100644 --- a/Main_menu.tscn +++ b/Main_menu.tscn @@ -1,12 +1,13 @@ -[gd_scene load_steps=13 format=2] +[gd_scene load_steps=15 format=2] -[ext_resource path="res://textures/backgrounds/background2.png" type="Texture" id=1] +[ext_resource path="res://textures/backgrounds/background1.png" type="Texture" id=1] [ext_resource path="res://fonts/SPACEBAR.ttf" type="DynamicFontData" id=2] [ext_resource path="res://Main_menu.gd" type="Script" id=3] [ext_resource path="res://fonts/Title-font.tres" type="DynamicFont" id=4] [ext_resource path="res://themes/Base_theme.tres" type="Theme" id=5] [ext_resource path="res://fonts/SPACE.tres" type="DynamicFont" id=6] [ext_resource path="res://ProgressBar.gd" type="Script" id=7] +[ext_resource path="res://fonts/retro_gaming.tres" type="DynamicFont" id=8] [sub_resource type="Theme" id=1] default_font = ExtResource( 4 ) @@ -38,6 +39,16 @@ corner_radius_top_right = 8 corner_radius_bottom_right = 8 corner_radius_bottom_left = 8 +[sub_resource type="StyleBoxFlat" id=7] +bg_color = Color( 0.113725, 0.0941176, 0.196078, 1 ) +border_width_left = 10 +border_width_right = 5 +border_color = Color( 0.0823529, 0.0745098, 0.117647, 1 ) +corner_radius_top_left = 4 +corner_radius_top_right = 4 +corner_radius_bottom_right = 4 +corner_radius_bottom_left = 4 + [node name="Main_menu" type="Control"] anchor_right = 1.0 anchor_bottom = 1.0 @@ -96,6 +107,27 @@ custom_styles/fg = SubResource( 6 ) value = 20.0 script = ExtResource( 7 ) +[node name="Panel" type="Panel" parent="Panel"] +margin_top = 24.0 +margin_right = 280.0 +margin_bottom = 72.0 +custom_styles/panel = SubResource( 7 ) + +[node name="Local_version" type="Label" parent="Panel/Panel"] +margin_left = 24.0 +margin_right = 272.0 +margin_bottom = 24.0 +custom_fonts/font = ExtResource( 8 ) +text = "Local Version:" + +[node name="Online_version" type="Label" parent="Panel/Panel"] +margin_left = 16.0 +margin_top = 24.0 +margin_right = 272.0 +margin_bottom = 48.0 +custom_fonts/font = ExtResource( 8 ) +text = "Online Version:" + [node name="Notices" type="VBoxContainer" parent="."] margin_top = 80.0 margin_right = 192.0