Skip to content
Snippets Groups Projects
Commit 45097e1f authored by DarkGod's avatar DarkGod
Browse files

nevermind

parent b31d4b94
No related branches found
No related tags found
No related merge requests found
Pipeline #
......@@ -361,6 +361,12 @@ end
function _M:runStop() end
function _M:restStop() end
function _M:hasDescriptor(kind, value)
if not self.descriptor then return false end
if self.descriptor[kind] ~= value then return false end
return true
end
function _M:getSpeed(speed_type)
if type(speed_type) == "number" then return speed_type end
......
......@@ -59,7 +59,7 @@ newBirthDescriptor{
starting_zone = "blighted-ruins",
starting_level = 3, starting_level_force_down = true,
starting_quest = "start-undead",
undead = 1,
undead = 1, true_undead = 1,
forbid_nature = 1,
inscription_forbids = { ["inscriptions/infusions"] = true },
resolvers.inscription("RUNE:_SHIELDING", {cooldown=14, dur=5, power=130}, 1),
......
......@@ -49,6 +49,7 @@ Talents.newTalent = function(self, t)
if tt.is_nature then t.is_nature = true end
if tt.is_antimagic then t.is_antimagic = true end
if tt.is_unarmed then t.is_unarmed = true end
if tt.is_necromancy then t.is_necromancy = true end
if tt.autolearn_mindslayer then t.autolearn_mindslayer = true end
if tt.speed and not t.speed then t.speed = tt.speed end
if t.tactical then t.tactical = Talents.aiLowerTacticals(t.tactical) end
......@@ -65,6 +66,10 @@ Talents.newTalent = function(self, t)
t.short_name = (t.short_name or t.name):upper():gsub("[ ']", "_")
t.name = "#LIGHT_STEEL_BLUE#"..t.name.." (Class Evolution)"
end
if t.is_race_evolution then
t.short_name = (t.short_name or t.name):upper():gsub("[ ']", "_")
t.name = "#SANDY_BROWN#"..t.name.." (Race Evolution)"
end
return oldNewTalent(self, t)
end
......@@ -100,6 +105,7 @@ Talents.is_a_type = {
is_nature = "a nature gift",
is_antimagic = "an antimagic ability",
is_summon = "a summon power",
is_necromancy = "necromancy",
use_only_arcane = "usable during Aether Avatar",
}
......
......@@ -60,13 +60,13 @@ newTalentType{ type="golem/golem", name = "golem", description = "Golem basic ca
newTalentType{ type="golem/drolem", name = "drolem", description = "Drolem basic capacity." }
-- Necromancer spells
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/necrotic-minions", name = "necrotic minions", description = "Create and empower dumb undead minions." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/advanced-necrotic-minions", name = "advanced necrotic minions", min_lev = 10, description = "Create and empower powerful undead minions." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/nightfall", name = "nightfall", description = "Manipulate darkness itself to slaughter your foes." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/shades", name = "shades", min_lev = 10, description = "Invoke and control shades." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/necrosis", name = "necrosis", description = "Gain control over death, eventually turning into a lich." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/grave", name = "grave", description = "Use the rotting cold doom of the tomb to fell your foes." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, mana_regen=true, type="spell/animus", name = "animus", description = "Crush the souls of your foes to improve yourself." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/necrotic-minions", name = "necrotic minions", description = "Create and empower dumb undead minions." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/advanced-necrotic-minions", name = "advanced necrotic minions", min_lev = 10, description = "Create and empower powerful undead minions." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/nightfall", name = "nightfall", description = "Manipulate darkness itself to slaughter your foes." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/shades", name = "shades", min_lev = 10, description = "Invoke and control shades." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/necrosis", name = "necrosis", description = "Gain control over death, eventually turning into a lich." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/grave", name = "grave", description = "Use the rotting cold doom of the tomb to fell your foes." }
newTalentType{ allow_random=true, no_silence=true, is_necromancy=true, is_spell=true, mana_regen=true, type="spell/animus", name = "animus", description = "Crush the souls of your foes to improve yourself." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, type="spell/eldritch-shield", name = "eldritch shield", description = "Infuse arcane forces into your shield." }
newTalentType{ allow_random=true, no_silence=true, is_spell=true, type="spell/eldritch-stone", name = "eldritch stone", description = "Summon stony spikes imbued with various powers." }
......
......@@ -73,7 +73,6 @@ function _M:ignoreUnlocks()
end
function _M:generateList()
-- Makes up the list
local max = 0
local cols = {}
......@@ -81,7 +80,16 @@ function _M:generateList()
for tid, t in pairs(self.actor.talents_def) do
if t.uber and not t.not_listed then
if
(not t.is_class_evolution or (self.actor.descriptor and self.actor.descriptor.subclass == t.is_class_evolution)) and
(
not t.is_class_evolution or
((type(t.is_class_evolution) == "string" and self.actor:hasDescriptor("subclass", t.is_class_evolution))) or
((type(t.is_class_evolution) == "function" and t.is_class_evolution(self.actor, t)))
) and
(
not t.is_race_evolution or
((type(t.is_race_evolution) == "string" and self.actor:hasDescriptor("subrace", t.is_race_evolution))) or
((type(t.is_race_evolution) == "function" and t.is_race_evolution(self.actor, t)))
) and
(not t.requires_unlock or profile.mod.allow_build[t.requires_unlock] or self:ignoreUnlocks())
then
cols[t.type[1]] = cols[t.type[1]] or {}
......@@ -97,6 +105,8 @@ function _M:generateList()
table.sort(cols[s], function(a,b)
if a.is_class_evolution ~= b.is_class_evolution then
return b.is_class_evolution and true or false
elseif a.is_race_evolution ~= b.is_race_evolution then
return b.is_race_evolution and true or false
else
return a.name < b.name
end
......
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