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
| -- incline | |
| for i = 0, 10, 0.5 do | |
| makeOrb(-2, i, i + 1) | |
| makeOrb(-1, i, i + 1) | |
| makeOrb(0, i, i + 1) | |
| makeOrb(1, i, i + 1) | |
| makeOrb(2, i, i + 1) | |
| end | |
| -- vertical |
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 OnTemplate() | |
| self.AddModel('btoast.models.trophy') | |
| self.CreateSphereCollisions() | |
| self.MakeBuildable() | |
| -- self.AddTexture('btoast.textures.trophy') | |
| end | |
| function OnClone() | |
| self.RegisterListener(Messager.OnEnable, Enabled) | |
| self.RegisterEntityWithTag("solartrophy") |
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
| { | |
| // Place your snippets for json here. Each snippet is defined under a snippet name and has a prefix, body and | |
| // description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are: | |
| // $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the | |
| // same ids are connected. | |
| // Example: | |
| // "Print to console": { | |
| // "prefix": "log", | |
| // "body": [ | |
| // "console.log('$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
| Vector = {} | |
| function Vector:new(o) | |
| o = o or {} | |
| setmetatable(o, self) | |
| self.__index = self | |
| return o | |
| end | |
| function Vector:goBack(n) | |
| local newVector = Vector:new({}) |
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
| // TODO the mentions are all smooshed together. the next needs to include a space between each one | |
| class MentionPayload { | |
| constructor(mentionArray) { | |
| this.type = "paragraph"; | |
| this.content = [ | |
| { | |
| type: "text", | |
| text: "Automated reminder for: " | |
| }, |
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
| require('dotenv/config'); | |
| const _ = require('lodash'); | |
| const logger = require('./myWinston')('binance'); | |
| const binance = require('node-binance-api'); | |
| const calc = require('./calc'); | |
| Object.prototype.renameProp = function(currentPropName, newPropName) { | |
| this[newPropName] = this[currentPropName]; | |
| delete this[currentPropName]; | |
| } |
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 fibberGonnaFib(count) { | |
| var fibs = []; | |
| for (var i = 0; i < count; i++) { | |
| fibs.push((fibs[fibs.length - 1] || 1) + (fibs[fibs.length - 2] || 0)) | |
| } | |
| return fibs[fibs.length - 1]; | |
| } | |
| var theFibbening = []; |
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
| var t = new Tree(); | |
| t.addNode(21) | |
| t.addNode(74) | |
| t.addNode(3) | |
| t.addNode(7) | |
| t.addNode(5) | |
| t.addNode(63) | |
| t.addNode(58) | |
| t.addNode(57) | |
| t.logValues(102); |
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
| var obj = { | |
| done: function () { | |
| if (this.hasOwnProperty('tasks')) { | |
| console.log('each task is complete:'); | |
| for (let task of this.tasks) { | |
| console.log(`-- ${task}: ${this[task]}`); | |
| } | |
| } | |
| } | |
| } |
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 DeFIBrulator() { | |
| this.sequence = []; | |
| this.fibStep = function fibStep(count = 1) { | |
| if (count) { | |
| for (var i = 0; i < count; i++) { | |
| this.x = (this.y + this.z) || 1; | |
| this.sequence.push(this.x) | |
| } | |
| } | |
| }; |