Skip to content
Snippets Groups Projects
Commit 0a010a4e authored by dg's avatar dg
Browse files

Added many new room shapes

git-svn-id: http://svn.net-core.org/repos/t-engine4@1693 51575b47-30f0-44d4-a5cc-537603b46e54
parent ce8bf9c0
No related branches found
No related tags found
No related merge requests found
Showing
with 475 additions and 4 deletions
......@@ -37,7 +37,11 @@ function _M:init(data)
end
end
local rooms_cache = {}
function _M:loadRoom(file)
if rooms_cache[file] then return rooms_cache[file] end
local f, err = loadfile("/data/rooms/"..file..".lua")
if not f and err then error(err) end
setfenv(f, setmetatable({
......@@ -49,6 +53,7 @@ function _M:loadRoom(file)
-- We got a room generator function, save it for later
if type(ret) == "function" then
print("loaded room generator",file,ret)
rooms_cache[file] = ret
return ret
end
......@@ -66,6 +71,7 @@ function _M:loadRoom(file)
end
print("loaded room",file,t.w,t.h)
rooms_cache[file] = t
return t
end
......
......@@ -29,7 +29,7 @@ subGenerator{
generator = "engine.generator.map.Roomer",
data = {
nb_rooms = 10,
rooms = {"simple", "pilar"},
rooms = {"random_room"},
['.'] = "FLOOR",
['#'] = "WALL",
up = "UP",
......
......@@ -41,7 +41,7 @@ subGenerator{
generator = "engine.generator.map.Roomer",
data = {
nb_rooms = 7,
rooms = {"simple", "pilar"},
rooms = {"random_room"},
['.'] = "FLOOR",
['#'] = "WALL",
up = "FLOOR",
......
......@@ -27,7 +27,7 @@ subGenerator{
generator = "engine.generator.map.Roomer",
data = {
nb_rooms = 10,
rooms = {"simple", "pilar"},
rooms = {"random_room"},
['.'] = "FLOOR",
['#'] = "WALL",
up = "UP",
......
......@@ -29,7 +29,7 @@ subGenerator{
data = {
edge_entrances = {4,6},
nb_rooms = 13,
rooms = {"simple", "pilar"},
rooms = {"random_room"},
['.'] = "FLOOR",
['#'] = "WALL",
up = "UP_WILDERNESS_FAR_EAST",
......
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!#]],
[[!......!]],
[[###..###]],
[[!.#..#.!]],
[[!......!]],
[[!.#..#.!]],
[[###..###]],
[[!......!]],
[[#!!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!!!!!!#]],
[[!...........!]],
[[!...........!]],
[[!.#########.!]],
[[!.#...#...#.!]],
[[!.##.###.##.!]],
[[!...........!]],
[[!.##.###.##.!]],
[[!.#...#...#.!]],
[[!.#########.!]],
[[!...........!]],
[[!...........!]],
[[#!!!!!!!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!!!!!#]],
[[!..........!]],
[[!.#.#..#.#.!]],
[[!.#.#..#.#.!]],
[[!.###..###.!]],
[[!..........!]],
[[!.###..###.!]],
[[!.#.#..#.#.!]],
[[!.#.#..#.#.!]],
[[!..........!]],
[[#!!!!!!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!#!!!!#!#]],
[[!.#....#.!]],
[[!........!]],
[[####..####]],
[[####..####]],
[[!........!]],
[[!.#....#.!]],
[[#!#!!!!#!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!#!#!#!#]],
[[!.#.#.#.!]],
[[!.#.#.#.!]],
[[!.......!]],
[[###...###]],
[[###...###]],
[[!.......!]],
[[!.#.#.#.!]],
[[!.#.#.#.!]],
[[#!#!#!#!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!#]],
[[##..##]],
[[!....!]],
[[##..##]],
[[!....!]],
[[##..##]],
[[!....!]],
[[##..##]],
[[!....!]],
[[##..##]],
[[!....!]],
[[##..##]],
[[#!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!#]],
[[!.....!]],
[[##.#.##]],
[[!.#.#.!]],
[[!.....!]],
[[!.....!]],
[[!.#.#.!]],
[[##.#.##]],
[[!.....!]],
[[#!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!#]],
[[!.....!]],
[[!.###.!]],
[[!.#.#.!]],
[[!.....!]],
[[!.#.#.!]],
[[!.###.!]],
[[!.....!]],
[[#!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!#!!#]],
[[!..#..!]],
[[##...##]],
[[!.....!]],
[[##...##]],
[[!..#..!]],
[[#!!#!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!!!!#]],
[[!.........!]],
[[!.........!]],
[[!..##.##..!]],
[[!...###...!]],
[[!.#.....#.!]],
[[!.##...##.!]],
[[!..#...#..!]],
[[!.##...##.!]],
[[!.#.....#.!]],
[[!...###...!]],
[[!..##.##..!]],
[[!.........!]],
[[!.........!]],
[[#!!!!!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[###!!!!###]],
[[###....###]],
[[###....###]],
[[###....###]],
[[###....###]],
[[!........!]],
[[!........!]],
[[!........!]],
[[!........!]],
[[###....###]],
[[###....###]],
[[###....###]],
[[###....###]],
[[###!!!!###]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!#####!!#]],
[[!..#####..!]],
[[!...###...!]],
[[!.........!]],
[[!...###...!]],
[[!..#####..!]],
[[#!!#####!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!!#]],
[[!.......!]],
[[!.#####.!]],
[[!.......!]],
[[!.#####.!]],
[[!.......!]],
[[#!!!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!!#]],
[[!.......!]],
[[!.......!]],
[[###...###]],
[[!.......!]],
[[!.......!]],
[[###...###]],
[[!.......!]],
[[!.......!]],
[[#!!!!!!!#]],
}
\ No newline at end of file
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return {
[[#!!!!!!!!!#]],
[[!.........!]],
[[!.#######.!]],
[[!....#....!]],
[[!.#######.!]],
[[!.........!]],
[[#!!!!!!!!!#]],
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment