2017-10-19 21:00:49 -05:00
|
|
|
class Ext_TGroupRegen extends Ext_TGroupBase;
|
|
|
|
|
2021-01-18 00:55:45 +03:00
|
|
|
var localized string GroupDescription;
|
|
|
|
|
|
|
|
function string GetUIInfo(Ext_PerkBase Perk)
|
2017-10-19 21:00:49 -05:00
|
|
|
{
|
2021-01-18 00:55:45 +03:00
|
|
|
return Default.GroupInfo@"("$MaxText@GetMaxLimit(Perk)$")";
|
2017-10-19 21:00:49 -05:00
|
|
|
}
|
2020-11-29 00:54:57 +03:00
|
|
|
|
2021-01-18 00:55:45 +03:00
|
|
|
function string GetUIDesc()
|
2017-10-19 21:00:49 -05:00
|
|
|
{
|
2021-01-18 00:55:45 +03:00
|
|
|
return Super.GetUIDesc()$"|"$GroupDescription;
|
2017-10-19 21:00:49 -05:00
|
|
|
}
|
|
|
|
|
2020-11-28 23:04:55 +03:00
|
|
|
static function bool GroupLimited(Ext_PerkBase Perk, class<Ext_TraitBase> Trait)
|
2017-10-19 21:00:49 -05:00
|
|
|
{
|
|
|
|
local int i;
|
|
|
|
local byte n;
|
|
|
|
|
|
|
|
n = GetMaxLimit(Perk);
|
2020-11-28 23:12:58 +03:00
|
|
|
for (i=0; i<Perk.PerkTraits.Length; ++i)
|
|
|
|
if (Perk.PerkTraits[i].CurrentLevel>0 && Perk.PerkTraits[i].TraitType!=Trait && Perk.PerkTraits[i].TraitType.Default.TraitGroup==Default.Class && --n==0)
|
2017-10-19 21:00:49 -05:00
|
|
|
return true;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2020-11-28 23:04:55 +03:00
|
|
|
static final function byte GetMaxLimit(Ext_PerkBase Perk)
|
2017-10-19 21:00:49 -05:00
|
|
|
{
|
2020-11-28 23:12:58 +03:00
|
|
|
if (Perk.CurrentPrestige<1 || Perk.CurrentLevel<100)
|
2017-10-19 21:00:49 -05:00
|
|
|
return 1;
|
|
|
|
return ((Perk.CurrentPrestige<5 || Perk.CurrentLevel<150) ? 2 : 3);
|
|
|
|
}
|
|
|
|
|
|
|
|
defaultproperties
|
|
|
|
{
|
|
|
|
}
|