Skip to content

Instantly share code, notes, and snippets.

View zdimension's full-sized avatar

Tom Niget zdimension

View GitHub Profile
@zdimension
zdimension / names.txt
Created June 23, 2017 17:47
func names for main.exe
{65536L: 'VSyncFunc', 507904L: 'TestBoundsCollide', 90116L: 'MonkeySwingFall', 573448L: 'LaraBubbles', 342700L: 'SaveLevelData', 434188L: 'sub_6A00C', 116056L: 'lara_col_fastdive', 188448L: 'cranecut_end', 245796L: 'init_new_inventry', 581672L: 'GetStringDimensions', 204844L: 'andy10_end', 196660L: 'joby5_control', 106552L: 'lara_col_hangright', 417856L: 'SetDrawEnv', 401484L: 'mcOpen', 90204L: 'MonkeySwingSnap', 65636L: 'main', 68284L: 'DoLevel', 385144L: 'GPU_FlipNoIdle', 467068L: '_card_stop', 352384L: 'GetKeyTrigger', 106640L: 'SetCornerAnim', 462872L: 'InitHeap', 458912L: 'CD_sync', 598180L: 'SOUND_Stop', 401580L: 'mcClose', 105160L: 'lara_col_hang', 90292L: 'GetDirOctant', 188600L: 'cranecut_control', 524480L: 'do_the_flat_colursub_poly_tri', 90316L: 'TestMonkeyLeft', 180432L: 'UpdateSkyLightning', 434392L: 'SetRCnt', 598236L: 'SOUND_Init', 270560L: 'CreateEffect', 393444L: 'ReloadAnims', 114920L: 'lara_col_stepleft', 139508L: 'TargetBox', 581880L: 'UpdatePulseColour', 129748L: 'TriggerCDTrack', 286976L
using System;
using System.Collections;
using System.Collections.Generic;
namespace BiDictionary
{
/// <summary>
/// This is a dictionary guaranteed to have only one of each value and key.
/// It may be searched either by TFirst or by TSecond, giving a unique answer because it is 1 to 1.
/// </summary>
public class Unit
{
public string Name { get; }
public Lazy<Unit> _derivative;
public Unit Derivative => _derivative.Value;
private Lazy<Unit> _antiderivative;
public Unit Integral => _antiderivative.Value;
private static readonly Dictionary<string, Unit> _units = new Dictionary<string, Unit>();
@zdimension
zdimension / gen.php
Created August 4, 2020 22:50
Small PHP script that allows importing a Plex library directly into Radarr
<?php
// put this file in a web-served directory with a server that handles PHP files
// use the URL of the field as the "Trakt API" URL in Radarr
// (e.g. http://yourserver/somepath/gen.php)
// put your Plex library path here (escape eventual spaces using backslashes)
$res = `sqlite3 /storage/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db "select guid from metadata_items where guid like 'com.plexapp.agents.imdb%';" | grep -P 'tt\d+' -o`;
$movies = explode("\n", $res);
timeout() {
end=$(($(date +%s) + $1))
watch -c -n 1 -t 'toilet --gay -F border -t $(('"$end"' - $(date +%s)))'
}
from dataclasses import dataclass
from typing import Any, Callable
from enum import Enum
import operator
import string
@dataclass
class BinOperator:
symbol: str
from dataclasses import dataclass
from typing import Any
@dataclass
class List:
pass
@dataclass
class Empty(List):
def __iter__(self):
@zdimension
zdimension / options.pl
Created December 15, 2021 00:05
Calculateur d'options semestre 8
% CALCULATEUR D'OPTIONS SEMESTRE 8
% (c) 1989-1993 Tom Niget
% Programme testé sur 486-DX
% USAGE:
% ?- choix_options(+FILIERE, +OPTIONS DESIREES, +OPTIONS NON DESIREES, -OPTIONS1, -OPTIONS2)
%
% NB: Les options doivent être spécifiées par ordre ALPHABETIQUE!
% EXEMPLE:
@zdimension
zdimension / probleme1.pl
Created August 4, 2022 12:13
résolution prolog de problèmes de logique du test psychotechnique du CNED édition 1998
adjacent(A, B, List) :- nextto(A, B, List); nextto(B, A, List).
solve(AimeVoile) :-
length(Garcons, 4),
member(garcon(claude, treize, _, _), Garcons), % Claude est âge de treize ans
adjacent(garcon(_, _, tennis, _), garcon(_, _, _, policier), Garcons), % Le joueur de tennis s'entretient avec son voisin qui aime par-dessus tout les romans policiers
member(garcon(_, onze, nage, _), Garcons), % Le garçon de onze ans est un nageur accompli
member(garcon(_, dix, _, aventure), Garcons), % Celui qui préfère les livres d'aventures est âge de dix ans
adjacent(garcon(pierre, douze, _, _), garcon(_, _, tennis, _), Garcons), % Pierre, douze ans, parle avec son voisin qui pratique le tennis
nth1(1, Garcons, garcon(_, _, _, policier)), % Le joueur placé à l'extrême gauche est celui qui préfère les romans policiers

Making Windows 11 Usable

Remove Garbage

Sophia Script for Windows

Keep in mind that if you're not careful when selecting the settings, not only will it remove the preinstalled TikTok app but also the default photo viewer. Other than that works great.

Fix Explorer and Right Click Menus

Explorer Patcher