HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Warning If you are using the SetHeroStat() in GoldenUrgs trigger patch

12-12-2002, 07:53 PM#1
DaKaN
Or just using the function with custom text

There is a nifty bug in blizzards code with the SetHeroStrn Agil or Intel. Just beware this if you use this in your map.

If the heros Strn is 50 and from items he has a +15, and you use the SetHeroStrn() to make it say, 60, the new strn will turn out to be 45 +15.

The problem is it counts the +to stat with the base when setting. so if your hero's strn is 0+5 and you set his strn to 1, the heros strn will become -4+5 becuase the it thinks 0+5 = 5 so the heros strn is 5, so i need to subtract 4 to make it 1.

Same holds true with Agil and Intel.

Not sure if i explained this too good...
12-12-2002, 09:34 PM#2
DemonicSoul
i think u could find ways around it, storing the items and removing them from the hero's inventory, then setting it, then putting them back
12-13-2002, 09:13 PM#3
DaKaN
Yea but thats alot of extra work for no good reason =) dumb bug, just a warning to others
12-13-2002, 10:05 PM#4
DemonicSoul
yea i guess :( but good that this is said, even tho im sure more ppl will do it and complain.... u know how people are....
12-14-2002, 03:42 AM#5
DaKaN
person = smart
people = dumb
12-17-2002, 09:06 PM#6
Guest
Is there any way to use this on purpose? I remember seeing a while back, a way to do negative damage, and heal chars when you hit them. I wonder if there is a way to use this to do something similar.. give them negative stats, then drop the item, or whatever..
12-18-2002, 12:21 AM#7
CBWhiz
i'd think so.

untested:
give claw of attack + 15
setherostr 0
give claw of attack + 15
setherostr 0
give claw of attack + 15
setherostr 0
give claw of attack + 15
setherostr 0

shold have strength -60 if the hero started with 0 ;)
12-18-2002, 12:58 AM#8
weaaddar
You can't set a hero's stat down.
I believe if you use the permanant set to false boolean you will counteract this, as it will not effect the total sum but rather just the base, again this is just a belief and not really been test.