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 <iostream> | |
#include <string> | |
#include <regex> | |
#include <vector> | |
#include <sstream> | |
using namespace std; | |
bool ci_compare (char a, char b) {return tolower(a)<tolower(b);} |
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
init = function(this) | |
this.minimap = {} | |
this.tiles = {} | |
local limit = 32 | |
for x = 1, limit do this.tiles[x] = {} end | |
local snap=function(point)return{flr(point[1]/2)*2+1,flr(point[2]/2)*2+1}end | |
local new_room = function() | |
local dim = snap({rnd(6)+3, rnd(6)+3}) | |
dim[1]-=1 dim[2]-=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
while sleep 1 | |
do adb shell input swipe 50 400 1000 400 | |
done |
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
Sun Feb 4 22:06:55 2018 -- Compiling... | |
Requiring ichor.lua from games/picowars/picowars.p8 | |
Requiring camera from games/picowars/picowars.p8 | |
Requiring war.lua from games/picowars/picowars.p8 | |
Requiring player from /home/caaz/.lexaloffle/pico-8/carts/games/picowars/war.lua | |
Requiring class.lua from /home/caaz/.lexaloffle/pico-8/carts/games/picowars/player.lua | |
Requiring world_ui from /home/caaz/.lexaloffle/pico-8/carts/games/picowars/player.lua | |
Requiring table/merge from /home/caaz/.lexaloffle/pico-8/carts/lib/world_ui.lua | |
Requiring map from /home/caaz/.lexaloffle/pico-8/carts/games/picowars/war.lua |
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
const HID = require('node-hid') | |
const Bitfield = require("bitfield") | |
const SimpleADB = require('simple-adb').SimpleADB; | |
require('log-timestamp') | |
const sadb = new SimpleADB(); | |
const devices = HID.devices() | |
const device = new HID.HID(devices[0].path) | |
const names = ['zr','zl','r','l','x','a','b','y','null','null','record','home','cr','cl','plus','minus'] | |
const keymap = { |
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 answers = { | |
isk(arr) { | |
let vowels = 0; | |
for (e of arr) { | |
if (e.constructor === Array) vowels += answers.isk(e) | |
else { | |
let m = e.match(/[aeiou]/gi); | |
vowels += m === null ? 0 : m.length; | |
} |
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 partials/class.lua | |
-- require picowars/tile.lua | |
-- require partials/binary.lua | |
local maps = { | |
-- require logs/picowars_map.p8l | |
} | |
class.map = class{ | |
new = function(this) | |
merge(this, { | |
tick = 0, |
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 partials/class.lua | |
class.polygon = class{ | |
new = function(this,args) | |
merge(this,{ | |
points = {}, | |
lines = {} | |
}) | |
merge(this,args) | |
this:rasterize() | |
end, |
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
#!/usr/bin/perl | |
use warnings; | |
use strict; | |
use v5.10; | |
no warnings 'experimental::smartmatch'; | |
die("No argument provided for file\n") unless($ARGV[0]); | |
die("No file at $ARGV[0]\n") unless(-e $ARGV[0]); | |
unless($ARGV[1]) { | |
my $cart_name = $ARGV[0]; |
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 java.util.Scanner; | |
public class Start { | |
public static void main(String[] args) { | |
Hangman game = new Hangman("Hello"); | |
System.out.println("Welcome to Hangman. Make sure to guess letters."); | |
while (!game.isCompleted()) { | |
System.out.println(game); | |
game.getInput(); | |
} |