This file contains hidden or 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
Show hidden characters
{ | |
"JSON Console Log": { | |
"scope": "javascript,javascriptreact,typescript,typescriptreact", | |
"prefix": "jcl", | |
"body": [ | |
"console.log('$1: ', JSON.stringify($1, null, 4));", | |
], | |
"description": "Log JSON stringified output to console" | |
} | |
} |
This file contains hidden or 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
// Based on Christer Ericson's talk on floating point tolerance | |
// http://realtimecollisiondetection.net/blog/?p=89 | |
const approximatelyEqual = (a: number, b: number, tolerance: number = 0.000001) => { | |
return (Math.abs(a - b) <= tolerance * Math.max(1.0, Math.max(Math.abs(a), Math.abs(b)))); | |
} | |
console.log(approximatelyEqual(3.56999999, 3.57)); // true | |
console.log(approximatelyEqual(4.001, 4.002)); // false |
This file contains hidden or 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 <stdbool.h> | |
#include <stdint.h> | |
#include <stdlib.h> | |
#define MOJOSHADER_NO_VERSION_INCLUDE | |
#define MOJOSHADER_EFFECT_SUPPORT | |
#include <mojoshader.h> | |
#include <mojoshader_effects.h> | |
#define SDL_MAIN_HANDLED |
This file contains hidden or 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
{ | |
"terminal.integrated.shell.windows": "cmd.exe", | |
"terminal.integrated.env.windows": { | |
"CMDER_ROOT": "D:\\cmder" | |
}, | |
"terminal.integrated.shellArgs.windows": [ | |
"/k", | |
"%CMDER_ROOT%\\vendor\\bin\\vscode_init.cmd" | |
], | |
} |
This file contains hidden or 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
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"name": "(Windows) Launch", | |
"type": "cppvsdbg", | |
"request": "launch", | |
"program": "${workspaceRoot}/target/debug/${workspaceRootFolderName}", | |
"args": [], | |
"stopAtEntry": false, |
This file contains hidden or 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
// This file is for the speedrun community to use as a base for | |
// their LiveSplit autosplitter. You can set it up to read the | |
// memory you've layed out, and they can take it from there. | |
state("GameName") { | |
} | |
startup { | |
vars.scanTarget = new SigScanTarget(0, | |
"de c0 ad de de c0 37 13" // tag (0x1337c0dedeadc0de) |
This file contains hidden or 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 "TaskQueue.hpp" | |
namespace NinjaParty | |
{ | |
bool TaskQueue::IsComplete() const | |
{ | |
return tasks.empty(); | |
} | |
void TaskQueue::Update(float deltaSeconds) |