Skip to content

Instantly share code, notes, and snippets.

View mteece's full-sized avatar

Matthew Teece mteece

View GitHub Profile
  • To add Settings.bundle in Xcode. Command N and in Resource, choose Settings Bundle .
  • Open Root.plist in source code, paste the code below to replace it,
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>PreferenceSpecifiers</key>
	
@mteece
mteece / RPS.js
Last active December 21, 2015 21:19 — forked from joehinkle/RPS.js
Making game and objects configurable for rock, paper, scissors, lizard, spock. See http://en.wikipedia.org/wiki/Rock-paper-scissors-lizard-Spock.
// Initializing Variables
var userChoice = prompt("Do you choose rock, paper, scissors, lizard, or spock?");
var choices = ["rock", "paper", "scissors", "lizard", "spock"];
var computerChoice = choices[ Math.floor( Math.random() * choices.length ) ];
// Function that compares the two values
function compare( choice1, choice2 ) {
var rock = {
defeats: ["scissors", "lizard"],