This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse | |
import glob | |
import re | |
# language/comment types supported | |
cpp = r'//' | |
python = r'#' | |
# keywords supported | |
todo = r'todo:' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// get the CPU speed (needed before screen res) | |
// FIXME: Excise this monstrosity. This has NO reason to exist any more. | |
if ( (m_iCpuSpeed = GetProfileInt ("Advanced", "CPUspeed", 0)) < 60 ) | |
{ | |
BOOL bGotSpeed = FALSE; | |
SYSTEM_INFO si; | |
::GetSystemInfo ( &si ); | |
if ( (si.wProcessorArchitecture == PROCESSOR_ARCHITECTURE_INTEL) && (si.wProcessorLevel >= 5) ) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
/---------------------------------------------------------------- | |
| | |
| DIBWND.CPP Window containing a bitmap. | |
| | |
| Child window containing a bitmap. Handles | |
| scrolling and resize. | |
| | |
| Copyright (c) 1996-1998 Ulrich von Zadow | |
| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
OJN file documentation | |
LITTLE ENDIAN | |
HEADER | |
INT genre | |
FLOAT bpm | |
short easy-leve | |
short med-level |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MyPawn extends UTPawn; | |
simulated function bool CalcCamera(float fDeltaTime, out vector out_CamLoc, out rotator out_CamRot, out float out_FOV) | |
{ | |
local vector start, end, hl, hn; | |
local actor a; | |
start = Location; | |
if (Controller != none) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
import numpy as np | |
import re | |
import string | |
from bitstring import BitStream, BitArray | |
from construct import * | |
in_file = open("dump.bin", "rb") | |
file_bytes = in_file.read() | |
s = structure | |
c = GreedyRepeater(SBInt16("foo")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
import numpy as np | |
import re | |
import string | |
from bitstring import BitStream, BitArray | |
from construct import * | |
in_file = open("dump.bin", "rb") | |
file_bytes = in_file.read() | |
c = GreedyRepeater(SBInt16("foo")) | |
parsed = c.parse(file_bytes) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
import numpy as np | |
import re | |
import string | |
from bitstring import BitStream, BitArray | |
in_file = open("dump2.bin", "r") | |
file_bytes = bytearray(in_file.read()) | |
i = 0 | |
b = 0 | |
for byte in file_bytes: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
output looks like this: | |
F | |
A | |
3 | |
G | |
5 | |
D | |
etc. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import string | |
from bitstring import BitStream, BitArray | |
in_file = open("dump.log", "r") | |
out_file = open("dump.bin", "w") | |
text = in_file.read() | |
in_file.close() | |
split_text = text.splitlines() | |
for line in split_text: | |
blocks = line.split(' ') | |
for block in blocks: |