This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// @function TGINAssert(assertExpr, assertMsg) | |
/// @description assert() like function, do not use in your game code. | |
/// @param {bool} assertExpr boolean-ish exception | |
/// @param {string} assertMsg string that will be used if an assertion had failed. | |
/// @returns nothing, throws on error | |
function TGINAssert(assertExpr, assertMsg) { | |
if (!assertExpr) | |
throw string_replace("TGINParse: Assertion Failed: %s", "%s", string(assertMsg)); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// @function Rutranslit([useSoftSigns]) | |
/// @param {bool} [useSoftSigns] (optional) true - Translit soft signs, false - ignore them. | |
/// @description This class allows you to convert Russian strings to English translit. | |
/// @returns {Rutranslit} self | |
function Rutranslit(useSoftSigns) constructor { | |
// private: | |
m_lookup = undefined; | |
/// @description (private) Initializes the lookup table. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// See https://aka.ms/new-console-template for more information | |
var namespath = @"C:\ProgramData\GameMakerStudio2-Dev\Cache\runtimes\runtime-9.9.1.2226\fnames"; | |
var lines = File.ReadAllLines(namespath); | |
var specchars = new[] { '#', '*', '@', '&', '$', '£', '!', '%', '?', '[', '(' }; | |
Console.WriteLine("// copy and paste me into your game:"); | |
foreach (var sline in lines) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! how to compile: `csc Program.cs -r:Mono.Cecil.dll` | |
* how to use: `mono Program.exe /opt/GameMakerStudio2/IDE.dll` | |
* OR, FOR RED: `mono Program.exe /opt/GameMakerStudio2-Dev/IDE.dll` | |
* | |
* the Cecil dll can be obtained manually from NuGet. (which is what I did) | |
* thanks to YoYo not obfuscating Linux builds, we can easily do our funky stuff. | |
* | |
* also hi to all YoYo employees reading this, please take care of yourself, hydrate, | |
* go outside (in a mask), take breaks from work, and don't patch this program, or I will become vewy sad :< | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#nullable enable | |
using System; | |
using System.Net.Sockets; | |
using System.Runtime.Serialization; | |
using System.Text; | |
namespace nkrapivindev | |
{ | |
/// <summary> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
some may only work on Linux, or only on consoles... | |
usage: debug_event("thing here"); | |
DumpMemory - prints the amount of allocated memory to console (Total memory used 0xblabla bytes) | |
CheckGLError - I assume it's supposed to ignore OpenGL errors? But it seems to be unused lol. | |
VMTraceOn - sets g_fVMDebug to true | |
VMTraceOff - sets that variable to false |
NewerOlder