The popular open-source contract for web professionals by Stuff & Nonsense
- Originally published: 23rd December 2008
- Revised date: March 15th 2016
- Original post
| var map = ds_map_create(); | |
| ds_map_add(map, "Content-Type", "application/json"); | |
| var date = string(current_day); | |
| var data = '{"IMEI": 0, "Package":"com.saltgaming.hero_of_the_north", "date":'+ date+ '}' | |
| global.check_usage = http_request("http://46.38.168.148:3452/emts/game/requsage","POST", map, json_encode(data)); |
| local lpeg = require 'lpeg' | |
| local L = lpeg.locale() | |
| local P,V,C,Ct,S,R,Cg,Cc = | |
| lpeg.P, lpeg.V, lpeg.C, lpeg.Ct, lpeg.S, lpeg.R, lpeg.Cg, lpeg.Cc | |
| local ws = S'\r\n\f\t\v ' | |
| local ws0 = ws^0 | |
| local ws1 = ws^1 | |
| local name = S'_ ' + L.digit + L.alpha |
| render_tags= (fn)-> | |
| setfenv fn, setmetatable({}, { | |
| __index:(tag_name)=> | |
| print tag_name | |
| (opts)-> | |
| build_tag(tag_name, opts) | |
| }) | |
| fn! |
| local player = {} --the player object | |
| function love.load() | |
| player.x = 300 | |
| player.y = 400 | |
| end | |
| function love.update(dt) |
| function love.load() | |
| myfont = love.graphics.newFont(45) | |
| love.graphics.setFont(myfont) | |
| love.graphics.setColor(0, 0, 0, 225) | |
| love.graphics.setBackgroundColor(225, 153, 0) | |
| end | |
| function love.update() | |
| --we are not doing anything here yet :) | |
| end | |
| function love.draw() |
| function love.load() | |
| --load | |
| end | |
| function love.update(dt) | |
| -- maths | |
| end | |
| function love.draw() | |
| --draw | |
| end |
| function instanceOf (subject, super) | |
| super = tostring(super) | |
| local mt = getmetatable(subject) | |
| while true do | |
| if mt == nil then return false end | |
| if tostring(mt) == super then return true end | |
| mt = getmetatable(mt) |
| <link rel="import" href="../google-map/google-map.html"> | |
| <polymer-element name="my-element"> | |
| <template> | |
| <style> | |
| :host { | |
| position: absolute; | |
| width: 100%; | |
| height: 100%; |
| <link rel="import" href="../topeka-elements/theme.html"> | |
| <link rel="import" href="../topeka-elements/topeka-resources.html"> | |
| <link rel="import" href="../topeka-elements/topeka-app.html"> | |
| <polymer-element name="my-element"> | |
| <template> | |
| <style> | |
| :host { | |
| position: absolute; |