4 Commits

Author SHA1 Message Date
c2d6429cbc clean up 2026-06-21 11:22:08 +02:00
d71b6a5be7 add blend time 2026-06-21 11:12:57 +02:00
ee6fe2ab89 update human models and animations 2026-06-21 11:11:01 +02:00
196a238f5c add new models and rig and handle multiple navigation region 2026-06-19 23:05:14 +02:00
160 changed files with 442 additions and 5992 deletions

View File

@@ -1,8 +0,0 @@
@tool
extends Control
@onready var container_frame: VBoxContainer = %ContainerFrame
func add_companion_dock(companion_dock: Control) -> void:
container_frame.add_child(companion_dock)

View File

@@ -1 +0,0 @@
uid://1oo0gvamoxgp

View File

@@ -1,125 +0,0 @@
[gd_scene load_steps=6 format=3 uid="uid://cyniebd6yahu5"]
[ext_resource type="Script" uid="uid://1oo0gvamoxgp" path="res://addons/godotsteam/editor/steamworks_panel.gd" id="1_qn6cd"]
[ext_resource type="Script" uid="uid://b4nvgu7h84u53" path="res://addons/godotsteam/editor/updates/updates.gd" id="2_qn6cd"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_qn6cd"]
content_margin_top = 2.0
content_margin_bottom = 2.0
bg_color = Color(0.0980392, 0.0980392, 0.0980392, 1)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_qf1vo"]
content_margin_top = 2.0
content_margin_bottom = 2.0
bg_color = Color(0.337255, 0.619608, 1, 1)
[sub_resource type="Theme" id="Theme_sqmbs"]
ProgressBar/styles/background = SubResource("StyleBoxFlat_qn6cd")
ProgressBar/styles/fill = SubResource("StyleBoxFlat_qf1vo")
[node name="Steamworks" type="Control"]
process_mode = 3
custom_minimum_size = Vector2(0, 150)
layout_mode = 3
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
script = ExtResource("1_qn6cd")
metadata/_edit_lock_ = true
[node name="Scroller" type="ScrollContainer" parent="."]
custom_minimum_size = Vector2(0, 150)
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
metadata/_edit_lock_ = true
[node name="DockFrame" type="TabContainer" parent="Scroller"]
unique_name_in_owner = true
layout_mode = 2
size_flags_horizontal = 3
size_flags_vertical = 3
current_tab = 0
metadata/_edit_lock_ = true
[node name="Updates" type="MarginContainer" parent="Scroller/DockFrame"]
unique_name_in_owner = true
layout_mode = 2
theme_override_constants/margin_left = 10
theme_override_constants/margin_top = 10
theme_override_constants/margin_right = 10
theme_override_constants/margin_bottom = 10
script = ExtResource("2_qn6cd")
metadata/_tab_index = 0
metadata/_edit_lock_ = true
[node name="ContainerFrame" type="VBoxContainer" parent="Scroller/DockFrame/Updates"]
unique_name_in_owner = true
layout_mode = 2
theme_override_constants/separation = 10
metadata/_edit_lock_ = true
[node name="HFrame" type="HBoxContainer" parent="Scroller/DockFrame/Updates/ContainerFrame"]
layout_mode = 2
theme_override_constants/separation = 25
metadata/_edit_lock_ = true
[node name="Type" type="Label" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame"]
custom_minimum_size = Vector2(125, 25)
layout_mode = 2
text = "GodotSteam"
metadata/_edit_lock_ = true
[node name="InstalledLabel" type="Label" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame"]
unique_name_in_owner = true
layout_mode = 2
text = "Installed version 4.18"
metadata/_edit_lock_ = true
[node name="UpdateLabel" type="Label" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame"]
unique_name_in_owner = true
layout_mode = 2
metadata/_edit_lock_ = true
[node name="Updating" type="HBoxContainer" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame"]
layout_mode = 2
size_flags_horizontal = 10
theme_override_constants/separation = 25
metadata/_edit_lock_ = true
[node name="Downloading" type="ProgressBar" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame/Updating"]
unique_name_in_owner = true
visible = false
custom_minimum_size = Vector2(200, 30)
layout_mode = 2
theme = SubResource("Theme_sqmbs")
step = 1.0
rounded = true
metadata/_edit_lock_ = true
[node name="InstallButton" type="Button" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame/Updating"]
unique_name_in_owner = true
visible = false
layout_mode = 2
text = "Install"
metadata/_edit_lock_ = true
[node name="UpdateButton" type="Button" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame/Updating"]
unique_name_in_owner = true
layout_mode = 2
size_flags_horizontal = 8
disabled = true
text = "Up-to-date"
metadata/_edit_lock_ = true
[node name="CancelButton" type="Button" parent="Scroller/DockFrame/Updates/ContainerFrame/HFrame/Updating"]
unique_name_in_owner = true
visible = false
layout_mode = 2
text = "Cancel"
metadata/_edit_lock_ = true

View File

@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0,0,256,256" width="50px" height="50px" fill-rule="nonzero"><g fill="#ffffff" fill-rule="nonzero" stroke="none" stroke-width="1" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="10" stroke-dasharray="" stroke-dashoffset="0" font-family="none" font-weight="none" font-size="none" text-anchor="none" style="mix-blend-mode: normal"><g transform="scale(5.12,5.12)"><path d="M25,3c-11.41,0 -20.79062,8.68078 -21.89062,19.80078l11.19141,5.72852c1.13,-0.95 2.59922,-1.5293 4.19922,-1.5293h0.05078c0.39,-0.6 0.83859,-1.35086 1.30859,-2.13086c0.98,-1.61 2.08016,-3.43008 3.16016,-4.83008c0.24,-4.47 3.95047,-8.03906 8.48047,-8.03906c4.69,0 8.5,3.81 8.5,8.5c0,4.53 -3.56906,8.24047 -8.03906,8.48047c-1.4,1.08 -3.21008,2.18039 -4.83008,3.15039c-0.78,0.48 -1.53086,0.92836 -2.13086,1.31836v0.05078c0,3.59 -2.91,6.5 -6.5,6.5c-3.59,0 -6.5,-2.91 -6.5,-6.5c0,-0.17 0.00953,-0.33 0.01953,-0.5l-8.74023,-4.48047c1.69,10.48 10.7707,18.48047 21.7207,18.48047c12.15,0 22,-9.85 22,-22c0,-12.15 -9.85,-22 -22,-22zM31.5,14c-3.58,0 -6.5,2.92 -6.5,6.5c0,3.58 2.92,6.5 6.5,6.5c3.58,0 6.5,-2.92 6.5,-6.5c0,-3.58 -2.92,-6.5 -6.5,-6.5zM31.5,16c2.49,0 4.5,2.01 4.5,4.5c0,2.49 -2.01,4.5 -4.5,4.5c-2.49,0 -4.5,-2.01 -4.5,-4.5c0,-2.49 2.01,-4.5 4.5,-4.5zM18.5,29c-0.79,0 -1.53969,0.20031 -2.17969,0.57031l3.32031,1.69922c1.23,0.63 1.70984,2.14109 1.08984,3.37109c-0.45,0.86 -1.32047,1.35938 -2.23047,1.35938c-0.39,0 -0.77062,-0.08953 -1.14062,-0.26953l-3.33008,-1.71094c0.26,2.24 2.1607,3.98047 4.4707,3.98047c2.49,0 4.5,-2.01 4.5,-4.5c0,-2.49 -2.01,-4.5 -4.5,-4.5z"></path></g></g></svg>

Before

Width:  |  Height:  |  Size: 1.6 KiB

View File

@@ -1,43 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://dhn3vkdxvetbn"
path="res://.godot/imported/steam.svg-1c1b1c87b286630e8735047e7af015ac.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://addons/godotsteam/editor/ui/steam.svg"
dest_files=["res://.godot/imported/steam.svg-1c1b1c87b286630e8735047e7af015ac.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1
svg/scale=1.0
editor/scale_with_editor_scale=false
editor/convert_colors_with_editor_theme=false

View File

@@ -1,59 +0,0 @@
@tool
extends ConfirmationDialog
signal cancel_update
signal continue_update
@onready var cancel_button: Button = %Cancel
@onready var continue_button: Button = %Continue
@onready var downloading: ProgressBar = %Downloading
@onready var message: Label = %Message
@onready var version_title: Label = %VersionTitle
func _ready() -> void:
connect_signals()
set_defaults()
#region Setup
func set_defaults() -> void:
size = Vector2(450, 330)
get_ok_button().visible = false
get_cancel_button().visible = false
#endregion
#region Signals
func connect_signals() -> void:
cancel_button.pressed.connect(_on_cancel_pressed)
continue_button.pressed.connect(_on_continue_pressed)
func _on_cancel_pressed() -> void:
cancel_update.emit()
queue_free()
func _on_continue_pressed() -> void:
continue_update.emit()
#endregion
#region Updating text
func update_interface(version_string: String, is_downloader: bool) -> void:
if not is_node_ready(): await ready
cancel_button.visible = true
continue_button.visible = not is_downloader
downloading.visible = is_downloader
if is_downloader:
message.text = "You are downloading the update, please wait. Closing this window will cancel the update."
version_title.text = "Downloading GodotSteam %s" % version_string
else:
message.text = "You are about to update plug-in version to %s. The editor will restart at the end of this process." % version_string
version_title.text = "Update To GodotSteam %s" % version_string
func update_progress(new_percentage: int) -> void:
downloading.value = new_percentage
#endregion

View File

@@ -1 +0,0 @@
uid://bjb747gou4fbo

View File

@@ -1,174 +0,0 @@
[gd_scene format=3 uid="uid://bb6pyk4s77qvo"]
[ext_resource type="Script" uid="uid://bjb747gou4fbo" path="res://addons/godotsteam/editor/updates/confirmation.gd" id="1_fskym"]
[ext_resource type="Texture2D" uid="uid://dhn3vkdxvetbn" path="res://addons/godotsteam/editor/ui/steam.svg" id="1_xklt4"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_cnr4s"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_jjufo"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_fskym"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_0ql43"]
content_margin_left = 10.0
content_margin_top = 5.0
content_margin_right = 10.0
content_margin_bottom = 5.0
bg_color = Color(0.3372549, 0.61960787, 1, 1)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_apu4b"]
content_margin_left = 10.0
content_margin_top = 5.0
content_margin_right = 10.0
content_margin_bottom = 5.0
bg_color = Color(0.09803922, 0.09803922, 0.09803922, 1)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_bi3ss"]
content_margin_left = 10.0
content_margin_top = 5.0
content_margin_right = 10.0
content_margin_bottom = 5.0
bg_color = Color(0, 0, 0, 1)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_cnr4s"]
content_margin_top = 2.0
content_margin_bottom = 2.0
bg_color = Color(0.09803922, 0.09803922, 0.09803922, 1)
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_jjufo"]
content_margin_top = 2.0
content_margin_bottom = 2.0
bg_color = Color(0.3372549, 0.61960787, 1, 1)
[sub_resource type="Theme" id="Theme_cnr4s"]
AcceptDialog/constants/title_height = 0
AcceptDialog/styles/embedded_border = SubResource("StyleBoxEmpty_cnr4s")
AcceptDialog/styles/embedded_unfocused_border = SubResource("StyleBoxEmpty_jjufo")
AcceptDialog/styles/panel = SubResource("StyleBoxEmpty_fskym")
Button/colors/font_color = Color(1, 1, 1, 1)
Button/styles/hover = SubResource("StyleBoxFlat_0ql43")
Button/styles/normal = SubResource("StyleBoxFlat_apu4b")
Button/styles/pressed = SubResource("StyleBoxFlat_bi3ss")
ProgressBar/styles/background = SubResource("StyleBoxFlat_cnr4s")
ProgressBar/styles/fill = SubResource("StyleBoxFlat_jjufo")
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_fskym"]
bg_color = Color(0.15686275, 0.15686275, 0.15686275, 1)
border_width_bottom = 3
border_color = Color(0.3372549, 0.61960787, 1, 1)
[node name="Confirmation" type="ConfirmationDialog" unique_id=1649782113]
transparent_bg = true
oversampling_override = 1.0
title = "Updating GodotSteam"
initial_position = 1
size = Vector2i(450, 330)
visible = true
wrap_controls = false
unresizable = true
borderless = true
min_size = Vector2i(450, 200)
keep_title_visible = false
content_scale_mode = 1
theme = SubResource("Theme_cnr4s")
ok_button_text = "Continue"
dialog_hide_on_ok = false
dialog_close_on_escape = false
script = ExtResource("1_fskym")
metadata/_edit_lock_ = true
[node name="Panel" type="Panel" parent="." unique_id=336687509]
custom_minimum_size = Vector2(450, 330)
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -225.0
offset_top = -165.0
offset_right = 225.0
offset_bottom = 165.0
grow_horizontal = 2
grow_vertical = 2
size_flags_horizontal = 4
size_flags_vertical = 4
theme_override_styles/panel = SubResource("StyleBoxFlat_fskym")
metadata/_edit_lock_ = true
[node name="Margin" type="MarginContainer" parent="Panel" unique_id=598549467]
custom_minimum_size = Vector2(450, 330)
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
theme_override_constants/margin_left = 50
theme_override_constants/margin_top = 50
theme_override_constants/margin_right = 50
theme_override_constants/margin_bottom = 50
metadata/_edit_lock_ = true
[node name="VFrame" type="VBoxContainer" parent="Panel/Margin" unique_id=7442794]
layout_mode = 2
theme_override_constants/separation = 15
metadata/_edit_lock_ = true
[node name="HFrame" type="HBoxContainer" parent="Panel/Margin/VFrame" unique_id=1314013334]
layout_mode = 2
theme_override_constants/separation = 15
metadata/_edit_lock_ = true
[node name="Icon" type="TextureRect" parent="Panel/Margin/VFrame/HFrame" unique_id=521288466]
custom_minimum_size = Vector2(26, 30)
layout_mode = 2
texture = ExtResource("1_xklt4")
expand_mode = 1
stretch_mode = 5
metadata/_edit_lock_ = true
[node name="VersionTitle" type="Label" parent="Panel/Margin/VFrame/HFrame" unique_id=906249057]
unique_name_in_owner = true
custom_minimum_size = Vector2(275, 30)
layout_mode = 2
theme_override_colors/font_outline_color = Color(1, 1, 1, 1)
theme_override_constants/outline_size = 1
theme_override_font_sizes/font_size = 18
text = "Downloading GodotSteam 99.99"
metadata/_edit_lock_ = true
[node name="Message" type="Label" parent="Panel/Margin/VFrame" unique_id=345793881]
unique_name_in_owner = true
custom_minimum_size = Vector2(315, 85)
layout_mode = 2
size_flags_vertical = 0
text = "You are about to update plug-in version to %s. The editor will restart at the end of this process."
autowrap_mode = 3
metadata/_edit_lock_ = true
[node name="Downloading" type="ProgressBar" parent="Panel/Margin/VFrame" unique_id=1922739661]
unique_name_in_owner = true
custom_minimum_size = Vector2(0, 30)
layout_mode = 2
step = 1.0
value = 50.0
metadata/_edit_lock_ = true
[node name="Options" type="HBoxContainer" parent="Panel/Margin/VFrame" unique_id=2126576529]
layout_mode = 2
size_flags_vertical = 10
theme_override_constants/separation = 15
alignment = 2
metadata/_edit_lock_ = true
[node name="Continue" type="Button" parent="Panel/Margin/VFrame/Options" unique_id=851000998]
unique_name_in_owner = true
layout_mode = 2
text = "Continue"
metadata/_edit_lock_ = true
[node name="Cancel" type="Button" parent="Panel/Margin/VFrame/Options" unique_id=1895267580]
unique_name_in_owner = true
layout_mode = 2
text = "Cancel"
metadata/_edit_lock_ = true

View File

@@ -1,186 +0,0 @@
@tool
extends MarginContainer
###
# Super-huge thanks to Nathan Hoad and Marcus Skov for ideas and inspiration on how to create a
# plug-in updater.
###
const TEMP_FILE = "user://update.zip"
const VERSION_URL: StringName = "https://godotengine.org/asset-library/api/asset/2445"
var download_location: String = ""
var downloading_update: bool = false
# This will act as both our version checker and update downloader
var http_request: HTTPRequest = null
var is_actively_downloading: bool = false
var new_version: String = ""
@onready var cancel_button: Button = %CancelButton
@onready var downloading: ProgressBar = %Downloading
@onready var install_button: Button = %InstallButton
@onready var installed_label: Label = %InstalledLabel
@onready var update_label: Label = %UpdateLabel
@onready var update_button: Button = %UpdateButton
func _ready() -> void:
connect_signals()
set_defaults()
check_for_updates()
func _process(delta: float) -> void:
if is_actively_downloading:
downloading.value = http_request.get_downloaded_bytes() * 100 / http_request.get_body_size()
#region Setup
func set_defaults() -> void:
downloading.value = 0
installed_label.text = "Installed version %s" % Steam.get_godotsteam_version()
update_button.text = "Up-to-date"
update_button.disabled = true
update_label.text = ""
updating_visibility(false, false, false, true)
#endregion
#region Signals
func connect_signals() -> void:
cancel_button.pressed.connect(_on_cancel_pressed)
install_button.pressed.connect(_on_install_pressed)
update_button.pressed.connect(_on_update_pressed)
#endregion
#region Checking for updates
func check_for_updates() -> void:
if not ProjectSettings.get_setting("steam/updates/godotsteam/check_for_updates"):
return
http_request = HTTPRequest.new()
add_child(http_request)
http_request.request_completed.connect(_on_http_request_completed)
if http_request.request(VERSION_URL) != OK:
printerr("Failed to request GodotSteam plug-in remote current version")
func _on_http_request_completed(result: int, _response_code: int, _headers: PackedStringArray, body: PackedByteArray) -> void:
http_request.request_completed.disconnect(_on_http_request_completed)
http_request.queue_free()
if result != HTTPRequest.RESULT_SUCCESS:
return
var response = JSON.parse_string(body.get_string_from_utf8())
if response == null:
return
download_location = response.download_url
new_version = response.version_string
if convert_version(new_version) > convert_version(Steam.get_godotsteam_version()):
print("New GodotSteam version %s available" % new_version)
update_label.text = "New version %s" % new_version
update_button.text = "Download"
update_button.disabled = false
#endregion
#region Updating versions
func _on_cancel_pressed() -> void:
updating_visibility(false, false, false, true)
if is_actively_downloading:
http_request.cancel_request()
http_request.queue_free()
is_actively_downloading = false
update_label.text = "Canceling %s plug-in update download" % new_version
else:
DirAccess.remove_absolute(TEMP_FILE)
update_label.text = "Canceling %s plug-in update and deleting temporary files" % new_version
update_button.text = "Download"
update_button.disabled = false
update_label.text = "New version %s" % new_version
func _on_install_pressed() -> void:
print("Removing older GodotSteam %s plug-in" % Steam.get_godotsteam_version())
OS.move_to_trash(ProjectSettings.globalize_path("res://addons/godotsteam"))
update_button.text = "Unpacking"
print("Unpacking new %s plug-in" % new_version)
var zip_reader: ZIPReader = ZIPReader.new()
zip_reader.open(TEMP_FILE)
var files: PackedStringArray = zip_reader.get_files()
var base_path := files[1]
# Remove archive folder
files.remove_at(0)
# Remove assets folder
files.remove_at(0)
for path in files:
var new_file_path: String = path.replace(base_path, "")
if path.ends_with("/"):
DirAccess.make_dir_recursive_absolute("res://addons/%s" % new_file_path)
else:
var file: FileAccess = FileAccess.open("res://addons/%s" % new_file_path, FileAccess.WRITE)
file.store_buffer(zip_reader.read_file(path))
zip_reader.close()
restart_post_update()
func _on_update_pressed() -> void:
is_actively_downloading = true
update_label.text = "Downloading %s plug-in update, please wait" % new_version
updating_visibility(true, true, false, false)
http_request = HTTPRequest.new()
add_child(http_request)
http_request.request_completed.connect(_on_download_request_completed)
if http_request.request(download_location) != OK:
printerr("Failed to request %s plug-in update download" % new_version)
is_actively_downloading = false
update_button.text = "Failed"
update_button.disabled = false
return
func _on_download_request_completed(result: int, _response_code: int, _headers: PackedStringArray, body: PackedByteArray) -> void:
http_request.request_completed.disconnect(_on_download_request_completed)
http_request.queue_free()
is_actively_downloading = false
updating_visibility(true, false, true, false)
if result != HTTPRequest.RESULT_SUCCESS:
printerr("Failed to download new GodotSteam version %s" % result)
update_button.disabled = false
return
update_label.text = "Update downloaded, ready to install %s" % new_version
var zip_file: FileAccess = FileAccess.open(TEMP_FILE, FileAccess.WRITE)
zip_file.store_buffer(body)
zip_file.close()
func restart_post_update() -> void:
update_button.text = "Restarting"
update_label.text = "Updated to version %s, restarting the editor" % new_version
DirAccess.remove_absolute(TEMP_FILE)
EditorInterface.restart_editor(true)
#endregion
#region Helpers
func convert_version(version_string: String) -> int:
return int(version_string.replace(".", "").rpad(4, "0"))
func updating_visibility(cancel: bool, download: bool, install: bool, update: bool) -> void:
cancel_button.visible = cancel
downloading.visible = download
install_button.visible = install
update_button.visible = update
#endregion

View File

@@ -1 +0,0 @@
uid://b4nvgu7h84u53

View File

@@ -1,29 +0,0 @@
[configuration]
entry_symbol = "godotsteam_init"
compatibility_minimum = "4.4"
[libraries]
android.debug.arm64 = "res://addons/godotsteam/androidarm64/libgodotsteam.android.template_debug.arm64.so"
android.release.arm64 = "res://addons/godotsteam/androidarm64/libgodotsteam.android.template_release.arm64.so"
linux.debug.arm64 = "res://addons/godotsteam/linuxarm64/libgodotsteam.linux.template_debug.arm64.so"
linux.debug.x86_64 = "res://addons/godotsteam/linux64/libgodotsteam.linux.template_debug.x86_64.so"
linux.debug.x86_32 = "res://addons/godotsteam/linux32/libgodotsteam.linux.template_debug.x86_32.so"
linux.release.arm64 = "res://addons/godotsteam/linuxarm64/libgodotsteam.linux.template_release.arm64.so"
linux.release.x86_64 = "res://addons/godotsteam/linux64/libgodotsteam.linux.template_release.x86_64.so"
linux.release.x86_32 = "res://addons/godotsteam/linux32/libgodotsteam.linux.template_release.x86_32.so"
macos.debug = "res://addons/godotsteam/osx/libgodotsteam.macos.template_debug.dylib"
macos.release = "res://addons/godotsteam/osx/libgodotsteam.macos.template_release.dylib"
windows.debug.x86_64 = "res://addons/godotsteam/win64/libgodotsteam.windows.template_debug.x86_64.dll"
windows.debug.x86_32 = "res://addons/godotsteam/win32/libgodotsteam.windows.template_debug.x86_32.dll"
windows.release.x86_64 = "res://addons/godotsteam/win64/libgodotsteam.windows.template_release.x86_64.dll"
windows.release.x86_32 = "res://addons/godotsteam/win32/libgodotsteam.windows.template_release.x86_32.dll"
[dependencies]
android.arm64 = { "res://addons/godotsteam/androidarm64/libsteam_api.so": "" }
linux.arm64 = { "res://addons/godotsteam/linuxarm64/libsteam_api.so": "" }
linux.x86_64 = { "res://addons/godotsteam/linux64/libsteam_api.so": "" }
linux.x86_32 = { "res://addons/godotsteam/linux32/libsteam_api.so": "" }
macos.universal = { "res://addons/godotsteam/osx/libsteam_api.dylib": "" }
windows.x86_64 = { "res://addons/godotsteam/win64/steam_api64.dll": "" }
windows.x86_32 = { "res://addons/godotsteam/win32/steam_api.dll": "" }

View File

@@ -1 +0,0 @@
uid://d4gadhvchsddo

View File

@@ -1,86 +0,0 @@
@tool
class_name GodotSteamPlugin
extends EditorPlugin
const EDITOR_PANEL = preload("uid://cyniebd6yahu5")
static var dock_frame
var link_changelog: String = "[url=https://godotsteam.com/changelog/gdextension/]changelog[/url]"
var link_website: String = "[url=https://godotsteam.com]website[/url]"
var steamworks_dock: Control
## Used specifically to add/remove additional dock content
static func get_dock_frame() -> Control:
return dock_frame
func _enable_plugin() -> void:
print("GodotSteam GDExtension updater functionality enabled")
func _disable_plugin() -> void:
print("GodotSteam GDEXtension updater functionality disabled")
func _enter_tree() -> void:
print_rich("GodotSteam v%s | %s | %s" % [Steam.get_godotsteam_version(), link_website, link_changelog])
add_project_settings()
add_steamworks_dock()
func _exit_tree() -> void:
remove_steamworks_dock()
func _make_visible(visible) -> void:
if steamworks_dock:
steamworks_dock.set_visible(visible)
#region Add and remove things
func add_project_settings() -> void:
# Used for the Updater looking for redist files and SteamCMD
if not ProjectSettings.has_setting("steam/updates/godotsteam/check_for_updates"):
ProjectSettings.set_setting("steam/updates/godotsteam/check_for_updates", true)
ProjectSettings.add_property_info({
"name": "steam/updates/godotsteam/check_for_updates",
"type": TYPE_BOOL
})
ProjectSettings.set_initial_value("steam/updates/godotsteam/check_for_updates", true)
ProjectSettings.set_as_basic("steam/updates/godotsteam/check_for_updates", true)
# Which channel of updates to pull from
# Sponsors repo should require the user to have access to that repository already
# In theory, they can connect via SSH?
if not ProjectSettings.has_setting("steam/updates/godotsteam/update_channel"):
ProjectSettings.set_setting("steam/updates/godotsteam/update_channel", 0)
ProjectSettings.add_property_info({
"name": "steam/updates/godotsteam/update_channel",
"type": TYPE_INT,
"hint": PROPERTY_HINT_ENUM,
"hint_string": "Community, Sponsors"
})
ProjectSettings.set_initial_value("steam/updates/godotsteam/update_channel", 0)
ProjectSettings.set_as_basic("steam/updates/godotsteam/update_channel", true)
func add_steamworks_dock() -> void:
steamworks_dock = EDITOR_PANEL.instantiate()
# This will be used when 4.4.x is deprecated
#add_control_to_dock(DockSlot.DOCK_SLOT_BOTTOM, steamworks_dock)
# This is deprecated as of 4.6; when it is removed then 4.4.x will be deprecated for GodotSteam
add_control_to_bottom_panel(steamworks_dock, "Steamworks")
dock_frame = steamworks_dock
func remove_steamworks_dock() -> void:
# This will be used when 4.4.x is deprecated
#remove_control_from_docks(steamworks_dock)
# This is deprecated as of 4.6; when it is removed then 4.4.x will be deprecated for GodotSteam
remove_control_from_bottom_panel(steamworks_dock)
# This may be causing crashes for some people and is unnecessary with the call above
# steamworks_dock.queue_free()
steamworks_dock = null
dock_frame = null
#endregion

View File

@@ -1 +0,0 @@
uid://btts11rgropcp

View File

@@ -1,23 +0,0 @@
MIT License
Copyright (c) 2015-Current | GP Garcia, Chris Ridenour, and Contributors
View all contributors at https://godotsteam.com/contribute/contributors/
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@@ -1,7 +0,0 @@
[plugin]
name="GodotSteam GDExtension Updater"
description="An updater for GodotSteam GDExtension. This is not required to use Steamworks functionality, just updating the plug-in."
author="Gramps Garcia, GodotSteam"
version="4.19.1"
script="godotsteam_plugin.gd"

View File

@@ -1,95 +0,0 @@
# GodotSteam for GDExtension | Community Edition
An ecosystem of tools for [Godot Engine](https://godotengine.org) and [Valve's Steam](https://store.steampowered.com). For the Windows, Linux, and Mac platforms.
Additional Flavors
---
Standard Module | Standard Plug-ins | Server Module | Server Plug-ins | Examples
--- | --- | --- | --- | ---
[Godot 2.x](https://codeberg.org/godotsteam/godotsteam/src/branch/godot2) | [GDNative](https://codeberg.org/godotsteam/godotsteam/src/branch/gdnative) | [Server 3.x](https://codeberg.org/godotsteam/godotsteam-server/src/branch/godot3) | [GDNative](https://codeberg.org/godotsteam/godotsteam-server/src/branch/gdnative) | [Skillet](https://codeberg.org/godotsteam/skillet)
[Godot 3.x](https://codeberg.org/godotsteam/godotsteam/src/branch/godot3) | [GDExtension](https://codeberg.org/godotsteam/godotsteam/src/branch/gdextension) | [Server 4.x](https://codeberg.org/godotsteam/godotsteam-server/src/branch/godot4) | [GDExtension](https://codeberg.org/godotsteam/godotsteam-server/src/branch/gdextension) | [Skillet UGC Editor](https://codeberg.org/godotsteam/skillet/src/branch/ugc_editor)
[Godot 4.x](https://codeberg.org/godotsteam/godotsteam/src/branch/godot4) | --- | --- | --- | ---
[MultiplayerPeer](https://codeberg.org/godotsteam/multiplayerpeer)| --- | --- | --- | ---
Documentation
---
[Documentation is available here](https://godotsteam.com/). You can also check out the Search Help section inside Godot Engine. [To start, try checking out our tutorial on initializing Steam.](https://godotsteam.com/tutorials/initializing/) There are additional tutorials, with more in the works. You can also [check out additional Godot and Steam related videos, text, additional tools, plug-ins, etc. here.](https://godotsteam.com/resources/external/)
Feel free to chat with us about GodotSteam or ask for assistance on the [Stoat server](https://stt.gg/9DxQ3Dcd) or [IRC on Libera Chat](irc://irc.libera.chat/#godotsteam).
Donate
---
Pull-requests are the best way to help the project out but you can also donate through [Github Sponsors](https://github.com/sponsors/Gramps) or [LiberaPay](https://liberapay.com/godotsteam/donate)! [You can read more about donor perks here.](https://godotsteam.com/contribute/donations/) [You can also view all our awesome donors here.](https://godotsteam.com/contribute/donors/)
Current Build
---
You can [download pre-compiled versions of this repo here](https://codeberg.org/godotsteam/godotsteam/releases).
**Version 4.19.1 Changes**
- Changed: commented out possible issue with removing dock node
- Fixed: in-editor docs error, thanks to ***evanwang0***
[You can read more change-logs here](https://godotsteam.com/changelog/gdextension/).
Compatibility
---
While rare, sometimes Steamworks SDK updates will break compatilibity with older GodotSteam versions. Any compatability breaks are noted below. Newer API files (dll, so, dylib) _should_ still work for older versions.
Steamworks SDK Version | GodotSteam Version
---|---
1.63 or newer | 4.17
1.62 | 4.14 or 4.16.2
1.61 | 4.12 to 4.13
1.60 | 4.6 to 4.11
1.59 | 4.6 to 4.8
1.58a or older | 4.5.4 or older
Versions of GodotSteam that have compatibility breaks introduced.
GodotSteam Version | Broken Compatibility
---|---
4.8 | Networking identity system removed, replaced with Steam IDs
4.9 | sendMessages returns an Array
4.11 | setLeaderboardDetailsMax removed
4.13 | getItemDefinitionProperty return a dictionary, html_needs_paint key 'bgra' changed to 'rbga'
4.14 | Removed first argument for stat request in steamInit and steamInitEx, steamInit returns intended bool value
4.16 | Variety of small break points, refer to [4.16 changelog for details](https://godotsteam.com/changelog/godot4/#version-416)
4.17 | Windows projects using Steam SDK 1.63 are meant to work with Proton 11 or Experimental on Linux / Steam Deck.
4.19 | Lots of changes to Voice functions, refer to [4.19 changelog for details](https://godotsteam.com/changelog/godot4/#version-419)
Known Issues
---
- GDExtension for 4.4 is **not** compatible with 4.3.x or lower. Please check the versions you are using.
- Overlay will not work in the editor but will work in export projects when uploaded to Steam. This seems to a limitation with Vulkan currently.
Quick How-To
---
For complete instructions on how to build the GDExtension version of GodotSteam, [please refer to our documentation's 'How-To GDExtension' section.](https://godotsteam.com/howto/gdextension/) It will have the most up-to-date information.
Alternatively, you can just [download the pre-compiled versions in our Releases section](https://codeberg.org/godotsteam/godotsteam/releases) or [from the Godot Asset Library](https://godotengine.org/asset-library/asset/2445) and skip compiling it yourself!
Usage
---
Once the plug-in is added to your project, the Steam class should be available and ready to go. Enabling the plug-in in the ProjectSettings only affects the Steamworks dock and not the actual functionality.
Do not use the GDExtension version of GodotSteam with any of the module versions whether it be our pre-compiled versions or ones you compile. They are not compatible with each other.
When exporting with the GDExtension version, please use the normal Godot Engine templates instead of our GodotSteam templates or you will have a lot of issues.
No LLM Policy / No "AI" Policy
---
No LLMs are allowed to be used for issues, patches, or pull-requests. They will be closed or rejected and the submitter may be blocked from future submissions.
License
---
MIT license

View File

@@ -4,12 +4,12 @@ importer="scene"
importer_version=1
type="PackedScene"
uid="uid://bvrn4woiabto5"
path="res://.godot/imported/Gathering.fbx-010ce6eb774e1ef5173d7b91f43194c4.scn"
path="res://.godot/imported/gathering.fbx-8cf29bfb4073eff7f1a8c8f2f1200637.scn"
[deps]
source_file="res://core/ai/agents/human/Gathering.fbx"
dest_files=["res://.godot/imported/Gathering.fbx-010ce6eb774e1ef5173d7b91f43194c4.scn"]
source_file="res://core/ai/agents/human/gathering.fbx"
dest_files=["res://.godot/imported/gathering.fbx-8cf29bfb4073eff7f1a8c8f2f1200637.scn"]
[params]

View File

@@ -4,12 +4,12 @@ importer="scene"
importer_version=1
type="PackedScene"
uid="uid://cfe0ylyx1lfaa"
path="res://.godot/imported/Idle.fbx-55b141029a6b8b2285a4fdfb57ee0c93.scn"
path="res://.godot/imported/idle.fbx-e84be0400dfd82eeca47497734059eba.scn"
[deps]
source_file="res://core/ai/agents/human/Idle.fbx"
dest_files=["res://.godot/imported/Idle.fbx-55b141029a6b8b2285a4fdfb57ee0c93.scn"]
source_file="res://core/ai/agents/human/idle.fbx"
dest_files=["res://.godot/imported/idle.fbx-e84be0400dfd82eeca47497734059eba.scn"]
[params]

View File

@@ -4,12 +4,12 @@ importer="scene"
importer_version=1
type="PackedScene"
uid="uid://cuphreeff7ihw"
path="res://.godot/imported/Sitting.fbx-83aa57848ecefeeaff20ef595a19a7b3.scn"
path="res://.godot/imported/sitting.fbx-28ba14b5efd99e4f9dac90f909835595.scn"
[deps]
source_file="res://core/ai/agents/human/Sitting.fbx"
dest_files=["res://.godot/imported/Sitting.fbx-83aa57848ecefeeaff20ef595a19a7b3.scn"]
source_file="res://core/ai/agents/human/sitting.fbx"
dest_files=["res://.godot/imported/sitting.fbx-28ba14b5efd99e4f9dac90f909835595.scn"]
[params]

View File

@@ -4,12 +4,12 @@ importer="scene"
importer_version=1
type="PackedScene"
uid="uid://o8dn1hc1lyly"
path="res://.godot/imported/Walking.fbx-280a67ae546347dd1478504ff6b11a6e.scn"
path="res://.godot/imported/walking.fbx-2ef52b3a6cd770e898c2eff1dbd7eecc.scn"
[deps]
source_file="res://core/ai/agents/human/Walking.fbx"
dest_files=["res://.godot/imported/Walking.fbx-280a67ae546347dd1478504ff6b11a6e.scn"]
source_file="res://core/ai/agents/human/walking.fbx"
dest_files=["res://.godot/imported/walking.fbx-2ef52b3a6cd770e898c2eff1dbd7eecc.scn"]
[params]

Binary file not shown.

Binary file not shown.

View File

@@ -1,8 +1,5 @@
extends Path3D
const STEAM_DISTANCE_STAT: String = "stat_distance_km"
const DISTANCE_KM_PER_UNIT: float = 0.001
@export_group("Train")
##train speed
@export var train_speed: float = 6.0
@@ -82,7 +79,6 @@ var tween_restart: Tween
var environment_config: EnvironmentConfig
var wagon_instances: Array[Node3D] = []
var wagon_progress_offsets: Array[float] = []
var _pending_steam_distance_km: float = 0.0
func _ready() -> void:
randomize()
@@ -332,7 +328,6 @@ func train_move(delta: float) -> void:
var current_speed = train_speed * stop_multiply
train_progress += current_speed * delta
_track_steam_distance(abs(current_speed) * delta)
if enable_stops and stop_offset.size() > 0:
var target_offset = stop_offset[next_stop_index]
@@ -390,29 +385,6 @@ func train_move(delta: float) -> void:
train_instance.rotation.z += curve_roll
train_instance.rotation.x += curve_pitch
#Calculate train distance for steam stats
func _track_steam_distance(distance_units: float) -> void:
if distance_units <= 0.0 or not SteamManager.is_on_steam:
return
_pending_steam_distance_km += distance_units * DISTANCE_KM_PER_UNIT
var whole_km: int = int(floor(_pending_steam_distance_km))
if whole_km <= 0:
return
_pending_steam_distance_km -= float(whole_km)
var total_distance_km: int = StatsManager.get_int(STEAM_DISTANCE_STAT) + whole_km
StatsManager.set_int(STEAM_DISTANCE_STAT, total_distance_km)
_check_distance_achievements(total_distance_km)
StatsManager.store()
#Check achievements
func _check_distance_achievements(total_distance_km: int) -> void:
if total_distance_km >= 100:
AchievementManager.unlock("ACH_DISTANCE_100")
if total_distance_km >= 200:
AchievementManager.unlock("ACH_DISTANCE_200")
func _execute_stop(go_forward: bool = true) -> void:
stop_ongoing = true
stop_multiply = 0.0

View File

@@ -1,7 +1,8 @@
[gd_scene format=3 uid="uid://cmuvmmp7xam4o"]
[ext_resource type="Script" uid="uid://d27xbipk650kf" path="res://core/daynight/environment_manager.gd" id="1_wecen"]
[ext_resource type="Resource" uid="uid://cq627dtyhaew6" path="res://tgcc/map/main.tres" id="2_kavln"]
[ext_resource type="Script" uid="uid://butda6k2tli3o" path="res://core/environment_config.gd" id="2_h6hjk"]
[ext_resource type="Shader" uid="uid://7vwkfffa5vao" path="res://core/daynight/clouds_shadow.gdshader" id="2_i3hjl"]
[ext_resource type="Shader" uid="uid://cq4vlcj8cuvge" path="res://core/daynight/fog.gdshader" id="2_r4tfj"]
[ext_resource type="PackedScene" uid="uid://dyxvcf2l8ba5x" path="res://core/daynight/god_ray.tscn" id="5_411rw"]
[ext_resource type="Shader" uid="uid://bb1jjwe31fl7o" path="res://core/daynight/wind.gdshader" id="5_djqkg"]
@@ -11,6 +12,91 @@
[ext_resource type="Texture2D" uid="uid://b2xcpt2y8v32x" path="res://core/daynight/FogNoise.tres" id="11_tuauy"]
[ext_resource type="FastNoiseLite" uid="uid://c0mtwrkptjcuw" path="res://core/daynight/environment_shadows_noise_clouds.tres" id="11_yn8v8"]
[sub_resource type="ShaderMaterial" id="ShaderMaterial_ruhh7"]
render_priority = 0
shader = ExtResource("2_i3hjl")
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_r4tfj"]
transparency = 2
alpha_scissor_threshold = 0.0
alpha_antialiasing_mode = 0
disable_ambient_light = true
albedo_color = Color(0.44410604, 0.32877246, 0.26597014, 0.7541567)
billboard_mode = 3
particles_anim_h_frames = 1
particles_anim_v_frames = 1
particles_anim_loop = false
[sub_resource type="ShaderMaterial" id="ShaderMaterial_b5atu"]
render_priority = 0
shader = ExtResource("2_r4tfj")
shader_parameter/use_red_as_alpha = true
shader_parameter/fog_color = Color(0.8, 0.85, 0.9, 0.5)
shader_parameter/fog_density = 0.25
shader_parameter/scroll_speed = Vector2(0.05, 0.01)
shader_parameter/texture_scale = Vector2(1, 1)
shader_parameter/edge_softness_y = 0.2
shader_parameter/edge_softness_x = 0.1
shader_parameter/night_intensity = 0.7953524793650795
shader_parameter/sun_color = Color(0.2841828, 0.2023238, 0.27953526, 1)
[sub_resource type="Resource" id="Resource_r4tfj"]
script = ExtResource("2_h6hjk")
morning_color = Color(0.93333334, 0.78039217, 0.6039216, 1)
afternoon_color = Color(0.9490196, 0.62352943, 0.38039216, 1)
night_color = Color(0.18431373, 0.18431373, 0.4862745, 1)
sun_rotation_morning = Vector3(-50, -90, 0)
sun_rotation_afternoon = Vector3(-120, -90, 0)
sun_rotation_night = Vector3(-130, -90, 0)
night_light_energy = 1.0
exposure_morning = 0.8
exposure_afternoon = 0.7
exposure_night = 0.7
sky_top_morning = Color(0.11764706, 0.35686275, 0.5411765, 1)
sky_top_afternoon = Color(0.7019608, 0.4509804, 0.2, 1)
sky_top_night = Color(0.050980393, 0.050980393, 0.14901961, 1)
sky_horizon_morning = Color(0.4627451, 0.6745098, 0.8627451, 1)
sky_horizon_afternoon = Color(0.93333334, 0.6, 0.8039216, 1)
sky_horizon_night = Color(0.14901961, 0.101960786, 0.2509804, 1)
grad_top_morning = Color(0.7921569, 0.8784314, 0.95686275, 1)
grad_top_afternoon = Color(0.8627451, 0.24313726, 0.5411765, 1)
grad_top_night = Color(0.16470589, 0.16470589, 0.26666668, 1)
grad_bot_morning = Color(0.05882353, 0.078431375, 0.21568628, 1)
grad_bot_afternoon = Color(0.2509804, 0.019607844, 0.043137256, 1)
grad_intensity_morning = 0.05
grad_intensity_afternoon = 0.1
grad_intensity_night = 0.5
fog_color_morning = Color(0.7490196, 0.8509804, 0.9490196, 1)
fog_color_afternoon = Color(0.9823975, 0.8034449, 0.8778439, 1)
fog_color_night = Color(0.38409987, 0.28720453, 0.5907528, 1)
fog_density_morning = 0.01
fog_density_afternoon = 0.02
glow_morning = 0.4
glow_night = 0.8
enable_fog = true
material_fog = SubResource("ShaderMaterial_b5atu")
material_drops = SubResource("StandardMaterial3D_r4tfj")
material_clouds = SubResource("ShaderMaterial_ruhh7")
lightning_color = Color(1, 0.9843137, 0.4627451, 1)
lightning_min = 2
lightning_max = 4
lightning_scale_min = 2.0
lightning_scale_max = 5.0
godray_max_rain = 30
godray_spawn_radius = 100.0
godray_spawn_offset = Vector3(20, 80, 20)
godray_rotation_degrees = Vector3(50, 30, 0)
godray_scale = Vector3(2, 25, 50)
snow_amount = 2000.0
wind_amount = 50
cloud_speed = 0.01
fireflies_amount = 550
fireflies_spawn_ray = 60.0
water_color_morning = Color(0.33333334, 0.654902, 0.5294118, 1)
water_color_afternoon = Color(0.5803922, 0.5137255, 0.2901961, 1)
water_color_night = Color(0.48235294, 0.45490196, 0.69411767, 1)
metadata/_custom_type_script = "uid://butda6k2tli3o"
[sub_resource type="Gradient" id="Gradient_i3hjl"]
offsets = PackedFloat32Array(0, 0.49019608, 1)
colors = PackedColorArray(0, 0, 0, 0, 1, 0.8980392, 0.3764706, 1, 1, 1, 1, 0)
@@ -187,7 +273,7 @@ shader_parameter/sun_color = Color(1, 1, 1, 1)
[node name="EnvironmentManager" type="Node3D" unique_id=1611939731 node_paths=PackedStringArray("particles_wind", "particles_snow", "particles_fireflies", "particles_rain", "environment_dust", "blur", "environment_shadows", "fog")]
script = ExtResource("1_wecen")
environment_config = ExtResource("2_kavln")
environment_config = SubResource("Resource_r4tfj")
particles_wind = NodePath("Particles_Wind")
particles_snow = NodePath("Particles_Snow")
particles_fireflies = NodePath("Particles_Fireflies")

View File

@@ -26,9 +26,6 @@ const DYNAMIC_ENVIRONMENT_UPDATES_PER_FRAME: int = 32 #how many update of the en
@export var thunder_sounds: Array[AudioStream]
@export var rain_sounds: Array[AudioStream]
@export_group("Clouds")
@export var cloud_material: ShaderMaterial
#environment nodes
@onready var sun: DirectionalLight3D = $"../DirectionalLight3D"
@onready var environment: WorldEnvironment = $"../WorldEnvironment"
@@ -251,39 +248,3 @@ func select_day_time(normalized_time: float) -> void:
if weather_controller:
weather_controller.day_time = day_time
_update_clouds_lighting(normalized_time)
func _update_clouds_lighting(normalized_time: float) -> void:
if not cloud_material:
return
if normalized_time < environment_config.sunrise:
# NOTTE / PRE-ALBA (Colori scuri, nessun rim light solare)
cloud_material.set_shader_parameter("cloud_color", Color("1a1c2e"))
cloud_material.set_shader_parameter("shadow_color", Color("0d0e17"))
cloud_material.set_shader_parameter("rim_color", Color("000000"))
elif normalized_time < environment_config.day:
# MATTINA / ALBA (Colori che iniziano a scaldarsi)
cloud_material.set_shader_parameter("cloud_color", Color("fdf3e7"))
cloud_material.set_shader_parameter("shadow_color", Color("5c537a"))
cloud_material.set_shader_parameter("rim_color", Color("ff9e64"))
elif normalized_time < environment_config.sunset:
# PIENO GIORNO (Nuvole bianche brillanti, ombre azzurrate anime)
cloud_material.set_shader_parameter("cloud_color", Color("ffffff"))
cloud_material.set_shader_parameter("shadow_color", Color("687fa1"))
cloud_material.set_shader_parameter("rim_color", Color("fff3cc"))
elif normalized_time < environment_config.night:
# TRAMONTO (Bordo dorato/arancione acceso e ombre violacee)
cloud_material.set_shader_parameter("cloud_color", Color("fdf3e7"))
cloud_material.set_shader_parameter("shadow_color", Color("5c537a"))
cloud_material.set_shader_parameter("rim_color", Color("ff9e64"))
else:
# NOTTE FONDA (Ritorno al buio)
cloud_material.set_shader_parameter("cloud_color", Color("1a1c2e"))
cloud_material.set_shader_parameter("shadow_color", Color("0d0e17"))
cloud_material.set_shader_parameter("rim_color", Color("000000"))

View File

@@ -3,9 +3,7 @@
[sub_resource type="FastNoiseLite" id="FastNoiseLite_xa3jw"]
noise_type = 3
seed = 1
frequency = 0.0264
fractal_octaves = 10
fractal_lacunarity = 2.13
frequency = 0.0158
metadata/_preview_in_3d_space_ = true
[resource]

Binary file not shown.

View File

@@ -1,36 +0,0 @@
[remap]
importer="font_data_dynamic"
type="FontFile"
uid="uid://bclja5no1qteh"
path="res://.godot/imported/Kestila.ttf-f001cde29110f4467ff622e7f88cd515.fontdata"
[deps]
source_file="res://core/font/Kestila.ttf"
dest_files=["res://.godot/imported/Kestila.ttf-f001cde29110f4467ff622e7f88cd515.fontdata"]
[params]
Rendering=null
antialiasing=1
generate_mipmaps=false
disable_embedded_bitmaps=true
multichannel_signed_distance_field=false
msdf_pixel_range=8
msdf_size=48
allow_system_fallback=true
force_autohinter=false
modulate_color_glyphs=false
hinting=1
subpixel_positioning=4
keep_rounding_remainders=true
oversampling=0.0
Fallbacks=null
fallbacks=[]
Compress=null
compress=true
preload=[]
language_support={}
script_support={}
opentype_features={}

View File

@@ -1,6 +0,0 @@
[gd_resource type="Theme" format=3 uid="uid://bg8megpn77mod"]
[ext_resource type="FontFile" uid="uid://bclja5no1qteh" path="res://core/font/Kestila.ttf" id="1_47a5q"]
[resource]
default_font = ExtResource("1_47a5q")

View File

@@ -16,6 +16,9 @@ grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
[node name="Background" parent="." index="0" unique_id=1203110384]
visible = true
[node name="Decoration" type="TextureRect" parent="." index="1" unique_id=980764536]
layout_mode = 1
anchors_preset = 15

View File

@@ -1,57 +1,52 @@
extends VBoxContainer
@onready var color_pickers_1: Array[TrainColorPicker] = [$%ColorPicker1, $%ColorPicker2, $%ColorPicker3, $%ColorPicker4, $%ColorPicker5, $%ColorPicker6]
@onready var color_pickers_2: Array[TrainColorPicker] = [$%ColorPicker7, $%ColorPicker8, $%ColorPicker9, $%ColorPicker10, $%ColorPicker11, $%ColorPicker12]
@onready var color_pickers: Array[TrainColorPicker] = [$%ColorPicker1, $%ColorPicker2, $%ColorPicker3, $%ColorPicker4, $%ColorPicker5, $%ColorPicker6]
@onready var left_arrow: ArrowButton = $%ArrowButtonLeft
@onready var right_arrow: ArrowButton = $%ArrowButtonRight
@onready var treno: Node3D = $TrainViewportContainer/SubViewport/Treno
var selected_color: Color
var selected_color_index: int = 0
func _ready() -> void:
for color_picker in color_pickers_1:
color_picker.pressed.connect(_on_color_selected.bind(color_picker, 0))
for color_picker in color_pickers:
color_picker.pressed.connect(_on_color_selected.bind(color_picker))
color_picker.deselect()
var init_idx_1 = GameState.save_data.train_color_1_index
_set_selected_color(init_idx_1, 0)
_set_selected_color(0)
for color_picker in color_pickers_2:
color_picker.pressed.connect(_on_color_selected.bind(color_picker, 1))
color_picker.deselect()
var init_idx_2 = GameState.save_data.train_color_2_index
_set_selected_color(init_idx_2, 1)
left_arrow.pressed.connect(_select_prev_color)
right_arrow.pressed.connect(_select_next_color)
func _process(delta: float) -> void:
if treno:
treno.rotation_degrees.y += 30.0 * delta
func _set_selected_color(index: int, material_index: int) -> void:
var color_pickers = color_pickers_1 if material_index == 0 else color_pickers_2
func _set_selected_color(index: int) -> void:
for i in range(color_pickers.size()):
if i == index:
color_pickers[i].select()
selected_color_index = i
selected_color = color_pickers[i].color
_apply_train_color(selected_color, material_index, index)
_apply_train_color(selected_color)
else:
color_pickers[i].deselect()
func _on_color_selected(selected_color_picker: TrainColorPicker, material_index: int) -> void:
var color_pickers = color_pickers_1 if material_index == 0 else color_pickers_2
func _on_color_selected(selected_color_picker: TrainColorPicker) -> void:
for i in range(color_pickers.size()):
if color_pickers[i] == selected_color_picker:
_set_selected_color(i, material_index)
_set_selected_color(i)
break
func _apply_train_color(color: Color, material_index: int, color_index: int = 0) -> void:
var path = "res://tgcc/train/Color%s_train.tres" % ("1" if material_index == 0 else "2")
var mat: ShaderMaterial = load(path)
func _select_prev_color() -> void:
var next_index = (selected_color_index - 1 + color_pickers.size()) % color_pickers.size()
_set_selected_color(next_index)
func _select_next_color() -> void:
var next_index = (selected_color_index + 1) % color_pickers.size()
_set_selected_color(next_index)
func _apply_train_color(color: Color) -> void:
var mat: ShaderMaterial = load("res://tgcc/train/Color1_train.tres")
if mat:
mat.set_shader_parameter("albedo_color", color)
if material_index == 0:
GameState.save_data.train_color_1 = color.to_html()
GameState.save_data.train_color_1_index = color_index
else:
GameState.save_data.train_color_2 = color.to_html()
GameState.save_data.train_color_2_index = color_index
GameState.save_game()

View File

@@ -9,10 +9,10 @@ func _ready() -> void:
deselect()
disable()
func set_option_text(_text: String) -> void:
func set_option_text(text: String) -> void:
if label == null:
label = $%Label
label.text = _text
label.text = text
func select() -> void:
if checkbox == null:

View File

@@ -2,7 +2,6 @@
[ext_resource type="Script" uid="uid://i331kqurs7f4" path="res://core/game_menu/window_option_menu_button.gd" id="1_yyn3b"]
[ext_resource type="PackedScene" uid="uid://gvpxmy1bgt8h" path="res://core/game_menu/checkbox.tscn" id="2_ai3i2"]
[ext_resource type="Theme" uid="uid://bg8megpn77mod" path="res://core/font/main_theme.tres" id="3_1lfxj"]
[node name="WindowOptionMenuButton" type="Button" unique_id=1649914382]
custom_minimum_size = Vector2(200, 30)
@@ -40,7 +39,6 @@ offset_bottom = 11.0
unique_name_in_owner = true
layout_mode = 2
size_flags_horizontal = 3
theme = ExtResource("3_1lfxj")
theme_override_colors/font_color = Color(0, 0, 0, 1)
text = "TEST"
horizontal_alignment = 1

View File

@@ -34,7 +34,7 @@ func apply_video_settings() -> void:
get_viewport().use_taa = save_data.anti_aliasing
var msaa_mode = Viewport.MSAA_2X if save_data.anti_aliasing else Viewport.MSAA_DISABLED
get_viewport().msaa_3d = msaa_mode
get_viewport().msaa_2d = Viewport.MSAA_DISABLED
get_viewport().msaa_2d = msaa_mode
match save_data.window_mode_index:
0:
@@ -49,18 +49,9 @@ func apply_video_settings() -> void:
DisplayServer.window_set_size(Vector2i(save_data.resolution_x, save_data.resolution_y))
# Optional: center the window if resized
var screen_position: Vector2i = DisplayServer.screen_get_position()
var screen_size: Vector2i = DisplayServer.screen_get_size()
var window_size: Vector2i = DisplayServer.window_get_size()
var screen_center := screen_position + Vector2i(
floori(float(screen_size.x) / 2.0),
floori(float(screen_size.y) / 2.0)
)
var window_half_size := Vector2i(
floori(float(window_size.x) / 2.0),
floori(float(window_size.y) / 2.0)
)
DisplayServer.window_set_position(screen_center - window_half_size)
var screen_center = DisplayServer.screen_get_position() + DisplayServer.screen_get_size() / 2
var window_size = DisplayServer.window_get_size()
DisplayServer.window_set_position(screen_center - window_size / 2)
func save_game() -> void:

View File

@@ -2,7 +2,6 @@
[ext_resource type="Script" uid="uid://c4kekqicrv4m8" path="res://core/main_scene_ui/audio_player.gd" id="1_i2mrl"]
[ext_resource type="PackedScene" uid="uid://2tqofxxxnvhv" path="res://core/main_scene_ui/icon_button.tscn" id="1_ucnyb"]
[ext_resource type="Theme" uid="uid://bg8megpn77mod" path="res://core/font/main_theme.tres" id="2_0koyu"]
[ext_resource type="Texture2D" uid="uid://cqx45c744325t" path="res://core/main_scene_ui/assets/button_audio_previous.png" id="3_netjv"]
[ext_resource type="Texture2D" uid="uid://bdnevc7ewu5qe" path="res://core/main_scene_ui/assets/button_audio_play.png" id="4_urwwp"]
[ext_resource type="Texture2D" uid="uid://d2ft1kea45hec" path="res://core/main_scene_ui/assets/button_audio_next.png" id="5_0koyu"]
@@ -34,7 +33,6 @@ metadata/_edit_use_anchors_ = true
unique_name_in_owner = true
layout_mode = 2
size_flags_horizontal = 4
theme = ExtResource("2_0koyu")
theme_override_font_sizes/font_size = 24
text = "Uknown Track"
horizontal_alignment = 1
@@ -46,10 +44,13 @@ alignment = 1
[node name="PrevTrackIconButton" parent="HBoxContainer/VBoxContainer/IconButtonsRow" unique_id=1750448019 instance=ExtResource("1_ucnyb")]
unique_name_in_owner = true
custom_minimum_size = Vector2(80, 80)
layout_mode = 2
image = ExtResource("3_netjv")
images = Array[Texture]([])
[node name="Texture" parent="HBoxContainer/VBoxContainer/IconButtonsRow/PrevTrackIconButton" index="0" unique_id=1071359322]
custom_minimum_size = Vector2(80, 80)
anchors_preset = -1
offset_left = 116.66667
offset_top = 131.3789
@@ -60,11 +61,13 @@ metadata/_edit_use_anchors_ = true
[node name="PlayPauseIconButton" parent="HBoxContainer/VBoxContainer/IconButtonsRow" unique_id=1533336956 instance=ExtResource("1_ucnyb")]
unique_name_in_owner = true
custom_minimum_size = Vector2(80, 80)
layout_mode = 2
image = ExtResource("4_urwwp")
images = Array[Texture]([ExtResource("4_urwwp"), ExtResource("5_urwwp")])
[node name="Texture" parent="HBoxContainer/VBoxContainer/IconButtonsRow/PlayPauseIconButton" index="0" unique_id=1071359322]
custom_minimum_size = Vector2(80, 80)
anchors_preset = -1
offset_left = 116.66667
offset_top = 131.3789
@@ -75,10 +78,13 @@ metadata/_edit_use_anchors_ = true
[node name="NextTrackIconButton" parent="HBoxContainer/VBoxContainer/IconButtonsRow" unique_id=2108379455 instance=ExtResource("1_ucnyb")]
unique_name_in_owner = true
custom_minimum_size = Vector2(80, 80)
layout_mode = 2
image = ExtResource("5_0koyu")
images = Array[Texture]([])
[node name="Texture" parent="HBoxContainer/VBoxContainer/IconButtonsRow/NextTrackIconButton" index="0" unique_id=1071359322]
custom_minimum_size = Vector2(80, 80)
anchors_preset = -1
offset_left = 116.66667
offset_top = 131.3789
@@ -98,6 +104,7 @@ layout_mode = 2
size_flags_horizontal = 0
size_flags_vertical = 3
image = ExtResource("6_xv7rp")
images = Array[Texture]([])
[node name="Texture" parent="HBoxContainer/VBoxContainer2/IncreaseVolumeIconButton" index="0" unique_id=1071359322]
custom_minimum_size = Vector2(40, 40)
@@ -115,6 +122,7 @@ layout_mode = 2
size_flags_horizontal = 0
size_flags_vertical = 3
image = ExtResource("7_7ib2x")
images = Array[Texture]([])
[node name="Texture" parent="HBoxContainer/VBoxContainer2/DecreaseVolumeIconButton" index="0" unique_id=1071359322]
custom_minimum_size = Vector2(40, 40)

View File

@@ -1,5 +1,6 @@
extends Control
@onready var game_menu: Control = $%GameMenu
@onready var game_menu_panel: Control = $%GameMenuPanel
@onready var menu_icon_button: Button = $%MenuIconButton
@@ -89,8 +90,6 @@ func _on_weather_row_on_option_changed(data: String) -> void:
_:
pass
AchievementManager.is_unlocked("ACH_CHANGE_METEO")
func pick_random_weather() -> void:
var valid_buttons = []
for child in weather_row.options_icon_buttons:
@@ -167,8 +166,6 @@ func _on_photo_taken_finished() -> void:
await tween.finished
photo_mode_black_screen.hide()
GameState.on_photo_mode_black_screen_disappeared.emit()
StatsManager.add_int("stat_photo_number", 1)
StatsManager.store()
func hide_ui_for_photo_mode() -> void:
TweenFX.fade_out(weather_row, 0.25)

View File

@@ -1,70 +0,0 @@
## Updates total elapsed time and train distance labels.
class_name TotalStatsDisplay
extends Node
const RAILS_SCRIPT = preload("res://core/biome_generator/rails.gd")
const SECONDS_PER_MINUTE: int = 60
const MINUTES_PER_HOUR: int = 60
const HOURS_PER_DAY: int = 24
#DISTANCE_KM_PER_UNIT is taken from rails.gd constant
@export var time_label_path: NodePath
@export var distance_label_path: NodePath
@export var rail_path: NodePath
var _elapsed_seconds: float = 0.0
var _total_distance_km: float = 0.0
var _last_train_progress: float = -1.0
@onready var _time_label: Label = get_node_or_null(time_label_path) as Label
@onready var _distance_label: Label = get_node_or_null(distance_label_path) as Label
@onready var _rail_path: Path3D = get_node_or_null(rail_path) as Path3D
func _ready() -> void:
_update_time_label()
_update_distance_label()
func _process(delta: float) -> void:
_elapsed_seconds += delta
_update_total_distance()
_update_time_label()
_update_distance_label()
func _update_total_distance() -> void:
if _rail_path == null or _rail_path.curve == null:
return
var current_train_progress: float = float(_rail_path.get("train_progress"))
if _last_train_progress < 0.0:
_last_train_progress = current_train_progress
return
var total_length: float = _rail_path.curve.get_baked_length()
if total_length <= 0.0:
return
var progress_delta: float = absf(current_train_progress - _last_train_progress)
var wrapped_progress_delta: float = minf(progress_delta, total_length - progress_delta)
_total_distance_km += wrapped_progress_delta * RAILS_SCRIPT.DISTANCE_KM_PER_UNIT
_last_train_progress = current_train_progress
func _update_time_label() -> void:
if _time_label == null:
return
var total_minutes: int = int(floor(_elapsed_seconds / SECONDS_PER_MINUTE))
var days: int = floori(float(total_minutes) / float(MINUTES_PER_HOUR * HOURS_PER_DAY))
var hours: int = floori(float(total_minutes) / float(MINUTES_PER_HOUR)) % HOURS_PER_DAY
var minutes: int = total_minutes % MINUTES_PER_HOUR
_time_label.text = "Time %dd %02dh %02dm" % [days, hours, minutes]
func _update_distance_label() -> void:
if _distance_label == null:
return
_distance_label.text = "Distance %.1f km" % _total_distance_km

View File

@@ -1 +0,0 @@
uid://c2usnexa5x7pg

View File

@@ -5,7 +5,6 @@ extends CanvasLayer
@onready var loading_screen = $LoadingScreen
@export var transition_duration: float = 1
func _ready() -> void:
color_rect.color.a = 0.0
color_rect.mouse_filter = Control.MOUSE_FILTER_IGNORE

View File

@@ -2,7 +2,6 @@
[ext_resource type="Script" uid="uid://bf1f2kp8ghtei" path="res://core/scene_manager/scene_manager.gd" id="1_7resu"]
[ext_resource type="Resource" uid="uid://dr612tmciq8pg" path="res://core/scene_manager/scene_config.tres" id="2_vtdwt"]
[ext_resource type="Theme" uid="uid://bg8megpn77mod" path="res://core/font/main_theme.tres" id="3_j173j"]
[node name="SceneManager" type="CanvasLayer" unique_id=399843239]
process_mode = 3
@@ -28,20 +27,19 @@ grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
[node name="Label" type="Label" parent="LoadingScreen" unique_id=1650459634]
[node name="Label" type="Label" parent="LoadingScreen" unique_id=887425331]
layout_mode = 1
anchors_preset = 3
anchor_left = 1.0
anchor_top = 1.0
anchor_right = 1.0
anchor_bottom = 1.0
offset_left = -197.0
offset_top = -68.0
offset_right = -21.0
offset_left = -169.0
offset_top = -65.0
offset_right = -20.0
offset_bottom = -20.0
grow_horizontal = 0
grow_vertical = 0
theme = ExtResource("3_j173j")
theme_override_constants/outline_size = 24
theme_override_font_sizes/font_size = 32
text = "Loading..."
uppercase = true

View File

@@ -1,73 +0,0 @@
extends Node
#Achievements and stats must be published on Steam even if game is not yet released
#if you have an error setting achievements or stats in debug mode remember to open your steam client
#with jmp games account or another account who bought this game. If error persist try to clos and reopen steam client.
const KNOWN := [
"ACH_CHANGE_METEO",
"ACH_CHANGE_TRAIN_COLOR",
]
#how it works:
#func _on_player_won() -> void:
# AchievementManager.unlock("ACH_DISTANCE_100") #unlock the achievement at first win
#func _on_match_finished(coins_collected: int) -> void:
#update stats
#...
#check thresholds and unlock achievements
# if StatsManager.get_int("stat_distance_km") >= 100:
# AchievementManager.unlock("ACH_DISTANCE_100")
# if StatsManager.get_int("stat_distance_km") >= 200:
# AchievementManager.unlock("ACH_DISTANCE_200")
signal unlocked(api_name: String)
func _ready() -> void:
if not SteamManager.is_on_steam:
return
Steam.user_achievement_stored.connect(_on_achievement_stored)
Steam.global_achievement_percentages_ready.connect(_on_global_percentages_ready)
Steam.requestGlobalAchievementPercentages() # asincrona
func _on_global_percentages_ready(_game: int, _result: int) -> void:
pass
func unlock(api_name: String) -> void:
if not KNOWN.has(api_name):
push_warning("Achievement unknown: %s" % api_name)
return
if is_unlocked(api_name):
return
if not Steam.setAchievement(api_name):
push_error("setAchievement failed (is published on Steam?): %s" % api_name)
return
Steam.storeStats()
unlocked.emit(api_name)
func is_unlocked(api_name: String) -> bool:
var data: Dictionary = Steam.getAchievement(api_name)
return data.get("achieved", false)
func get_display_name(api_name: String) -> String:
return Steam.getAchievementDisplayAttribute(api_name, "name")
func get_description(api_name: String) -> String:
return Steam.getAchievementDisplayAttribute(api_name, "desc")
#Global percentage of player who have unlocked the achievement
func get_global_percent(api_name: String) -> float:
var data: Dictionary = Steam.getAchievementAchievedPercent(api_name)
if not data.get("ret", false):
return -1.0 #global percentage not yet available
return data.get("percent", 0.0)
#for development only: reset an achievement
func clear(api_name: String) -> void:
Steam.clearAchievement(api_name)
Steam.storeStats()
func _on_achievement_stored(_game: int, _group: bool, api_name: String,
current: int, maximum: int) -> void:
print("Achievement confirmed by server: %s (%d/%d)" % [api_name, current, maximum])

View File

@@ -1 +0,0 @@
uid://vcuh547okpvj

View File

@@ -1,72 +0,0 @@
extends Node
### SISETMARE SU RAILS IL FATTORE DI CONVERSIONE DA UNITA' A KM!!!
### ORA HO LASCIATO 1:1 PER TEST
#Achievements and stats must be published on Steam even if game is not yet released
#if you have an error setting achievements or stats in debug mode remember to open your steam client
#with jmp games account or another account who bought this game. If error persist try to clos and reopen steam client.
const KNOWN := [
"stat_time_played",
"stat_distance_km",
"stat_stop_number",
"stat_photo_number",
"stat_toottoot_number",
]
#how it works:
#func _on_match_finished(score: int) -> void:
# StatsManager.add_int("stat_time_played", 1)
# StatsManager.set_int("stat_total_score", StatsManager.get_int("stat_total_score") + score)
# StatsManager.store() #only one push at the end of the game
# if StatsManager.get_int("stat_time_played") >= 10:
# AchievementManager.unlock("ACH_PLAY_10_HOURS") #it call storeStats()
func _ready() -> void:
if not SteamManager.is_on_steam:
return
Steam.user_stats_stored.connect(_on_stats_stored)
func get_int(stat: String) -> int:
return Steam.getStatInt(stat)
func get_float(stat: String) -> float:
return Steam.getStatFloat(stat)
func set_int(stat: String, value: int) -> void:
if not KNOWN.has(stat):
push_warning("Stat not found: %s" % stat)
return
if not Steam.setStatInt(stat, value):
push_error("setStatInt failed (incremental with value less than current value? is published on steam?): %s" % stat)
func set_float(stat: String, value: float) -> void:
if not KNOWN.has(stat):
push_warning("Stat not found: %s" % stat)
return
if not Steam.setStatFloat(stat, value):
push_error("setStatFloat failed: %s" % stat)
func add_int(stat: String, amount: int = 1) -> void:
set_int(stat, get_int(stat) + amount)
func update_avg_rate(stat: String, count_this_session: float, session_length: float) -> void:
Steam.updateAvgRateStat(stat, count_this_session, session_length)
#Send all data to server; call it at the end of the game of when exit
func store() -> void:
if not Steam.storeStats():
push_error("storeStats failed; data saved locally")
#Development only: reset stats
func reset_all(include_achievements: bool = false) -> void:
if !Steam.resetAllStats(include_achievements):
push_error("resetAllStats failed")
func _on_stats_stored(_game: int, result: int) -> void:
if !result:
print("stats not ready: (result %d)" % [result])

View File

@@ -1 +0,0 @@
uid://bc3w8330cgc53

View File

@@ -1,30 +0,0 @@
extends Node
#if you have an error setting achievements or stats in debug mode remember to open your steam client
#with jmp games account or another account who bought this game. If error persist try to clos and reopen steam client.
const APP_ID: int = 4809260 #Train Goes Choo Choo
var is_on_steam: bool = false
func _init() -> void:
OS.set_environment("SteamAppId", str(APP_ID))
OS.set_environment("SteamGameId", str(APP_ID))
func _ready() -> void:
process_mode = Node.PROCESS_MODE_ALWAYS
var init := Steam.steamInitEx()
if init['status'] != Steam.STEAM_API_INIT_RESULT_OK:
push_error("Steam not initialized: %s" % init['verbal'])
return
is_on_steam = true
Steam.overlay_toggled.connect(_on_overlay_toggled)
func _process(_delta: float) -> void:
if is_on_steam:
Steam.run_callbacks() #every frame, forever
func _on_overlay_toggled(active: bool, _user_initiated: bool, _app_id: int) -> void:
get_tree().paused = active

View File

@@ -1 +0,0 @@
uid://b8u4wynp6d6so

View File

@@ -1,57 +0,0 @@
shader_type canvas_item;
uniform vec4 base_color : source_color;
uniform vec2 node_resolution;
uniform float factor : hint_range(0.0, 1.0, 0.01) = 0.54;
uniform float width = 0.4;
group_uniforms gradient;
uniform sampler2D gradient_texture;
uniform bool gradient_fixed = false;
group_uniforms shape;
uniform sampler2D shape_texture;
uniform float shape_tiling = 32.0;
uniform float shape_rotation = 0.0;
uniform vec2 shape_scroll = vec2(0.0);
uniform float shape_feathering : hint_range(0.0, 1.0, 0.01) = 0.00;
uniform float shape_treshold : hint_range(0.0, 2.0, 0.01) = 1.0;
float gradient(vec2 uv, vec2 fixed_uv, bool fixed){
float value = 0.0;
if(fixed){
value = texture(gradient_texture, fixed_uv).r;
} else {
value = texture(gradient_texture, uv).r;
}
return value;
}
vec2 rotate(vec2 uv, vec2 pivot, float angle)
{
mat2 rotation = mat2(vec2(sin(angle), -cos(angle)),
vec2(cos(angle), sin(angle)));
uv -= pivot;
uv = uv * rotation;
uv += pivot;
return uv;
}
void fragment() {
float progress = mix(-width, 1.0, factor);
float aspect = node_resolution.y / node_resolution.x;
vec2 aspect_uv = ((UV-vec2(0.0,0.5)) * vec2(1.0, aspect))+vec2(0.0,0.5);
float value = clamp((gradient(UV, aspect_uv, gradient_fixed) - progress) / (width), 0.0, 1.0);
vec2 tiled_uv = rotate(mod((aspect_uv + vec2(TIME)*shape_scroll) * shape_tiling, 1.0), vec2(0.5), radians(shape_rotation));
float shape_value = 1.0 - texture(shape_texture, tiled_uv).r;
shape_value = mix(shape_feathering * 0.5, 1.0 - shape_feathering * 0.5, shape_value);
float shaped_gradient = smoothstep(value - (shape_feathering * 0.5), value + (shape_feathering * 0.5), shape_treshold - shape_value);
COLOR.rgb = base_color.rgb;
COLOR.a = shaped_gradient;
}

View File

@@ -1 +0,0 @@
uid://ovrd5ydp8p0q

View File

@@ -43,7 +43,3 @@ signal day_time_changed(value: float, time_string: String)
signal time_option_item_changed(index: int)
@warning_ignore("unused_signal")
signal day_time_option_changed(index: int)
#train signals
@warning_ignore("unused_signal")
signal toot_toot()

View File

@@ -1,6 +1,6 @@
extends Node3D
#func _input(event):
#if event is InputEventKey and event.pressed:
#if event.keycode == KEY_ESCAPE:
#get_tree().quit()
func _input(event):
if event is InputEventKey and event.pressed:
if event.keycode == KEY_ESCAPE:
get_tree().quit()

View File

@@ -107,9 +107,3 @@ func _on_fog_toggled(toggled_on: bool) -> void:
func _on_update_rails_pressed() -> void:
UIEvents.update_rail_chunks.emit()
func _on_toot_toot_pressed() -> void:
UIEvents.toot_toot.emit()
func _on_reset_stats_ach_pressed() -> void:
StatsManager.reset_all(true)

View File

@@ -1,6 +1,6 @@
extends Node3D
#func _input(event):
#if event is InputEventKey and event.pressed:
#if event.keycode == KEY_ESCAPE:
#get_tree().quit()
func _input(event):
if event is InputEventKey and event.pressed:
if event.keycode == KEY_ESCAPE:
get_tree().quit()

View File

@@ -18,7 +18,6 @@ config/icon="uid://bfar1kk3pgq8f"
[autoload]
SteamManager="*uid://b8u4wynp6d6so"
UIEvents="*uid://dehu28iq27mbn"
GameState="*uid://b17g2w2g101o6"
CollectionManager="*uid://22orqdm34hfm"
@@ -26,20 +25,17 @@ AudioManager="*uid://dcttbbavtwtsg"
SceneManager="*uid://bw8hwkw55j675"
ShaderWarmup="*res://core/shader_warmup.gd"
TweenFX="*uid://d2n10rw2dnx8o"
AchievementManager="*uid://vcuh547okpvj"
StatsManager="*uid://bc3w8330cgc53"
[display]
window/size/viewport_width=1920
window/size/viewport_height=1080
window/size/mode=3
window/stretch/mode="canvas_items"
window/stretch/aspect="expand"
[editor_plugins]
enabled=PackedStringArray("res://addons/TweenFX/plugin.cfg", "res://addons/godotsteam/plugin.cfg")
enabled=PackedStringArray("res://addons/TweenFX/plugin.cfg")
[global_group]
@@ -192,10 +188,3 @@ global_water_color={
"type": "color",
"value": Color(0, 0, 0, 1)
}
[steam]
initialization/app_id=0
initialization/initialize_on_startup=false
initialization/embed_callbacks=false
multiplayer_peer/max_channels=4

View File

@@ -1 +0,0 @@
4809260

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,44 +0,0 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://b1b84hr1574ot"
path="res://.godot/imported/chunk_animal_cross_3_1.fbx-9ba7d23ea67859d43e9c9bc4c8950603.scn"
[deps]
source_file="res://tgcc/chunk/animal/mesh/chunk_animal_cross_3_1.fbx"
dest_files=["res://.godot/imported/chunk_animal_cross_3_1.fbx-9ba7d23ea67859d43e9c9bc4c8950603.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=true
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={}
fbx/importer=0
fbx/allow_geometry_helper_nodes=false
fbx/embedded_image_handling=1
fbx/naming_version=2

View File

@@ -1,44 +0,0 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://ct81x3tc7yvd1"
path="res://.godot/imported/chunk_animal_cross_3_2.fbx-c10cf9224748248ca9065a238e5d6161.scn"
[deps]
source_file="res://tgcc/chunk/animal/mesh/chunk_animal_cross_3_2.fbx"
dest_files=["res://.godot/imported/chunk_animal_cross_3_2.fbx-c10cf9224748248ca9065a238e5d6161.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=true
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={}
fbx/importer=0
fbx/allow_geometry_helper_nodes=false
fbx/embedded_image_handling=1
fbx/naming_version=2

View File

@@ -1,44 +0,0 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://b3l382myb5h2a"
path="res://.godot/imported/chunk_animal_empty.fbx-5f8fd80388442a07c98b7a8f575ecbcc.scn"
[deps]
source_file="res://tgcc/chunk/animal/mesh/chunk_animal_empty.fbx"
dest_files=["res://.godot/imported/chunk_animal_empty.fbx-5f8fd80388442a07c98b7a8f575ecbcc.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=true
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={}
fbx/importer=0
fbx/allow_geometry_helper_nodes=false
fbx/embedded_image_handling=1
fbx/naming_version=2

View File

@@ -1,44 +0,0 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://b7vsobxts27bd"
path="res://.godot/imported/chunk_animal_end_1.fbx-cbafcedc90251b52c1a348406f2968b4.scn"
[deps]
source_file="res://tgcc/chunk/animal/mesh/chunk_animal_end_1.fbx"
dest_files=["res://.godot/imported/chunk_animal_end_1.fbx-cbafcedc90251b52c1a348406f2968b4.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=true
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={}
fbx/importer=0
fbx/allow_geometry_helper_nodes=false
fbx/embedded_image_handling=1
fbx/naming_version=2

View File

@@ -1,44 +0,0 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://bi40xq1kqfyuj"
path="res://.godot/imported/chunk_animal_straight_1.fbx-27f86be94137614690612635ef71fc61.scn"
[deps]
source_file="res://tgcc/chunk/animal/mesh/chunk_animal_straight_1.fbx"
dest_files=["res://.godot/imported/chunk_animal_straight_1.fbx-27f86be94137614690612635ef71fc61.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=true
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={}
fbx/importer=0
fbx/allow_geometry_helper_nodes=false
fbx/embedded_image_handling=1
fbx/naming_version=2

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -58,19 +58,19 @@ have_lamppost = true
connection_left = [NodePath("PaloLuce/sx")]
connection_right = [NodePath("PaloLuce/dx")]
[node name="Argini_001" parent="." index="0" unique_id=439223507]
[node name="Argini_001" parent="." index="0" unique_id=1474838784]
surface_material_override/0 = ExtResource("3_082gl")
[node name="Chunk_005" parent="." index="1" unique_id=1955568282]
[node name="Chunk_005" parent="." index="1" unique_id=844192036]
surface_material_override/0 = ExtResource("3_082gl")
[node name="Chunk_036" parent="." index="2" unique_id=1808067169 groups=["weather_node"]]
[node name="Chunk_036" parent="." index="2" unique_id=1584066508 groups=["weather_node"]]
surface_material_override/0 = ExtResource("4_a7l8v")
[node name="Chunk_037" parent="." index="3" unique_id=1338393481 groups=["weather_node"]]
[node name="Chunk_037" parent="." index="3" unique_id=1100757609 groups=["weather_node"]]
surface_material_override/0 = ExtResource("4_a7l8v")
[node name="Water_003" parent="." index="4" unique_id=1175879696]
[node name="Water_003" parent="." index="4" unique_id=1047599796]
surface_material_override/0 = ExtResource("5_c18pu")
[node name="grass" type="Node3D" parent="." index="5" unique_id=924191951 groups=["weather_vegetables_node", "wind_node"]]
@@ -117,16 +117,16 @@ transform = Transform3D(-1, 0, 8.742278e-08, 0, 1, 0, -8.742278e-08, 0, -1, 5.70
script = ExtResource("11_087d3")
available_props = Array[PackedScene]([ExtResource("12_scfr8"), ExtResource("13_mflo2"), ExtResource("14_12dst"), ExtResource("15_3yofm")])
[node name="tea_medium" parent="." index="9" unique_id=774250378 instance=ExtResource("16_qoeuy")]
[node name="tea_medium" parent="." index="9" unique_id=774250378 groups=["weather_node"] instance=ExtResource("16_qoeuy")]
transform = Transform3D(0.6711149, 0, 0, 0, 1, 0, 0, 0, 1, -5.7421913, 0, 5.875937)
[node name="tea_small" parent="." index="10" unique_id=738556947 instance=ExtResource("17_nbfhp")]
[node name="tea_small" parent="." index="10" unique_id=738556947 groups=["weather_node"] instance=ExtResource("17_nbfhp")]
transform = Transform3D(-3.2106954e-08, 0, -0.782855, 0, 1, 0, 0.7345215, 0, -3.4219678e-08, 1.8474164, 0, -5.8836246)
[node name="tea_big" parent="." index="11" unique_id=1080521676 instance=ExtResource("18_ipyhu")]
[node name="tea_big" parent="." index="11" unique_id=1080521676 groups=["weather_node"] instance=ExtResource("18_ipyhu")]
transform = Transform3D(-4.371139e-08, 0, -0.91950864, 0, 1, 0, 1, 0, -4.0192997e-08, 5.9148865, 0, 0.1678947)
[node name="tea_medium2" parent="." index="12" unique_id=1970222177 instance=ExtResource("16_qoeuy")]
[node name="tea_medium2" parent="." index="12" unique_id=1970222177 groups=["weather_node"] instance=ExtResource("16_qoeuy")]
transform = Transform3D(1.1652113, 0, 0, 0, 1, 0, 0, 0, 0.85860604, -4.215868, 0, -5.8837156)
[node name="sign" type="Marker3D" parent="." index="13" unique_id=1955169244]

View File

@@ -3,10 +3,12 @@
[ext_resource type="PackedScene" uid="uid://dujt3wgv8m4h3" path="res://tgcc/chunk/countryside/mesh/chunk_country_tea_empty.fbx" id="1_u5mxb"]
[ext_resource type="Script" uid="uid://dg2h4kbqe8j3m" path="res://core/biome_generator/chunk_info.gd" id="2_h7374"]
[ext_resource type="Material" uid="uid://cnu38m5dsy4uw" path="res://tgcc/chunk/material/terrain.tres" id="2_o4jpf"]
[ext_resource type="Shader" uid="uid://8l8glwvvs7fb" path="res://core/daynight/grass_leaves.gdshader" id="3_d4edy"]
[ext_resource type="Material" uid="uid://c2x7xxweexmj" path="res://tgcc/chunk/material/field.tres" id="3_h7374"]
[ext_resource type="Material" uid="uid://blqelpjvdv23j" path="res://tgcc/chunk/material/grassflat_chunk.tres" id="4_aco6i"]
[ext_resource type="Texture2D" uid="uid://bm0roy74xo3ce" path="res://tgcc/chunk/prop/flower/bush_alpha.png" id="4_h7374"]
[ext_resource type="Texture2D" uid="uid://bkuv31yvqmqr2" path="res://tgcc/chunk/prop/flower/bush_colornoise.tres" id="5_aco6i"]
[ext_resource type="Material" uid="uid://fnjxocmx16b7" path="res://tgcc/chunk/prop/grass/grass_chunk.tres" id="6_4u8k4"]
[ext_resource type="Material" uid="uid://d3pui0oy51fcg" path="res://tgcc/chunk/prop/tea/Tea.tres" id="6_d4edy"]
[ext_resource type="Material" uid="uid://bjrb33qwp1p43" path="res://tgcc/chunk/prop/grass/grass_chunk_weeds.tres" id="8_7lsuf"]
[ext_resource type="Material" uid="uid://0x17mj2v807r" path="res://tgcc/chunk/prop/grass/grass_chunk_weeds2.tres" id="9_rju47"]
[ext_resource type="PackedScene" uid="uid://cuh0xw6ff6bku" path="res://tgcc/chunk/prop/flower/flower.tscn" id="12_aco6i"]
@@ -14,6 +16,33 @@
[sub_resource type="PlaneMesh" id="PlaneMesh_1ivca"]
size = Vector2(0.5, 0.5)
[sub_resource type="ShaderMaterial" id="ShaderMaterial_lwafb"]
render_priority = 0
shader = ExtResource("3_d4edy")
shader_parameter/billboard_enabled = true
shader_parameter/wind_enabled = true
shader_parameter/base_color = Color(0.35581627, 0.61734307, 0.29309765, 1)
shader_parameter/alpha_texture = ExtResource("4_h7374")
shader_parameter/leaves_scale = 0.31
shader_parameter/rotation_degrees = 180.0
shader_parameter/texture_offset = Vector2(0, 0)
shader_parameter/opacity = 1.0
shader_parameter/color_variance_noise = ExtResource("5_aco6i")
shader_parameter/variance_scale = 0.3
shader_parameter/variance_color = Color(0.3019608, 0.5019608, 0.2, 1)
shader_parameter/variance_intensity = 0.400000019
shader_parameter/snow_color = Color(0.85, 0.9, 0.95, 1)
shader_parameter/snow_visibility = 2.0
shader_parameter/snow_coverage = 0.85
shader_parameter/height_min = 0.0
shader_parameter/height_max = 5.0
shader_parameter/shadow_intensity = 0.6000000285
shader_parameter/highlight_intensity = 0.0
shader_parameter/light_steps = 8.50000035625
shader_parameter/random_mix = 0.0150000007125
shader_parameter/cast_shadow_strength = 0.6
shader_parameter/wetness_darkening = 0.25
[sub_resource type="MultiMesh" id="MultiMesh_h7374"]
transform_format = 1
instance_count = 50000
@@ -44,17 +73,17 @@ buffer = PackedFloat32Array(-1.134027e-07, -0.9848538, 0.17906433, 9.567814, -1.
[node name="chunk_country_tea_empty" unique_id=578295477 instance=ExtResource("1_u5mxb")]
script = ExtResource("2_h7374")
[node name="Tea_001" parent="." index="0" unique_id=552394742]
[node name="Tea_001" parent="." index="0" unique_id=475850181]
visible = false
cast_shadow = 0
[node name="Terrain_002" parent="." index="1" unique_id=1215896429 groups=["weather_node"]]
[node name="Terrain_002" parent="." index="1" unique_id=149659069 groups=["weather_node"]]
surface_material_override/0 = ExtResource("2_o4jpf")
[node name="field" parent="." index="2" unique_id=1716644832]
[node name="field" parent="." index="2" unique_id=1674538997]
surface_material_override/0 = ExtResource("3_h7374")
[node name="grass_001" parent="." index="3" unique_id=572641767]
[node name="grass_001" parent="." index="3" unique_id=1653206836]
surface_material_override/0 = ExtResource("4_aco6i")
[node name="Tea2" type="Node3D" parent="." index="4" unique_id=515491080 groups=["weather_node"]]
@@ -66,7 +95,7 @@ mesh = SubResource("PlaneMesh_1ivca")
[node name="bush" type="MultiMeshInstance3D" parent="Tea2" index="1" unique_id=1391504191]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.36843967, 0)
material_override = ExtResource("6_d4edy")
material_override = SubResource("ShaderMaterial_lwafb")
cast_shadow = 0
multimesh = SubResource("MultiMesh_h7374")

File diff suppressed because one or more lines are too long

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

View File

@@ -1,41 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://ct606pxejnynh"
path.s3tc="res://.godot/imported/Fuji.png-b1e50176030f2e1f3fa87c0f275e476b.s3tc.ctex"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
}
[deps]
source_file="res://tgcc/chunk/material/decal/Fuji.png"
dest_files=["res://.godot/imported/Fuji.png-b1e50176030f2e1f3fa87c0f275e476b.s3tc.ctex"]
[params]
compress/mode=2
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=true
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=0

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

Some files were not shown because too many files have changed in this diff Show More