canoi12 / poti

Lua game framework with a tiny C core

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

poti

Lua game framework with a tiny C core

function poti.load()
  tex = poti.graphics.load_texture("image.png", "static")
  canvas = poti.graphics.new_texture(160, 95, "target")
  dest = {0, 0, 160*4, 95*4}
end

function poti.draw()
  poti.graphics.set_target(canvas)
  poti.graphics.clear()
  tex:draw()
  poti.graphics.set_target()
  
  canvas:draw(nil, dest)
end

About

Lua game framework with a tiny C core

License:MIT License


Languages

Language:C 96.3%Language:Lua 2.0%Language:CMake 0.7%Language:Makefile 0.6%Language:HTML 0.3%Language:Shell 0.0%