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
-- Accelometer Shake | |
supportedOrientations(LANDSCAPE_RIGHT) | |
function setup() | |
print("Shake a few times until the rect() exceeds the ellipse().") | |
end | |
local function deviceShaking() | |
local acceleration = UserAcceleration |
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
--# Main | |
-------------------------------------------------------------- NAMESPACES | |
local Touches = {} | |
local Frames = {} | |
local CurrentFrame = 0 | |
local Action = {} | |
local Actions, CurrentAction = {} |
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
--# Color | |
-- modified version from https://github.com/EmmanuelOga/columns/blob/master/utils/color.lua | |
--[[ | |
* Converts an RGB color value to HSL. Conversion formula | |
* adapted from http://en.wikipedia.org/wiki/HSL_color_space. | |
* Assumes r, g, and b are contained in the set [0, 255] and | |
* returns h, s, and l in the set [0, 1]. | |
* | |
* @param Number r The red color value |
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
--# Hook | |
local s_setup | |
debug.sethook(function(event) | |
if setup and setup ~= s_setup then | |
local o_setup = setup | |
setup = function() | |
debug.sethook() | |
if hook then hook() end | |
o_setup() | |
end |
NewerOlder