calculation questions

1)when is reseted the calc?

ie i have to add + n to dodge and accuracy, do i have to do

gamemodifier

adjust dodge

calc,get unistat n

value=calc

/gamemod (calc get reseted here)

gamemod

adjust accuracy

calc, get n

blablabla

 

or i get calc first time and it works even on second modifier without recalling it?

 

2)can i use calc on stats different from value?

i tried

            <Calculate InternalName="Duration">
                <Expression><![CDATA[[Calc]]]></Expression>
            </Calculate>

but doesnt look like its working

i need to make dynamic range, cooldown for example

 

 

 

4,065 views 9 replies
Reply #1 Top

Afaik calculations are reset when the modifier ends.

Afaik you cannot use calculations on anything except value.

Reply #2 Top

thats too bad

and i suspect calculations arent working into traits right?

 

any way i can give a dynamic buff with a trait ?

or can i have a trait giving a buff to the unit at all?

 

 

 

Reply #3 Top

Calculate should work on any gamemodifier that has the Value tag.

Reply #4 Top

Quoting ddd888, reply 2
thats too bad

and i suspect calculations arent working into traits right?

 

any way i can give a dynamic buff with a trait ?

or can i have a trait giving a buff to the unit at all?

 

 

 

When I tried putting calculations way back in the day in traits, they only ran once - at the time the unit was created.

 

You can have a trait cast a buff on the unit in combat using BattleAutoCastSpell.

Reply #5 Top

Have you tried it since they introduced the <HasUpgradeableValue> tag?

Also, not to go off topic, but I also just noticed the <ValueCalcWrapper> tag...what does it do?

Reply #6 Top

Quoting mqpiffle, reply 6
Have you tried it since they introduced the tag?

No.

Quoting mqpiffle, reply 6
Also, not to go off topic, but I also just noticed the tag...what does it do?

Nothing right now. It is supposed to help the AI figure out what spell should have priority.

Reply #7 Top

true, like noble legacy does basically

ok, its not exactly what i need but can be adapted to it

 

thnx very much

 

@mqpiffle the problem is that i dont want to change the value, i want to change other stats

for example for spells i can make different ranks like fireball 2 with cooldown of 2 fireball 3 with cooldown of 3 etc , but i wanted to make a generic fireball N and then use other skills or gamestates to play with that N (being it cooldown or range or other stuff)

Reply #8 Top

Quoting ddd888, reply 8
@mqpiffle the problem is that i dont want to change the value, i want to change other stats

for example for spells i can make different ranks like fireball 2 with cooldown of 2 fireball 3 with cooldown of 3 etc , but i wanted to make a generic fireball N and then use other skills or gamestates to play with that N (being it cooldown or range or other stuff)

I know what you wanted to do, which is why I replied the way I did ;P

Reply #9 Top

so are you referring to traits ?