generated from polaritynord/polarity-engine
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconf.lua
More file actions
39 lines (35 loc) · 1.1 KB
/
conf.lua
File metadata and controls
39 lines (35 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
ENGINE_COMPONENT_NAMES = {
"imageComponent", "transformComponent", "particleComponent", "UIComponent"
}
ENGINE_COMPONENTS = {
imageComponent = require "engine.components.image_component";
UIComponent = require "engine.components.ui_component";
particleComponent = require("engine.components.particle_component");
scriptComponent = require("engine.components.script_component");
}
function table.contains(table, element, returnIndex)
for i, value in pairs(table) do
if value == element then
if returnIndex then
return i
else
return true
end
end
end
return false
end
function table.reverse(tab)
for i = 1, math.ceil(#tab/2), 1 do
tab[i], tab[#tab-i+1] = tab[#tab-i+1], tab[i]
end
return tab
end
function love.conf(t)
t.window.width = 960 ; t.window.height = 540
t.window.title = "DESOLATION Map Editor"
if table.contains(arg, "--no-vsync") then t.window.vsync = 0 end
t.window.icon = "engine/assets/icon.png"
t.console = true
ScreenWidth, ScreenHeight = t.window.width, t.window.height
end