Skip to content

Instantly share code, notes, and snippets.

View Pieeer1's full-sized avatar

Mason Adams Pieeer1

  • 14:13 (UTC -07:00)
View GitHub Profile
@Pieeer1
Pieeer1 / Extensions.cs
Created November 21, 2023 18:36
Navigation Manager and World Manager for Dynamic Runtime Changes
using Godot;
using System.Collections.Generic;
using System.Linq;
namespace Project.Extensions;
public static class GodotExtensions
{
public static T? GetChildByType<T>(this Node node, bool recursive = true)where T : Node
{
int childCount = node?.GetChildCount() ?? 0;
@Pieeer1
Pieeer1 / LobbyJoiningExample.cs
Created January 6, 2024 01:28
Steam Multiplayer Peer with Facepunch Steamworks (C# API)
Lobby.Join(); // you are going to have to pull the lobby from somewhere. Run the callback for getting the lobby list somewhere
// holy shit terrible implementation eventually fix this
//this is due to the fact that a second connection does not have access to the lobby owner id until it is joined.
//fucking why???
Timer timer = new Timer();
AddChild(timer);
timer.OneShot = true;
timer.WaitTime = 1.0d;