analysing shapechange, does it work as intended?
#1
Posté 12 décembre 2009 - 12:17
My Morrigan has a spellpower of 54, which should mean (rounded up) 10+11 = 21 strength. However, when I empirically turn her into a spider, her strength is 16, from an original stat of 14.
So what's up? Did I misinterpret the code?
#2
Posté 12 décembre 2009 - 12:35
#3
Posté 12 décembre 2009 - 02:05
#4
Posté 12 décembre 2009 - 02:51
Yes, you're reading it wrongfro7k wrote...
According to spell_shapeshift.nss, the stat modifiers of a shapechange make up for the difference between the mages' statistics and the forms' target statistics. According to shapechange.xls, a spiderform gets a base strength of 10 and +1 per "form level" which is spellpower / 5.
My Morrigan has a spellpower of 54, which should mean (rounded up) 10+11 = 21 strength. However, when I empirically turn her into a spider, her strength is 16, from an original stat of 14.
So what's up? Did I misinterpret the code?
The attributes for the forms are calculated using: base attribute value + level * attribute per level (level is calculated as spellpower / 5, plus additionally shapeshift mastery grants +2 to it)
the "attribute per level" part doesn't have to equal 1 and in most situations it doesn't. In case of strength for spider StrengthPerLevel column reads "0.5" ... so your Morrigan gets 10 base + (11 * 0.5 = 5.5 rounded up = 6) ... which results in 16 as final attribute.
To make things even more confusing some forms receive passive effect which can adjust their stats further. For example bear form gets "bear_properties" effect from API_base which adds +10 to armour etc.
Modifié par tmp7704, 12 décembre 2009 - 02:55 .
#5
Posté 12 décembre 2009 - 11:00
tmp7704 wrote...
Yes, you're reading it wrongfro7k wrote...
According to spell_shapeshift.nss, the stat modifiers of a shapechange make up for the difference between the mages' statistics and the forms' target statistics. According to shapechange.xls, a spiderform gets a base strength of 10 and +1 per "form level" which is spellpower / 5.
My Morrigan has a spellpower of 54, which should mean (rounded up) 10+11 = 21 strength. However, when I empirically turn her into a spider, her strength is 16, from an original stat of 14.
So what's up? Did I misinterpret the code?
The attributes for the forms are calculated using: base attribute value + level * attribute per level (level is calculated as spellpower / 5, plus additionally shapeshift mastery grants +2 to it)
the "attribute per level" part doesn't have to equal 1 and in most situations it doesn't. In case of strength for spider StrengthPerLevel column reads "0.5" ... so your Morrigan gets 10 base + (11 * 0.5 = 5.5 rounded up = 6) ... which results in 16 as final attribute.
To make things even more confusing some forms receive passive effect which can adjust their stats further. For example bear form gets "bear_properties" effect from API_base which adds +10 to armour etc.
Well, that's exactly what I thought. I only read from the wrong field since it's a long row and I followed it along with my eyes and read from the row above.
#6
Posté 12 décembre 2009 - 10:30
#7
Posté 12 décembre 2009 - 10:34
#8
Posté 12 décembre 2009 - 11:57
tmp7704 wrote...
On semi-related note there do seem to be some errors in the original shapeshifting code, related mainly to way some attributes (damage bonus and armour penetration) are handled. I'm toying with this system atm, hopefully can straighten it out and make it somewhat more viable.
Could you elaborate on this? I've skimmed the shapeshift code quite a few times and haven't seen anything that would make me think it was a bug.
#9
Posté 13 décembre 2009 - 12:40
There also might be one "break;" missing in the code which resulted in game using values for armour penetration to calculate intended damage bonus, but at this point i can't tell if this error is in the original code or if it was just me hitting delete in the wrong spot.
#10
Posté 13 décembre 2009 - 07:49
Also, good eye on the missing break. I have it too and I know I haven't touched that script since the update.
Modifié par MachDelta, 13 décembre 2009 - 07:49 .
#11
Posté 13 décembre 2009 - 11:47
Yes, exactly. At the same time the function which modifies the properties works as you'd expect i.e. in order to modify AP by 5 you need to pass 5 as argument rather than 0.05. This is easy to miss since basic AP is very high on staves, and when it comes to damage bonus the final value is also affected by changes to strength attribute... but in its default form the code does do calculations wrong because it computes effect to apply using the scaled down values it receives rather than what these values 'really' are.MachDelta wrote...
I'm not sure I follow. Are you saying that GetCreatureProperty(oAttacker, Property_Attribute_AP) returns 0.05 instead of 5.0?
#12
Posté 13 décembre 2009 - 07:26
Modifié par tmp7704, 13 décembre 2009 - 09:05 .
#13
Posté 13 décembre 2009 - 09:05
Modifié par Praylak, 13 décembre 2009 - 09:07 .
#14
Posté 13 décembre 2009 - 10:03
Keep in mind the change would have to be done in a rather counter-intuitive manner (to increase damage of the forms you'd have to adjust the columns which define their AP, not the ones for damage)
Trying to do it "proper" way i've ran into a minor issue, it seems the act of changing the shape itself changes also the damage output of the caster (probably because they switch from staff to melee somewhere under the hood) which can throw off the calculation of by how much the damage should be then adjuste as the reported damage bonus doesn't update when it happens, at least while out of combat, even though the change is visible on the character's info sheet. Rather annoying, really.
Modifié par tmp7704, 13 décembre 2009 - 10:04 .
#15
Posté 13 décembre 2009 - 11:40
I suppose I could look at this myself, but I'm amatuer. Still, I'm going to take a look.
EDIT: Ok I see now. Comparing the Spider to the Spirit form sheds allot of light. I was always curious why the Spirit form dealt much more damage than the Spider. Don't you think its just many of the values are just set too low for Spider, and bear? The Golem seemed to perform quite well in the game as well, in contrast to the lacking Bear form. Looking at the DamageB and DamageP column, its seems quite significant.
Modifié par Praylak, 14 décembre 2009 - 12:24 .
#16
Posté 14 décembre 2009 - 02:07
I've put together a mod which attempts to straighten things out to some degree at least: http://social.biowar...m/project/1317/
it wasn't tested much so if you want to give it a try, proceed with caution. I have no idea what's typical Spellpower value people have on their casters, so it's possible the modified version makes these characters completely out of whack (though i'm really hoping not)
Modifié par tmp7704, 14 décembre 2009 - 02:08 .
#17
Posté 14 décembre 2009 - 03:08
It would appear you've gone a step or two further in making the forms more distinct, and I for one think thats great. Although I couldn't get your mod to work though. Emptied my override, etc.
I also changed the passive trait for the bear so it gets the nature resist as the tooltip states, like the spider does.
How did you balance the Dragon form against the others? Or is it meant to replace all the other forms?
#18
Posté 14 décembre 2009 - 03:27
Hmm i fear this may have something to do with the installation being just straight unpack into Dragon Age folder. I couldn't figure out a way for the default installer to put the modified *.ncs script into the main core/override directory so i made a normal archive out of the whole thing. It probably needs an entry in addins.xml to showup or whatnotPraylak wrote...
Although I couldn't get your mod to work though. Emptied my override, etc.
The dragon form has little less armour than the bear and doesn't have bear's "tank" trait which gives the latter 100+ more health. It is intended to be sort of equivalent of a 2h warrior while spider is closer to a rogue and bear is more like sword-and-board guy. Out of them all the dragon is probably most rounded out option that's sort-of good for everything, but i wanted to keep the other ones useful in some situations too. Hard to say how well it worked out though.
edit: i've repacked the mod into some weird combination of .dazip and the separately packed script. It's even less convenient to install now but hopefully will at least be possible to install at all
Modifié par tmp7704, 14 décembre 2009 - 03:55 .





Retour en haut






