Skip to content

Instantly share code, notes, and snippets.

View tildejustin's full-sized avatar

tildejustin

View GitHub Profile
@tildejustin
tildejustin / libraries.csv
Created December 18, 2024 18:36
mc libraries by version from vanilla launcher meta. iirc this is also in the legacy fabric instances repo for lwjgl reference.
version argo asm-all authlib bcprov-jdk15on blocklist brigadier codecjorbis codecwav commons-codec commons-compress commons-io commons-lang3 commons-logging datafixerupper failureaccess fastutil gson guava httpclient httpcore icu4j icu4j-core-mojang java-objc-bridge-osx javabridge jinput jinput-platform jna jna-platform joml jopt-simple jutils launchwrapper libraryjavasound librarylwjglopenal log4j-api log4j-core log4j-slf4j18-impl log4j-slf4j2-impl logging lwjgl lwjgl-!osx lwjgl-glfw lwjgl-glfw-!osx lwjgl-glfw-natives-linux lwjgl-glfw-natives-macos lwjgl-glfw-natives-macos-arm64 lwjgl-glfw-natives-windows lwjgl-glfw-natives-windows-arm64 lwjgl-glfw-natives-windows-x86 lwjgl-glfw-osx lwjgl-jemalloc lwjgl-jemalloc-!osx lwjgl-jemalloc-natives-linux lwjgl-jemalloc-natives-macos lwjgl-jemalloc-natives-macos-arm64 lwjgl-jemalloc-natives-windows lwjgl-jemalloc-natives-windows-arm64 lwjgl-jemalloc-natives-windows-x86 lwjgl-jemalloc-osx lwjgl-natives-linux lwjgl-natives-macos lwjgl-natives-macos-arm64 lwjgl-natives-w
@tildejustin
tildejustin / MaC_speedrunigt_debug_log.txt
Created December 18, 2024 18:35
log from speedrunigt MaC dev, just looks cool
Prism Launcher version: 8.0 (archlinux)
Launched instance in online mode
authserver.mojang.com resolves to:
[**.**.**.**, **.**.**.**, **.**.**.**, **.**.**.**]
session.minecraft.net resolves to:
[**.**.**.**, **.**.**.**, ****:****:****:****:****:****:****:****, ****:****:****:****:****:****:****:****]
@tildejustin
tildejustin / 1.18-set-spawn-write-up.md
Created August 25, 2024 02:22
something about spawn logic that i wrote sometime last year

assuming getSpawnRadius -> 10 for now for simplicity
and assuming player is further from the world border than the spawnRadius, again, for simplicity
i = 10: spawnRadius
l = 21: width / height of spawn square
m = 441: area of spawn square
k = m = 441: area of spawn square (integer overflow safe)
n = 17: spawnOffsetMultiplier, is 17 if area of spawn square is > 16, which it almost certainly is
o is random called in range of k (spawn square area)
p = 0: start of a loop maxing out in k steps, p is incremented every time
in loop:

@tildejustin
tildejustin / villagechance.py
Created August 25, 2024 02:16
villager trade probability simulator for 1.3
import random
def add_item(name: str, chance: float, offers_list: list):
if random.random() < chance:
offers_list.append(name)
def get_brown_coat_trade() -> str:
new_offers = []
add_item("wheat", .9, new_offers)
add_item("wool", .5, new_offers)
@tildejustin
tildejustin / end_hash.py
Created August 25, 2024 02:13
20w14inf something or other sitting on my hard drive
import hashlib
import random
# 264^4 dimensions
# need hash to equal 2
def get_string(input: str) -> str:
# stolen from net.minecraft.world.dimension.DimensionHashHelper$getHash
return input + ":why_so_salty#LazyCrypto"
This file has been truncated, but you can view the full file.
tiny 2 0 official intermediary named
c a net/minecraft/class_1442 net/minecraft/util/Formatting
f Z A field_5480 modifier
f Ljava/lang/String; B field_5481 stringValue
f I C field_9145 colorIndex
f [La; D field_5482 field_1072
f La; a field_5483 BLACK
f La; b field_5484 DARK_BLUE
f La; c field_5485 DARK_GREEN
f La; d field_5486 DARK_AQUA
{
"schemaVersion": 5,
"mods": [
{
"modid": "sodium",
"name": "Sodium",
"description": "Sodium is a free and open-source optimization mod for Minecraft which improves frame rates and reduces lag spikes.",
"versions": [
{
"target_version": [
Subject: [PATCH] personal changes
---
Index: config.def.h
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/config.def.h b/config.def.h
--- a/config.def.h (revision a34d8fb4327bbb1afd92e7527c53fcaad547a495)
+++ b/config.def.h (date 1700268761282)
@tildejustin
tildejustin / brightness.sh
Last active November 17, 2023 13:02
note to self: in /usr/local/bin
#!/bin/bash
curr_brightness=$(cat /sys/class/backlight/intel_backlight/brightness)
curr_brightness=$(($curr_brightness))
max_brightness="$(cat /sys/class/backlight/intel_backlight/max_brightness)"
max_brightness=$(($max_brightness))
brightness=0
# -10%: decrease by a percentage, not going below 0
# +10%: increase by a percentage, not going above $max_brightness
# 10%: set to an absolute percentage between 0 and $max_brightness
# 10: set to an absoulte brightness not exceeding #max_brightness