Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Mouse] Read mouse arguments out of Args table
Fix flamendless#20. Related to flamendless#80. The function arg to customize screen to slab coordinates isn't passed from Slab.Initialize -- it only passes the input table. Usage with push.lua: function love.load(args) local function get_push_mouse(x,y) local new_x,new_y = push:toGame(x,y) if new_x and new_y then return new_x,new_y end return x,y end local game_width, game_height, window_width, window_height = 320, 240, 1280, 720 push:setupScreen(game_width, game_height, window_width, window_height) args.TransformPointToSlab = get_push_mouse Slab.Initialize(args) end function love.draw() push:start() Slab.Draw() push:finish() end
- Loading branch information