Skip to content

Instantly share code, notes, and snippets.

View DeltaJordan's full-sized avatar

DeltaJordan DeltaJordan

View GitHub Profile
@DeltaJordan
DeltaJordan / ReflectionFix.md
Created January 17, 2025 07:41
Garry's Mod AMD Reflection Fix (Windows)

If anyone is having issues with missing textures in reflections and they use AMD graphics, I finally found why it happens and a workaround to fix it: Here's the bug report explaining why it happens: Facepunch/garrysmod-issues#5755

How to fix it (kinda):

  1. Download dxvk-x.x.x.tar.gz from here: https://github.com/doitsujin/dxvk/releases/latest
  2. Extract it somewhere. You will need something like 7zip to open it.
  3. Copy /x32/d3d9.dll to GarrysMod/bin. You can access your GarrysMod folder by right clicking the game in Steam > Installed Files > Browse
  4. Launch the game.

Caveats:

@DeltaJordan
DeltaJordan / Davfernape.MD
Last active March 26, 2020 22:51
3-25-20 Splatoon 2 VOD Review (WIP)

Overall Analysis (As of Match 1)

I don't really have much specifics to say for this match. Positioning was pretty good, you stayed near the middle of your team, and provided armors. I think you did well overall.

@DeltaJordan
DeltaJordan / SafeAltarsWorld.cs
Created December 25, 2019 08:56
SafeAltarsSnippet
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using MonoMod.Cil;
using Terraria.ModLoader;
namespace SafeAltars
{
@-moz-document domain(frackinuniverse.fandom.com)
{
/*
================
Wikia
================
*/
/* Seach box */
@DeltaJordan
DeltaJordan / TIReadme.md
Last active August 8, 2018 06:12
Twitch Commands

Song Request Commands


!songrequest (Alias: !sr) [YouTube link] - Add a song to the queue that will then play on stream. Current song is displayed on stream.


Mario Party Commands

5 Points are earned when a new game starts. Points are earned in three other ways: Following (1), Donations ($amount * 1 points), bits (increments of 100 give 1 point), and subscribing (2). Donations also allow you to request songs.

!redeem - Redeems the new game points if you missed the automated command.

public void Send(TCPPacket packet)
{
// I recommend making your own TCPPacket class to store these values
byte[] buffer = TCPPacket.GetBinaryHeader()
// Text header length
.Concat(BitConverter.GetBytes(packet.TextHeader.Length))
// Text header, used for switch/case selecting of parameter handling
.Concat(Encoding.UTF8.GetBytes(packet.TextHeader))
// Concat byte arrays with Seperator string in between. Note that Seperator string only is between parameters and is not required before the binary footer.
/*
Item spawns 0x00409428 to 0x00415404
Each dungeon item list has a Pointer that can point at either a Category or Item on the above list.
The Pointer's default position is 0 (Thrown - Pierce) at the beginning of each dungeon item list.
Whenever a rarity number is read by the game, the Pointer automatically increments by 1.
As found out by Lee, XX 75 numbers are Skip numbers.
A Skip number increments the Pointer by the Skip Number's decimal value minus 30000.
Once the Pointer has passed Category # F, it will automatically go into the hex item list as shown above.
Additionally, the game treats number 183 of the hex item list as Coins instead of None.
There is no actual Category # for Coins. Instead, if Coins can be found on that dungeon Floor, the Coin Category
await vnc.SendSpeakingAsync(); // send a speaking indicator
ProcessStartInfo psi = new ProcessStartInfo
{
FileName = "ffmpeg",
Arguments = @"-i pipe:0 -ac 2 -f s16le -ar 48000 pipe:1",
RedirectStandardOutput = true,
RedirectStandardInput = true,
UseShellExecute = false
};
private List<Card> InitializeDeck()
{
// Create the list to hold the cards
List<Card> resultCards = new List<Card>();
// Add the numbered cards
for (int i = 1; i < 10; i++)
{
resultCards.Add(new Card
{
/// <summary>
/// Splits an IEnumerable&lt;string&gt; to a enumerable list of enumerable lists that can be then used to bypass char limits
/// </summary>
/// <param name="listToSplit">IEnumerable&lt;string&gt; that will be split</param>
/// <param name="charLimit">Limit of characters base split on</param>
/// <param name="joiningCharCount">Optional joining char count to apply to char counting</param>
/// <returns></returns>
public IEnumerable<IEnumerable<string>> SplitToLists(IEnumerable<string> listToSplit, int charLimit, int joiningCharCount = 0)
{
List<List<string>> splitLists = new List<List<string>>();