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
export class Spring { | |
target: number = 0; | |
position: number = 0; | |
velocity: number = 0; | |
frequency: number = 0.2; | |
damping: number = 1; | |
constructor(frequency: number = 0.2, damping: number = 1) { |
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
import { Vector3 } from "@milk-ecs/core"; | |
import { System } from "typescript"; | |
export type SpringParams = { | |
posPosCoef: number; | |
positionVelCoef: number; | |
velPosCoef: number; | |
velocityVelCoef: number; | |
}; |
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
[ | |
{ | |
"backcolor": "#b0b0b0", | |
"name": "M65 SA/DSA Template" | |
}, | |
[ | |
{ | |
"c": "#ff6b6b", | |
"t": "464646", | |
"p": "SA", |
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
open /Applications/Google\ Chrome.app --args --disable-3d-apis |
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
enum Opcodes { | |
NAME_CHANGE = "nameChange", | |
POSITION = "position" | |
} | |
type NameChangePacket = { | |
opcode: Opcodes.NAME_CHANGE, | |
name: string | |
}; |
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
abstract class System<T extends { [index:string]:Component[] }> { | |
query: { [P in keyof T]?: QueryCollection<T[P][]> } | |
} | |
class QueryCollection<T> { | |
components:T; | |
listen?: { | |
added?: (value:T) => void; | |
removed?: (value:T) => void; | |
} |
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
interface Config { | |
boxColor: number, | |
backgroundColor: number, | |
modelUrl: string, | |
} | |
class Game { | |
options: Config; | |
constructor(options: Config) { |
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
/* ============================================================ | |
* jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ | |
* | |
* Open source under the BSD License. | |
* | |
* Copyright © 2008 George McGinley Smith | |
* All rights reserved. | |
* https://raw.github.com/danro/jquery-easing/master/LICENSE | |
* ======================================================== */ |
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
function createGameObject<T>(string id, object data, string ?parentId) | |
{ | |
var parent = (parentId == null) ? stage : networkObject.get(parentId); | |
var gameObject = new T(id, data); | |
networkObjects.set(id, gameObject); | |
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
package ; | |
import events.BaseEventHandler; | |
import events.EventHandler; | |
import externs.math.Matrix; | |
import externs.Player; | |
import luaxe.lib.LuaTable; | |
@:native("_G") @dotpath | |
extern class Globals |
NewerOlder