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
-- When running this code in LOVE, the player's top left corner dot and square will follow the top left corner of the white square | |
-- When running this code on hardware with LovePotion for switch, the dot will not follow the top left corner of the white square, but the square will | |
camera = {} | |
camera._x = 0 | |
camera._y = 0 | |
function camera:set() | |
love.graphics.push() | |
love.graphics.translate(-self._x, -self._y) |
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
// Require Twitter module | |
const twitter = require('twitter'); | |
// Define list of triggers, username, last tweet, and interval object : | |
triggers = []; | |
username = ""; | |
interval = null; | |
lastTweet = ""; | |
// Constructor |
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
if(process.argv[2] == undefined) | |
{ | |
console.log("No song specified"); | |
} | |
var songName = process.argv[2]; | |
var fs = require('fs'); | |
// Load song | |
var mySong = []; | |
try { | |
mySong = JSON.parse(fs.readFileSync(songName)); |
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
var midiFileParser = require('midi-file-parser'); | |
var MIDIUtils = require('midiutils'); | |
var song = "hotline_bling" | |
var file = require('fs').readFileSync(song + '.mid', 'binary') | |
var midi = midiFileParser(file); | |
notes = []; | |
noteStatus = false; |
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
@echo off | |
if exist notice.vbs ( | |
rem file exists | |
) else ( | |
( | |
echo Set objArgs = WScript.Arguments | |
echo messageText = objArgs^(0^) | |
echo MsgBox messageText | |
) >notice.vbs | |
) |
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
package com.qualcomm.ftcrobotcontroller.opmodes; | |
import com.qualcomm.robotcore.eventloop.opmode.OpMode; | |
import com.qualcomm.robotcore.hardware.DcMotor; | |
import com.qualcomm.robotcore.hardware.DcMotorController; | |
import com.qualcomm.robotcore.util.ElapsedTime; | |
import com.qualcomm.robotcore.util.Range; | |
import java.text.SimpleDateFormat; | |
import java.util.Date; |
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
// server.js | |
//Run with: node PORT=8081 server.js | |
//Run with ports below 1024 with sudo: node PORT=80 server.js | |
// BASE SETUP | |
// ============================================== | |
var express = require('express'); | |
var app = express(); |