From 9fcb1be05deb6f951f39ddc3ec2ae91337dc4f0a Mon Sep 17 00:00:00 2001
From: DarkGod <darkgod@net-core.org>
Date: Fri, 19 Jun 2020 19:06:25 +0200
Subject: [PATCH] plop

---
 .../engines/default/engine/generator/map/Static.lua |  3 +++
 game/modules/tome/class/GameState.lua               |  2 +-
 game/modules/tome/resolvers.lua                     | 13 +++++++++++++
 3 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/game/engines/default/engine/generator/map/Static.lua b/game/engines/default/engine/generator/map/Static.lua
index 466eca5856..b664a80eae 100644
--- a/game/engines/default/engine/generator/map/Static.lua
+++ b/game/engines/default/engine/generator/map/Static.lua
@@ -262,6 +262,9 @@ function _M:tmxLoad(file)
 	if mapprops.lua then
 		self:loadLuaInEnv(g, nil, "return "..mapprops.lua)
 	end
+	if mapprops.lua_exec then
+		self:loadLuaInEnv(g, nil, mapprops.lua_exec)
+	end
 
 	-- copy certain variables from the map file
 	if mapprops.roomcheck then
diff --git a/game/modules/tome/class/GameState.lua b/game/modules/tome/class/GameState.lua
index 8de9152026..985dc0a104 100644
--- a/game/modules/tome/class/GameState.lua
+++ b/game/modules/tome/class/GameState.lua
@@ -836,7 +836,7 @@ function _M:spawnWorldAmbush(enc, dx, dy, kind)
 		},
 
 		reload_lists = false,
-		npc_list = mod.class.NPC:loadList("/data/general/npcs/all.lua", nil, nil, 
+		npc_list = mod.class.NPC:loadList(enc.npc_list or "/data/general/npcs/all.lua", nil, nil, 
 			function(e) 
 				e.make_escort=nil
 				e.instakill_immune = 1
diff --git a/game/modules/tome/resolvers.lua b/game/modules/tome/resolvers.lua
index 10b73fe85c..e74379336e 100644
--- a/game/modules/tome/resolvers.lua
+++ b/game/modules/tome/resolvers.lua
@@ -1201,6 +1201,14 @@ local racials_visuals = {
 			{kind="facial_features", percent=20, filter={"findname", "Dark Beard "}},
 			{kind="facial_features", percent=20, filter={"findname", "Dark Mustache "}},
 		},
+		Sholtar = {
+			{kind="skin", filter={"oneof", {"Skin Color 6", "Skin Color 7", "Skin Color 8"}}},
+			{kind="skin", percent=5, filter={"oneof", {"Skin Color 1", "Skin Color 2", "Skin Color 3", "Skin Color 4", "Skin Color 5"}}},
+			{kind="hairs", filter={"findname", "Dark Hair"}},
+			{kind="hairs", percent=10, filter={"findname", "Redhead "}},
+			{kind="facial_features", percent=20, filter={"findname", "Dark Beard "}},
+			{kind="facial_features", percent=20, filter={"findname", "Dark Mustache "}},
+		},
 		Higher = {
 			{kind="skin", filter={"oneof", {"Skin Color 1", "Skin Color 2", "Skin Color 3", "Skin Color 4", "Skin Color 5"}}},
 			{kind="skin", percent=5, filter={"oneof", {"Skin Color 6", "Skin Color 7", "Skin Color 8"}}},
@@ -1229,6 +1237,11 @@ local racials_visuals = {
 			{kind="skin", percent=5, filter={"oneof", {"Skin Color 5", "Skin Color 6"}}},
 			{kind="hairs", filter={"all"}},
 		},
+		DarkSkinHalfling = {
+			{kind="skin", filter={"oneof", {"Skin Color 5", "Skin Color 6"}}},
+			{kind="skin", percent=5, filter={"oneof", {"Skin Color 1", "Skin Color 2", "Skin Color 3", "Skin Color 4"}}},
+			{kind="hairs", filter={"all"}},
+		},
 	},
 	Dwarf = {
 		Dwarf = {
-- 
GitLab