Skip to content

Instantly share code, notes, and snippets.

The following IDs were copied from the Celeste FMOD Studio project.
They can be found in event:/char/madeline/footstep - thanks to Kevin Regamey from PowerUp Audio!

Entries marked as (unused) don't have any sound associated to them.
ID 20 doesn't have a sound associated to it in the public Celeste FMOD Studio project.
IDs 38 - 44 aren't listed in the FMOD Studio project comment. The names for those IDs were chosen by the community and match the sound file names and in-game usage.
The surface index parameter goes up to 50, but IDs 45 - 50 aren't used.

  1. null
  2. asphalt
@0x0ade
0x0ade / HookGenTest.cs
Last active June 19, 2021 23:11
TerrariaHooks / HookGen example using On. += and IL. +=
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Mono.Cecil;
using Mono.Cecil.Cil;
using MonoMod.RuntimeDetour.HookGen;
using System;
using System.IO;
using System.Reflection;
using Terraria;
using Terraria.ModLoader;

Keybase proof

I hereby claim:

  • I am 0x0ade on github.
  • I am 0x0ade (https://keybase.io/0x0ade) on keybase.
  • I have a public key ASA4Um_a3qXLTgxxLnb7RasnXoMY7KNKfhD7ka0nye-ZHAo

To claim this, I am signing this object:

using System;
using System.Collections.Generic;
using System.Numerics;
using SDL2;
using ImGuiNET;
using ImGuiSDL2CS;
namespace YourGameNamespace {
public class YourGameWindow : ImGuiSDL2CSWindow {
@0x0ade
0x0ade / Common.cs
Created August 5, 2017 11:05
YO! Noid 2: Enter The Void - Custom aspect ratio MonoMod
#pragma warning disable CS0626 // Method, operator, or accessor is marked external and has no attributes on it
using UnityEngine;
using MonoMod;
using System;
using UnityEngine.SceneManagement;
using UnityEngine.UI;
public static class Common {
@0x0ade
0x0ade / FNADroid-Graphics-Log.md
Last active January 20, 2017 14:29
Alternate title: "This could become a fun drinking game.md"

FNADroid graphics bug debugging log:

  • glDrawElements instead of glDrawRangeElements: Nope. Android monitor GL ES profiler behaves differently - glDrawElements calls are blue.
  • Manual texture mode changes: Changes got applied on both PC and Android, but it didn't magically fix any issues.

  • Replacing the effect of the vibrating membrane in the FEZ 32 bit ending with another one used in the game: MESH VISIBLE!
  • Textures and geometry seem fine (except when using HW instancing). Issue seems to be effect related.
diff --git a/mojoshader.c b/mojoshader.c
index 90f0cf9..d897637 100644
--- a/mojoshader.c
+++ b/mojoshader.c
@@ -2205,9 +2205,11 @@ static void emit_GLSL_start(Context *ctx, const char *profilestr)
else
output_line(ctx, "precision mediump float;");
output_line(ctx, "precision mediump int;");
- output_line(ctx, "varying vec4 v_FrontColor;");
- output_line(ctx, "varying vec4 v_FrontSecondaryColor;");
@0x0ade
0x0ade / throttle.sh
Last active September 20, 2019 01:16
#!/bin/bash
# throttle - utility throttling applications according to CPU temperature.
# Usage: throttle.sh <PID>
# Alternatively: throttle.sh <your command here>
# Version: 1
# Changelog:
# 1:
# * Configuration vars are only set if not already set (per-app config. via env.)
# * Added QUIET configuration
# * Added notify-send support
@0x0ade
0x0ade / xna-touch-data.md
Last active June 22, 2018 14:57
XNA4 touch data

Main data:

XNA FNADroid FNA
ID Ascending HW / system identifier (1) Ascending, next free (Android-esque) Ascending, n-th touch
Desktop support None (Win7 only, stub) Disabled by default; FNA_TOUCH_FORCE_ENABLE Enabled
Multi-touch-capable Yes Yes Broken
MT Drag gestures First touch only Additional touches inherit first touch gesture ----

|

diff --git a/src/Graphics/OpenGLDevice.cs b/src/Graphics/OpenGLDevice.cs
index f2451ec..d830a73 100644
--- a/src/Graphics/OpenGLDevice.cs
+++ b/src/Graphics/OpenGLDevice.cs
@@ -8,7 +8,7 @@
#endregion
#region DISABLE_FAUXBACKBUFFER Option
-#define DISABLE_FAUXBACKBUFFER
+// #define DISABLE_FAUXBACKBUFFER