This repository has been archived on 2026-04-30. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
Tortuga/rsc/scripts/setup_server.lua
T
Kayne Ruse 5eeda8235d Fixed the scripts struggling with nested API tables
I actually don't remember what the RoomData's lua references where for,
but I'm pretty srue it wasn't this. I'll figure something out when I've
had a sleep.
2014-11-23 06:40:31 +11:00

34 lines
786 B
Lua

print("Lua script check")
mapMaker = require "map_maker"
mapSaver = require "map_saver"
roomSystem = require "room_system"
local function dumpTable(t)
print(t)
for k, v in pairs(t) do
print("",k, v)
end
end
dumpTable(mapMaker)
dumpTable(mapSaver)
dumpTable(roomSystem)
dumpTable(roomSystem.Room)
dumpTable(roomSystem.RoomManager)
--create the overworld, set it's generator, loader & saver
local overworld = roomSystem.RoomManager.CreateRoom("overworld", "overworld.bmp")
roomSystem.Room.SetOnLoad(overworld, 1123)
roomSystem.Room.SetOnUnload(overworld, 458)
if roomSystem.Room.GetOnLoad(overworld) == 1123 then
print("onload retreival works")
end
if roomSystem.Room.GetOnUnload(overworld) == 458 then
print("onunload retreival works")
end
print("Finished the lua script")