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
// Taken from https://gist.github.com/Sainan/e290bef8b482005a01f3444d3341ac5f | |
// and https://web.archive.org/web/20211024160434/https://pastebin.com/Kj9t38KF. | |
std::vector<std::string> radio_stations{ | |
"RADIO_11_TALK_02", // Blaine County Radio | |
"RADIO_12_REGGAE", // The Blue Ark | |
"RADIO_13_JAZZ", // Worldwide FM | |
"RADIO_14_DANCE_02", // FlyLo FM | |
"RADIO_15_MOTOWN", // The Lowdown 9.11 | |
"RADIO_20_THELAB", // The Lab |
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
/** | |
* Python-like range function | |
* | |
* @param start {Number} Start value, inclusive, if end isn't provided, start is end | |
* @param end {Number|null} End value, exclusive, defaults to null | |
* @param step {Number} Step value, default to 1 | |
* @returns {Array} [start, start+step, start+step*2, ..., end - 1] | |
*/ | |
const range = (start, end=null, step=1) => { |
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
#include <cocos2d.h> | |
#include <gd.h> | |
class Layer : public gd::FLAlertLayer | |
{ | |
public: | |
CCMenu* m_pMenu{}; | |
void onEnter() override | |
{ |
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
CPP_TYPE_SPECIFIERS = ("unsigned", "signed") | |
CPP_TYPE_QUALIFIERS = ("const", "volatile") | |
def parse_str_args(args_str: str) -> list[tuple[str]]: | |
"""Mini parser that converts a string of arguments | |
into a list of tuples in the form of ("type", "name"). | |
Supports templates, named and unnamed arguments, | |
as well as stuff like long long, const short int... |
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 idaapi | |
import struct | |
MINIMUM_OS_VERSION_LOAD_COMMAND = 0x32 | |
# https://en.wikipedia.org/wiki/Mach-O#Minimum_OS_version | |
PLATFORM_TYPES = { | |
0x00000001: "macOS", | |
0x00000002: "iOS", | |
0x00000003: "tvOS", | |
0x00000004: "watchOS", |