blob: 3e4e09a7394700ae3929100bef4e9ad86bf31fc6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
-- Global state
win = require("window")
hc = require("party.hardoncollider.init")
ecs = require("ecs")
--Use a collider to decide what to render
x = {
world_e: ecs.Entity(1)
-- local offsets from the world
world_x: 0
world_y: 0
-- Have we selected an input type yet?
controller_selected: false
-- Level information
level: {
graphics:{}
entities:{}
graphic_world: hc.new(5)
}
}
x.level.collider = x.level.graphic_world\rectangle(0,0,1,1/win.width)
x
|