From 68f973a695df7c239a44920a8e818108e86aa7ae Mon Sep 17 00:00:00 2001 From: = <=> Date: Sun, 19 Apr 2026 13:04:14 +0200 Subject: [PATCH] Added steam to the project but deactivated for now --- Scripts/SteamworksHandler.cs | 28 ++++++++++++++++++++++++++++ Scripts/SteamworksHandler.cs.uid | 1 + steam_appid.txt | 1 + 3 files changed, 30 insertions(+) create mode 100644 Scripts/SteamworksHandler.cs create mode 100644 Scripts/SteamworksHandler.cs.uid create mode 100644 steam_appid.txt diff --git a/Scripts/SteamworksHandler.cs b/Scripts/SteamworksHandler.cs new file mode 100644 index 0000000..667fd16 --- /dev/null +++ b/Scripts/SteamworksHandler.cs @@ -0,0 +1,28 @@ +using Godot; +using GodotSteam; +public partial class SteamworksHandler : Node +{ + public override void _Ready() + { + return; + SteamInitExStatus status = Steam.SteamInitEx(false).Status; + if (status != 0) + { + GD.Print("Steam not initialized!"); + return; + } + + GD.Print("Steam initialized!"); + GD.Print("User: " + Steam.GetPersonaName()); + } + + public override void _Process(double delta) + { + Steam.RunCallbacks(); + } + + public override void _ExitTree() + { + Steam.SteamShutdown(); + } +} diff --git a/Scripts/SteamworksHandler.cs.uid b/Scripts/SteamworksHandler.cs.uid new file mode 100644 index 0000000..753df3b --- /dev/null +++ b/Scripts/SteamworksHandler.cs.uid @@ -0,0 +1 @@ +uid://dqrdb3bvws6b6 diff --git a/steam_appid.txt b/steam_appid.txt new file mode 100644 index 0000000..7ad8022 --- /dev/null +++ b/steam_appid.txt @@ -0,0 +1 @@ +480 \ No newline at end of file