From de19ba41263673e953e09738f46d399592223e8c Mon Sep 17 00:00:00 2001
From: DarkGod <darkgod@net-core.org>
Date: Wed, 24 Dec 2014 00:06:36 +0100
Subject: [PATCH] New race: the Ogres New lore for the ogres New zone to unlock
 the ogres

---
 .../data/zones/conclave-vault/rooms/room5.lua |  2 +-
 .../data/zones/conclave-vault/rooms/room6.lua | 52 +++++++++++++++++++
 .../tome/data/zones/conclave-vault/zone.lua   |  2 +-
 3 files changed, 54 insertions(+), 2 deletions(-)
 create mode 100644 game/modules/tome/data/zones/conclave-vault/rooms/room6.lua

diff --git a/game/modules/tome/data/zones/conclave-vault/rooms/room5.lua b/game/modules/tome/data/zones/conclave-vault/rooms/room5.lua
index 77a2905de3..cb3cc48a8c 100644
--- a/game/modules/tome/data/zones/conclave-vault/rooms/room5.lua
+++ b/game/modules/tome/data/zones/conclave-vault/rooms/room5.lua
@@ -44,7 +44,7 @@ return function(gen, id)
 		end
 		for _, spot in ipairs(room.spots[2]) do
 			game.level.map(x + spot.x, y + spot.y, gen.map.TRIGGER, engine.Entity.new{ on_move = function(self, x, y, who) if who and game.zone.awaken_ogres then
-				game.zone.awaken_ogres(who, x, y, 8)
+				game.zone.awaken_ogres(who, x, y, 8, {8, 12})
 			end end})
 		end
 	end}
diff --git a/game/modules/tome/data/zones/conclave-vault/rooms/room6.lua b/game/modules/tome/data/zones/conclave-vault/rooms/room6.lua
new file mode 100644
index 0000000000..6df594bde3
--- /dev/null
+++ b/game/modules/tome/data/zones/conclave-vault/rooms/room6.lua
@@ -0,0 +1,52 @@
+-- ToME - Tales of Maj'Eyal
+-- Copyright (C) 2009 - 2014 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
+
+local def = { numbers = '.',
+[[#!!!!!!!!!!!#]],
+[[!...........!]],
+[[!...........!]],
+[[!.####.####.!]],
+[[!....#.#11#.!]],
+[[!.#..###11#.!]],
+[[###2222222###]],
+[[!.#11###..#.!]],
+[[!.#11#.#....!]],
+[[!.####.####.!]],
+[[!...........!]],
+[[!...........!]],
+[[#!!!!!!!!!!!#]],
+}
+
+return function(gen, id)
+	local room = gen:roomParse(def)
+	return { name="conclave-ogre-2"..room.w.."x"..room.h, w=room.w, h=room.h, generator = function(self, x, y, is_lit)
+
+		gen:roomFrom(id, x, y, is_lit, room)
+
+		for _, spot in ipairs(room.spots[1]) do
+			local e = gen.zone:makeEntity(gen.level, "actor", {type="giant", subtype="ogre"}, nil, true)
+			if e then gen:roomMapAddEntity(x + spot.x, y + spot.y, "actor", e) gen.map.room_map[x + spot.x][y + spot.y].special = true end
+		end
+		for _, spot in ipairs(room.spots[2]) do
+			game.level.map(x + spot.x, y + spot.y, gen.map.TRIGGER, engine.Entity.new{ on_move = function(self, x, y, who) if who and game.zone.awaken_ogres then
+				game.zone.awaken_ogres(who, x, y, 8, {2, 3})
+			end end})
+		end
+	end}
+end
diff --git a/game/modules/tome/data/zones/conclave-vault/zone.lua b/game/modules/tome/data/zones/conclave-vault/zone.lua
index b95ab065c4..d66696a1e9 100644
--- a/game/modules/tome/data/zones/conclave-vault/zone.lua
+++ b/game/modules/tome/data/zones/conclave-vault/zone.lua
@@ -35,7 +35,7 @@ return {
 		map = {
 			class = "engine.generator.map.Roomer",
 			nb_rooms = 10,
-			rooms = {"!room1", "!room2", {"!room3", 3}, "small_x", "!room4", "!room5"},
+			rooms = {"!room1", "!room2", {"!room3", 3}, "small_x", "!room4", "!room5", "!room6"},
 			lite_room_chance = 100,
 			['.'] = "FLOOR",
 			['#'] = "WALL",
-- 
GitLab