-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmain.lua
More file actions
53 lines (40 loc) · 1.06 KB
/
Copy pathmain.lua
File metadata and controls
53 lines (40 loc) · 1.06 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
config = require("config")
require "lib/SECS"
require "lib/utils"
require "lib/simplegui"
require "lib/statemgr"
require "lib/inputmgr"
require "lib/soundmgr"
require "lib/storagemgr"
require "lib/assetloader"
require "lib/directions"
require "lib/platforms"
GAME_VERSION = "0.2.0"
function main()
print("Pellet Stealth "..GAME_VERSION.." starting...")
storagemgr.init("pelletstealth")
local _storage=storagemgr.get("_settings")
if _storage.data then
if _storage.data.landscape~=nil then
config.landscape = _storage.data.landscape
if config.forcelandscape~=nil then
config.landscape = config.forcelandscape
end
end
end
utils.init_screen("Pellet Stealth",config,640,960)
soundmgr.init(nil,16,44100,512,1)
if _storage.data then
if _storage.data.globalvolume then
soundmgr.setGlobalVolume(_storage.data.globalvolume)
end
end
-- seed random numbers
math.randomseed ( os.time ())
globalData = {}
JUMP_TO = nil
statemgr.push ( JUMP_TO or "intro" )
-- Start the game!
statemgr.begin ()
end
main()