Skip to content

Instantly share code, notes, and snippets.

using UnityEngine;
using UnityEditor;
using Mirror;
using kcp2k;
using Mirror.FizzySteam;
public class NetworkingEditorUtils : MonoBehaviour
{
public class EditorLayersUtils
{
@adriano-t
adriano-t / CreateEvent.gml
Created October 20, 2025 13:09
Input manager real example
enum Action {
interact,
run,
crouch,
drop,
open_tama,
move_hor,
move_ver,
view_hor,
global.local_storage = [];
global.local_storage_slot = 0;
global.local_storage_max_save_slots = 1; // You can change this to the desired number of slots
for (var i = 0; i < global.local_storage_max_save_slots; i++) {
var fname = "save_slot_" + string(i) + ".json";
global.local_storage[i] = {
fname: fname,
data: {}
@adriano-t
adriano-t / InputManager.gml
Last active November 12, 2026 07:16
Input Manager for GameMaker Studio 2
enum InputSource {
KEYBOARD,
MOUSE,
GAMEPAD
}
enum GamepadType {
Xinput,
DirectInput,
}
@adriano-t
adriano-t / mc-serverstatus.py
Created January 4, 2024 14:36
Minecraft Server Status Discord Webhook Script
# Minecraft Server Status Discord Webhook Script
#This Python script periodically checks the status of a Minecraft server and sends updates to a Discord webhook. It utilizes the mcstatus library to query the server status, and the requests library to send webhooks to a specified Discord channel.
### Features:
#- Displays the initial player count upon script start.
#- Monitors player joins and leaves, sending corresponding updates to the Discord webhook.
#- Supports custom intervals for status checks.
#- Gracefully handles manual script interruption (Ctrl+C).
labels = array_create(0);
times = array_create(0);
best_score = 0;
mystruct = function() constructor
{
a = 10;
static test_function = function(a, b )
{
@adriano-t
adriano-t / js2exe.md
Last active August 17, 2020 21:50
Create a .exe from electron node.js app using kataconda online playground