View Full Version : Percentage mechanics and the new tradeskill racial traits
Prrasha
09-03-2009, 12:04 PM
<p>Currently, on Live, there's an earring/belt set (from Far Seas Supply Division & Tradeskill missions) that gives a +5% durability "bonus".On a normal failure round of -50 durability, +0 progress, wearing these items gives you -52,+0. I re-verified this behavior within the past week on a Live server*.Now on Test, we have racial traits that can give a +1% durability "bonus".So there are 2 significant problems with this:1) Look at the way fractions are being rounded... they aren't. They're being dropped. 5% of 50 is 2.5, which if rounded would be 3, not 2. So a 1% modifier will only have an effect if the base number is at least 100... how does one get a +100 durability round? Only when the "Insight" event happens. (The other two rare events give you +1000, which is the entire durability bar, so the +1% there has no additional effect.)2) More significantly, it's modifying the NEGATIVE numbers the same way as the positive ones. Considering how often Durability is a negative number versus a positive one, a +% durability effect is currently a <em>penalty</em> more often than it is a bonus (consider the starting and ending positions of the bars... you wind up with 1000 more progress at the end of a craft than when you started, but you almost always have less durability than when you started... at best, you have exactly the same amount. So any across-the-board percentage effect is a net bonus for progress and a net penalty for durability as the mechanics are now.)Please fix the mechanics of this effect (i.e. only apply the +% if the progress/durability number to be modified is positive, ignore the +% otherwise), and make "+1%" into a number more meaningful than "only matters if you get a rare Insight event after already losing a lot of durability on previous rounds," by either changing the rounding effects, or raising the value above 1%.If nothing else, scrap the whole idea of "+percentage durability" and just make all the effects "+constant-number durability" like the other style of +2-durability racial traits.* - Sorry for not re-verifying in the Test environment, but my /testcopy add commands still haven't had any effect, even after re-issuing one of them yesterday. All my previously-testcopied characters have been wiped, and my normal-Test characters are too lowbie to have these items.</p>
<p>Agreed. Once this stuff goes live. ALL the durability items that used to give +X % durability need to be changed to be a raw +durability/round.</p><p>This bug has been in there for a long time, and it seems that the new racials show there is a way to fix it.</p>
LivelyHound
09-14-2009, 07:27 AM
<p><cite>Barx@Antonia Bayle wrote:</cite></p><blockquote><p>Agreed. Once this stuff goes live. ALL the durability items that used to give +X % durability need to be changed to be a raw +durability/round.</p><p>This bug has been in there for a long time, and it seems that the new racials show there is a way to fix it.</p></blockquote><p>There was always a way to fix it, they just need to change the sign in the code from</p><p>durability loss = random(0, -10, -50, -100) <span style="color: #888888;">determined during the crafting tick success roll.</span>durability change = durability loss + ( durability loss x durability%bonus ) todurability change = durability loss - ( durability loss x durability%bonus )</p><p>due to the fact that it only affects base ticks and base ticks can be either 0, -10, -50 or -100. In other words durability loss is always a negative and the bonus therefore needs to be swapped to give a positive.</p><p>I imagine they currently have something like:</p><p>durability%bonus = racial durability % bonus + aa durability % bonus + gear durability % bonusdurabilityabsolutebonus = racial durability amount bonus + aa durability amount bonus + gear durability amount bonus</p><p>durability change = durability loss + (durability loss x durability%bonus ) + durabilityaboslutebonus</p><p>(aa durability % bonuses dont exist but they may in the future so I included the term in preparation)</p><p>Which is why the racials work and the % bonus doesnt. Its a very quick and simple fix. However if they dont want to hardcode that + to a - becuase they are worried about turning any current or future positive amounts that come from that part of the formula into negatives the following would fix it. Im sure theres a better way:</p><p>%durabiltychangeamount = durability loss x durability%bonusif (%durabiltychangeamount < 0) then %durabiltychangeamount = -%durabiltychangeamountdurability change = durability loss + durabilityabsolutebonus + %durabilitychangeamountIn java you can just use the Math.abs function</p><p>durability change = durability loss +Math.abs(durability loss x durability%bonus ) + durabilityaboslutebonus</p><p>Problem solved.</p><p>Not that the +durability amounts will actually help much except in group crafting missions. Remembering of course that they essentially only have +10 to play with because that is the cost of a regular success tick, and the number of fail ticks is/should be very low due to all the current bonuses. Thus if they added +1, +2 and +3 for the 3 respective durability sets on live and then you add in the +2 from a racial, then you are suddenly at -5 a tick as opposed to -10 a tick and you have a 50% reduction in the crafting penalty which in theory is huge! But in fact is pointless as the current mechanics mean that no amount of +durability is necessary unless you are an afk or semi-afk crafter. The new traits might help new low level crafters and I am going to see with my new woodworker how the numbers look.</p><p>As to the rounding that, I imagine, is just becuase they are casting the fraction into an integer as fractions make no sense in crafting ticks <img src="/eq2/images/smilies/3b63d1616c5dfcf29f8a7a031aaa7cad.gif" border="0" /> As in %durabiltychangeamount = Int(durability loss x durability%bonus) It could be rounded properly I imagine but it would take more time and slow the code down and that lost 1 here and there I can forgive for a little speed. They could cahnge this using a rounding function giving something like:</p><p>+Math.abs(Math.round(durability loss x durability%bonus))</p><p>Total code:</p><p>durability%bonus = racial durability % bonus + aa durability % bonus + gear durability % bonusdurabilityabsolutebonus = racial durability amount bonus + aa durability amount bonus + gear durability amount bonus<span style="color: #888888;">... other crafting code...</span>durability change = durability loss + Math.abs(Math.round(durability loss x durability%bonus)) + durabilityaboslutebonus</p><p>Test for bugs <img src="/eq2/images/smilies/8a80c6485cd926be453217d59a84a888.gif" border="0" /></p><p>However, maybe their current code is a lot more complex and so the fix isnt that easy, no idea as I've not seen the code <img src="/eq2/images/smilies/69934afc394145350659cd7add244ca9.gif" border="0" /> This would however add in two extra function calls to determine the proper value to be added by % bonus items and that might slow the whole thing down, but I doubt it. Well it would be one actually as the math.round is a cast to int at the moment but hey...</p><p>This does of course ignore the fact that crafting arts are unaffected by these bonuses.</p>
vBulletin® v3.7.5, Copyright ©2000-2025, Jelsoft Enterprises Ltd.