Skip to content

Instantly share code, notes, and snippets.

; #########################################################################
.586
.model flat, stdcall
option casemap :none ; case sensitive
; #########################################################################
include \masm32\include\windows.inc
include \masm32\include\kernel32.inc
@untoxa
untoxa / gist:43677e603df64b9bb58bb0910d827b7a
Last active June 14, 2020 19:31
DMG Fading functions allows to fade in/out to black and in/out to white
UBYTE DMGFadetoWhiteStep(UBYTE pal, UBYTE step) __naked {
pal; step;
__asm
lda HL, 3(SP)
ld A, (HL-)
ld E, (HL)
or A
ret Z
ld D, A
@untoxa
untoxa / 1. profiler stat calculator
Last active May 10, 2020 08:50
stat calculator python script and example files
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# vim: sts=4 sw=4 et
# Description: profile calculator
# Author: Tony Pavlov (untoxa)
# SPDX-License-Identifier: MIT
import sys
symbols = {}
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# vim: sts=4 sw=4 et
import sys
from struct import unpack
from array import array
def read_snspshot(snapshot_name):
def readasciiz(f):