diff --git a/game/engines/default/engine/Entity.lua b/game/engines/default/engine/Entity.lua index 00c2df329c91014cbe9db6561536c320c600da8e..d3413cf6325a96ea952f84337824aff3af63e1ed 100644 --- a/game/engines/default/engine/Entity.lua +++ b/game/engines/default/engine/Entity.lua @@ -834,6 +834,7 @@ function _M:loadList(file, no_default, res, mod, loaded) if err then error(err) end loaded = loaded or {} + if res.ignore_loaded and loaded[file] then return res end loaded[file] = true local newenv newenv = { @@ -869,8 +870,8 @@ function _M:loadList(file, no_default, res, mod, loaded) load = function(f, new_mod) self:loadList(f, no_default, res, new_mod or mod, loaded) end, - loadList = function(f, new_mod) - return self:loadList(f, no_default, nil, new_mod or mod, nil) + loadList = function(f, new_mod, list, loaded) + return self:loadList(f, no_default, list, new_mod or mod, loaded) end, } setfenv(f, setmetatable(newenv, {__index=_G})) diff --git a/game/engines/default/engine/interface/WorldAchievements.lua b/game/engines/default/engine/interface/WorldAchievements.lua index 2c870ff3cd3ab86cac64afe6f24f63e07eeb8006..ef6f86c9fadb0ded207c849b6bf8fe29fb4ebbdc 100644 --- a/game/engines/default/engine/interface/WorldAchievements.lua +++ b/game/engines/default/engine/interface/WorldAchievements.lua @@ -104,6 +104,7 @@ end -- @return true if an achievement was gained function _M:gainAchievement(id, src, ...) local a = self.achiev_defs[id] + print("=============== ach", id, a) if not a then error("Unknown achievement "..id) return end if self.achieved[id] and src.achievements and src.achievements[id] then return end diff --git a/game/modules/tome/data/talents/gifts/mindstar-mastery.lua b/game/modules/tome/data/talents/gifts/mindstar-mastery.lua index 59c4bb26c1b7a4794ddda260f040a0e09a5bf825..6ebabdda1349716de637a3cfe06220a967df72b8 100644 --- a/game/modules/tome/data/talents/gifts/mindstar-mastery.lua +++ b/game/modules/tome/data/talents/gifts/mindstar-mastery.lua @@ -60,9 +60,9 @@ newTalent{ local damage = t.getDamage(self, t) local inc = t.getPercentInc(self, t) return ([[Channel your mental power through your wielded mindstars, generating psionic blades sprouting from the mindstars. - Mindstar psiblades have their damage modifiers (how much damage they gain from stats) increased to %d%% and their armour penetration by %d%%. + Mindstar psiblades have their damage modifiers (how much damage they gain from stats) multiplied by %0.2f and their armour penetration by %0.2f. Also increases Physical Power by %d and increases weapon damage by %d%% when using mindstars.]]): - format(100 * (1.3 + self:getTalentLevel(t) / 10), 100 * (1 + self:getTalentLevel(t) / 6.3), damage, 100 * inc) + format(1 * (1.3 + self:getTalentLevel(t) / 10), 1 * (1 + self:getTalentLevel(t) / 6.3), damage, 100 * inc) end, } diff --git a/game/modules/tome/data/zones/infinite-dungeon/zone.lua b/game/modules/tome/data/zones/infinite-dungeon/zone.lua index 1391fc13177fca5e0a600b459df11ff45d8ed815..0bc53cb1d0b2ed41c1a6a06be2f34f2aae54f082 100644 --- a/game/modules/tome/data/zones/infinite-dungeon/zone.lua +++ b/game/modules/tome/data/zones/infinite-dungeon/zone.lua @@ -66,21 +66,6 @@ return { }, }, post_process = function(level) - -- Everything hates you in the infinite dungeon! - for uid, e in pairs(level.entities) do e.faction = e.hard_faction or "enemies" end - - -- Some lore - if level.level == 1 or level.level == 10 or level.level == 20 or level.level == 30 or level.level == 40 then - local l = game.zone:makeEntityByName(level, "terrain", "ID_HISTORY"..level.level) - if not l then return end - for _, coord in pairs(util.adjacentCoords(level.default_up.x, level.default_up.y)) do - if game.level.map:isBound(coord[1], coord[2]) and (i ~= 0 or j ~= 0) and not game.level.map:checkEntity(coord[1], coord[2], engine.Map.TERRAIN, "block_move") then - game.zone:addEntity(level, l, "terrain", coord[1], coord[2]) - return - end - end - end - -- Provide some achievements if level.level == 10 then world:gainAchievement("INFINITE_X10", game.player) elseif level.level == 20 then world:gainAchievement("INFINITE_X20", game.player) @@ -98,5 +83,20 @@ return { elseif level.level == 400 then world:gainAchievement("INFINITE_X400", game.player) elseif level.level == 500 then world:gainAchievement("INFINITE_X500", game.player) end + + -- Everything hates you in the infinite dungeon! + for uid, e in pairs(level.entities) do e.faction = e.hard_faction or "enemies" end + + -- Some lore + if level.level == 1 or level.level == 10 or level.level == 20 or level.level == 30 or level.level == 40 then + local l = game.zone:makeEntityByName(level, "terrain", "ID_HISTORY"..level.level) + if not l then return end + for _, coord in pairs(util.adjacentCoords(level.default_up.x, level.default_up.y)) do + if game.level.map:isBound(coord[1], coord[2]) and (i ~= 0 or j ~= 0) and not game.level.map:checkEntity(coord[1], coord[2], engine.Map.TERRAIN, "block_move") then + game.zone:addEntity(level, l, "terrain", coord[1], coord[2]) + return + end + end + end end, }