UA not doing what I expected So I thought I knew what I was doing with the UA.
There are some NPC's that I think are a certain alignment. Today however they are all +1 more good. But the UA is only at 68 good. I thought the UA rounded DOWN which would mean NPCs should be normal today?
The same NPC's order/chaos is what I would expect today based on the UA being 29 chaos.
The alignment change is UA/100 rounded up. Rounded up, in this case, means rounded to the nearest integer greater or equal to the UA/100. This means that 0.2 rounds up to 1 but -0.99 rounds up to 0 because 0 is greater than -0.99.
Couldn't we just have a conditional where if it is <= 0 it rounds down? That would take the bias out of it.
Although, with the general laws of entropy it would make sense for things to drift towards chaos
basically
if UA <= 0
UA_bonus = floor(UA/100)
else
UA_bonus = ceil(UA/100)
Well son of a gun. Never really paid attention until this cycle. Now it makes sense why sometimes this cycle my numbers were on and sometimes off. Thank you.
The Natsa thread gives an example of a UA where it is evil/chaos and mentions rounding down. I assumed the same applied to good/order. Dog nab it all, assumed gets me again.
the code block in "attack", "converse" and "sexor" has been changed from:
$uage=ceil($universal_alignment[ge]/100);
$uoce=ceil($universal_alignment[oc]/100);
To:
if ($universal_alignment[ge]>0) {$uage=ceil($universal_alignment[ge]/100);} else {$uage=floor($universal_alignment[ge]/100);}
if ($universal_alignment[oc]>0) {$uoce=ceil($universal_alignment[oc]/100);} else {$uoce=floor($universal_alignment[oc]/100);}
I'm guessing this will achieve the desired effect and eliminate the first-day ES bias.