Skip to content

Instantly share code, notes, and snippets.

View BitPatty's full-sized avatar
🐕
Walking my watchdog

Matteias Collet BitPatty

🐕
Walking my watchdog
View GitHub Profile
@BitPatty
BitPatty / qftimer.s
Created September 16, 2024 17:49 — forked from QbeRoot/qftimer.s
Source for Quarterframe Timer
qftRect = 0x817F0094 # u32[4] coordinates of the textbox relative to the top left corner of the screen, in order: left X, top Y, right X, bottom Y
qftFormat = 0x817F00A4 # string printf format string of the timer, containing 3 specifiers for minutes, seconds and milliseconds in order
qftStop = 0x817F00B2 # bool if nonzero, the timer is stopped on the value of qftOffset, otherwise it continues to run
qftReset = 0x817F00B3 # bool if nonzero, the timer will restart from 0 in the next area, otherwise it will continue where it left off
qftOffset = 0x817F00B4 # u32 cumulative time spent in previous areas since the last reset, includes current area iff qftStop is true
qftFreezeTime = 0x817F00B8 # u32 fixed time to be displayed if qftFreezeFor > 0 and qftStop is false, only includes current area
qftFreezeFor = 0x817F00BC # u32 duration of a timer freeze (in frames)
qftTextBox = 0x817F0110 # J2DTextBox textbox used to render the timer (0x128
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
/**
* Runs the specified task until the specfied
* condition is met
*
* @param task The task to run
* @param breakCondition The breaking condition
* @param timeout The timeout between attempts in miliseconds
* @param options Additional options to tweak the timeout and
* max retry count
*/
$Hscroll = Get-Process | ? Name -eq "HscrollFun"
If ($Hscroll -eq $null){
Start-Process -FilePath "C:\Program Files (x86)\Lenovo\ThinkPad Compact Keyboard with TrackPoint driver\HScrollFun.exe"}
else {
"running"
}
@BitPatty
BitPatty / profiles.json
Created February 28, 2020 22:17
WSL Configuration
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"defaultProfile": "{2c4de342-38b7-51cf-b940-2309a097f518}",
"alwaysShowTabs": false,
"showTabsInTitlebar": false,
@BitPatty
BitPatty / WinError.cs
Created April 27, 2018 08:23
Enum containing all the system error codes from https://msdn.microsoft.com/en-us/library/windows/desktop/ms681382(v=vs.85).aspx (Not including ERROR_INTERNET_* 0x2E00 - 0x2EE0)
public enum Win32Error : uint
{
/// <summary>The operation completed successfully.</summary>
ERROR_SUCCESS = 0x0,
/// <summary>Incorrect function.</summary>
ERROR_INVALID_FUNCTION = 0x1,
/// <summary>The system cannot find the file specified.</summary>
ERROR_FILE_NOT_FOUND = 0x2,