unit type change and ability acquisition, by level up

Hi,

 

Is it possible to change a unit into another upon reaching a certain level. I'm thinking of the young elemental from Resoln, they could upon reaching a given level change to the (not so young) elemental. Is it possible?

Also is it possible to add a new ability at a certain level? For example a poison spit at level 10 for a spider, whatever... ??

 

thanks

5,355 views 9 replies
Reply #1 Top

1 no

2 yes, just prereq the unitstat in the spelldef

Reply #2 Top

thanks. Always appreciated how helpful you are HF. 

Reply #3 Top

You could make the unit have a spell upon reaching a certain level. That spell would summon the new unit and sacrafice the old one. For instance make a summon grave elemental to a young grave elemental at level 10 and in the spell use the same effect as the spell where you sacrafice a hero to give the sov his ability

Reply #4 Top

I actually thought about this solution, but that's too much mess, because you would then eat on the summon limit that is calculated for each shrine. Actually you would have to duplicate the Grave Elemental as a separate entity and have this entity the one summoned from the Young One, so that the 'standard' Grave Elemental limit is not altered.

 

Reply #5 Top

Does anyone know of any working examples of #2 above (unlocking a spell for a unit upon level X for a unit)?

I tried this with disappointing results.  I added a prereq level to a spell using this in SpellDef:

<Prereq>
   <Type>UnitStat_Level</Type>
   <Attribute>2</Attribute>
</Prereq>

Then attached the spell to a unit using a GameModifier like this:

<GameModifier>
   <ModType>Unit</ModType>
   <Attribute>UnlockCombatAbility</Attribute>
   <StrVal>My_Spell</StrVal>
   <Provides>Stuff</Provides>
</GameModifier>

I found that the ability still shows up on the Units dialog for a Level 1 unit.  And in tactical combat you can activate the ability, but it just has no effect (the unit waved it's arms like it was casting the spell but there was no particles or anything else).  So doesn't seem to work too well... unless anyone has suggestions on a better way to set it up?

 

 

Reply #6 Top

    <Prereq>
      <Type>UnitStat</Type>
      <Attribute>UnitStat_Level</Attribute>
      <Value>8</Value>
    </Prereq>

Reply #7 Top

OK so i'm still working on this, what I have found so far is that the unit level prereq works fine for Spells that a champion would use, i.e. so something that appears under the "Spells" action in tactical.  So for example if you add that UnitStat_Level restriction to say fireball, your champs can't use fireball until they reach level X.  The spell doesn't show up in their spell list until they reach the required level.  That's cool and pretty much expected behavior.

The thing i'm trying to do (and I think what the OP was after), was to unlock an Ability (AbilityBonusOption) at a certain level.... and the Ability could be anything, i.e. passive, a spell etc.  The key here being that the ability might not be something that grants a SpellDef.  For example, say at level 5 we want the "Unit_BoundHarridan" to start to regenerate (Regeneration1).  I tried added theUnitStat_Level prereq to the AbilityBonusOption (for Regeneration1 in this example) but it doesn't seem to work - it actually makes the unit unavailable so presumably that prereq is not allowed against an AbilityBonusOption.

What I am trying to do is essentially create a unit similar to the Sion where they get abilities on level up.... but I want the "perks" to be preset, i.e. Ability A at level 3, Ability B at level 5 Ability C at level 7 etc.  Seems a bit trickier than I thought it would be.

 

Reply #8 Top

To do that kind of trait, you need to give it the choice of traits at level-up, then block all other traits from appearing in your choice list. This leaves only your personal options.

Reply #9 Top

To do that kind of trait, you need to give it the choice of traits at level-up, then block all other traits from appearing in your choice list. This leaves only your personal options.

Yep that's pretty much the conclusion I had reached.  I just need to rework my concept a bit seeing as they will get the popup to choose each level... so have a number of roughly equal strength choices they can choose from during levels 2 to 5, then maybe a few more that are stronger with a minimum level added of 6 for once they reach level 6 etc.  That should work ok.

Thanks for the useful input (again).   :thumbsup: