Just shared on bitbucket sources of the "Amoeba control" iPad game.
https://bitbucket.org/vsergeyev/ameba/
Screenshot:
You may use it as a sample how to create muliplayer games with Lua
and Corona SDK for iPad / iPhone / iPod Touch.
This is my free-time work, and I happy to share it with anybody.
Feel free to use and modify it.
I shared a code on bitbucket of iPad game draft - "Bunkers".
https://bitbucket.org/vsergeyev/bunkers/
This is tower-defense style game where player put bunkers on the screen to stop and destroy tanks. Game project is done with Corona SDK. Game is just a draft, or template. You can use it as starting point of your game.

Have fun :)
"15 Puzzle Simple" game for iPhone.
Game is classic 15 puzzle, where you should place buttons from 1 to 15 one after each.
It is really addictive :)


Game is currently on review at App Store.
Today was my "open source" day :)
Rain Lua class to use with Corona SDK is placed on github and you can use it for free.
https://github.com/vsergeyev/Rain
You can find an example app `main.lua` to see how it works.
Basic usage is quite simple:
local rain = require("rain")
rain.new(group, {})
Class constructor accepts several config params:
* angle - rain angle, degrees
* toRight - boolean, if rain is from left to right. Default is from right to left
* speed - drop movement speed, float
* floor - Y coord to specify your ground/bottom
* length - drop length
* width - drop thickness
* alpha - transparency of the drop
* color - drop color, defaulu is white
* count - drops count to create
Demo:
So "Dark Hedgehog strikes back!" is looking more and more usable. Today we added intro and recorded some game sounds.
Game developed with Corona SDK and technically it is "scene" like other game levels. The only main difference is that all events on scene are scripted with timed-triggered handlers. This is how it now looks:
function scene:createScene( event )
...
timer.performWithDelay(3000, zzzZzz, 1 )
timer.performWithDelay(9000, lightOn, 1 )
timer.performWithDelay(15000, thisIsSparta, 1 )
end
To play intro are called three function - display sleep "z-z-z" and play appropriate sound; then turn on light source and finally - display angry "WTF?!" banner. Hedgehog don't expect to be lighted and he prefer darkness. This yourself to be waiked up at 3:00 AM :)
We currently develop an iPhone game aout adventures of Dark Hedgehog with Corona SDK.
It can jump and sometimes jumps out of screen. We decided to move all background stuff
in the bottom direction, while hedgehog will be fixed at top of the screen. Eg., this means we move
ground and sky instead of actor.
To handle situation when actor is going to leave screen, we add an "enterFrame" handler:
Runtime:addEventListener( "enterFrame", frameHandler )
Function checks the Y coordinate of "actor" and if it is less than allowed value, it starts to shift a display "group". Group holds background, ground, sky, etc. Here also one more restriction applied: group can not be shifted down more than half of screen height. This is because in my example, I have a stars sky hidden at the top out of screen. This sky has height half/screen height and shifted together with background. So when actor jumps high gamer will see stars sky appearing at the top. Pretty nice :)
function frameHandler( e )
local maxY = 100
if actor.y < maxY then
if group.y < halfH then
group.y = group.y + maxY - actor.y
end
actor.y = maxY
else
if group.y > 0 then
group.y = group.y - 1
end
end
end
Demo video:
This screencast is about placing bigger overlay over small in-game object and handle tap-touch events with it.
Here is code used in screencast:
local function addPlatform(group, name)
-- platform
local platform1 = display.newImageRect("i/wood.png", 120, 20)
platform1.x, platform1.y = levelData[name.."X"], levelData[name.."Y"]
physics.addBody( platform1, "static", {friction=levelData[name.."F"]} )
platform1.rotation = levelData[name.."R"]
group:insert( platform1 )
-- overlay to track touch events
local p1touch = display.newCircle(platform1.x, platform1.y, 60)
p1touch.alpha = 0.1
p1touch.target = platform1
p1touch:addEventListener('touch', rotateTramplin)
group:insert( p1touch )
end
This is my first screencast in English, so don't beat me to much :)
"Didi go fly" is a game for iPhone/iPad. Player rotate platforms and tramplins to help little chick Didi reach egg. In every level you collect golden eggs and after final level secret egg appear.
Gravitation is your friend, use it to accelerate. Platforms and tramplins behave differently in every level, so watch out. Two tramplins may accelerate Didi up to escape velocity and the only way to get it back will be Restart button.
Game done in "paper" style and action takes place on the sheet of paper. Gravitation helps Didi to speedup, while platforms has different coefficient of friction. Every tramplin has different acceleration and velocity multiplicator. Both platforms and tramplins active from top and bottom sides. Sometimes it is best to rotate it away from Didi trajectory.
Current game version has 15 levels.
Gameplay demo video:

Splunk is great tool for analyzing logs. It has a tool for adding local logs on the remote server.
Universal forwarder is client-side tool. Once you added your log file to it, forwarder will monitor changes
and push it to specified Splunk server(s).
$SPLUNKHOME/splunk start --accept-license
$SPLUNKHOME/splunk enable boot-start
$SPLUNKHOME/splunk add forward-server [SERVER]:9997 -auth [USER]:[PASSWORD]
$SPLUNKHOME/splunk add monitor [LOG_FILE]
In current task we use Splunk Dashboard as alternative to Graphite (http://graphite.wikidot.com).
If you worked with Django, it is obvious to install middleware in project's settings.py. Or maybe it's looks simple for me, as previously I used Django a lot. And with Flask it was not so clear. In fact I was lost with it :)
What I found in Flask documentation: middleware should hook on application. Ok, so let's "install" middleware into our application:
app = Flask(_name__)
...
app.wsgi_app = middleware.LogMiddleware(app.wsgi_app)
Middleware class in middleware.py:
class LogMiddleware(object):
"""WSGI middleware for collecting site usage
"""
def __init__(self, app):
self.app = app
def __call__(self, environ, start_response):
url = environ.get("PATH_INFO", "")
query = unquote_plus(environ.get("QUERY_STRING", "")).
item = logging.LogRecord(
name="Logging",
level=logging.INFO,
pathname=url,
lineno="",
msg=query,
args=None,
exc_info=None
)
metrics_logger.handle(item)
return self.app(environ, start_response)
This middleware logs site access and stores it for further analysis with Splunk.