Page 1 of 1

Bug: Carbon-weaver nanos and damage/hp calculations

Posted: Wed Dec 22, 2010 11:45 am
by SpongeJr
If you take a segment of (unenhanced) armor with x max hp that has taken y damage and apply carbon-weaver nanos to it you'll get a segment of damaged armor that has the new maximum hp value, the same amount of hp as it had before, but still has still only sustained y points of damage.

Example:
Say I have a segment of mundane Light Plasteel (60 hp max) and it takes 4 hp of damage and now has 56 hp. Then I apply some carbon-weaver nanos and it boosts the max hp to 90. The armor segment still has 56 hp but "has sustained 4 points of damage". The 4 points of damage is used both when repairing armor yourself or calculations to pay to have it repaired.

Is this working as intended? I'd expect either:
A. After applying the nanos, the armor would have 88 hp (4 less than its new max) and would have 86 / 90 hp.
B. After applying the nanos, the armor would retain its current hp but would need (newMax - currentHP) points of damage repaired. The armor would have 56 / 90 hp.
C. After applying the nanos, the armor would have the same ratio of hp as before application. Thus since it was 56/60 before, and the new max is 90, it would have (56/60) * 90 = 84 hp.

(B) Doesn't seem fair as the armor could wind up too heavily damaged to be repaired (I think?) with the new max. (A) Seems a little too generous. (C) seems like it would be the fairest and most logical solution to me.

Posted: Wed Dec 22, 2010 2:44 pm
by SpongeJr
:!: :!: :!:
I've confirmed this happens regularly, I can reproduce it... and the bug is bigger than I thought...

I currently have installed on my ship a segment of light plasteel that had 58/60 hp before applying the nanos. Afterwards it showed that the segment had a max of 90 hp, had 58 hp, had suffered 2 hp of damage...

...and now after repairing, I have a segment of light plasteel with 60 hp, a max hp of 90, and it is not in need of repairing.

=/

Posted: Wed Dec 22, 2010 3:01 pm
by Star Weaver
I have created a ticket:

http://wiki.neurohack.com/transcendence/trac/ticket/571

Not sure what componenet this should be, went with scripting. Maybe we need a "gameplay" or something.

Posted: Wed Dec 22, 2010 4:35 pm
by Ttech
NOOOOOOOOOOOOOOOO NOT a ticket! I actually have never had this happen to me, suppose its just luck.

Posted: Wed Dec 22, 2010 5:07 pm
by george moromisato
Thank you. Definitely looks like a bad bug. Armor mods are just plain broken.

What's supposed to happen is that the max increases without changing the current hp left [SpongeJr's scenario B]. But I think C also makes sense (and might be better).

Posted: Wed Dec 22, 2010 5:13 pm
by Aury
[quote="Ttech"]NOOOOOOOOOOOOOOOO NOT a ticket![quote]What do you mean?

Posted: Wed Dec 22, 2010 10:00 pm
by SpongeJr
Just found out a little bit more detail... even when the armor has full hp and you apply the carbon-weaver nanos... you still wind up with armor that is not in need of repair, yet still only has it's previous max HP... My undamaged armor with 100 hp has 100 hp after applying nanos, doesn't need repair, and has 100/130 hp. Not sure yet which number it actually USES, but I don't plan on taking 105 hp of damage on that segment to find out for sure...

Posted: Wed Dec 22, 2010 10:10 pm
by SpongeJr
...and my boy just found a workaround/fix for the problem. He said "Try replacing it with another armor segment then putting it back" and lo and behold, the armor segment now has 130 hp as it should!

Not bad for a kid, eh? Maybe he's got a future as a beta tester...

--
EDIT: It seems also that all armor buffs don't show up on the HUD until they are removed and re-installed. Now my question is whether or not the enhancements really are in effect before you "refresh" the armor segment like that or not? I'll try to find my own answer by checking out the xmls but not sure if the answer is there.

Posted: Wed Dec 22, 2010 10:19 pm
by george moromisato
SpongeJr wrote:...and my boy just found a workaround/fix for the problem. He said "Try replacing it with another armor segment then putting it back" and lo and behold, the armor segment now has 130 hp as it should!

Not bad for a kid, eh? Maybe he's got a future as a beta tester...
Nice! That should indeed fix the problem.

Posted: Wed Dec 22, 2010 10:25 pm
by Aury
SpongeJr wrote:EDIT: It seems also that all armor buffs don't show up on the HUD until they are removed and re-installed. Now my question is whether or not the enhancements really are in effect before you "refresh" the armor segment like that or not? I'll try to find my own answer by checking out the xmls but not sure if the answer is there.
Not to hard to test out, or fix for that matter, though it is fairly 'gimmicky' and may not work with every ship (ie, certain scripted custom ships would have problems with an enhnacer that would enhance, replace with a dummy segment, and then replace the dummy segment with the enhanced segment and delete the dummy)

Posted: Thu Dec 23, 2010 2:35 am
by SpongeJr
I seem to have accidentally exploited this... I currently have a segment of hardened plasteel armor installed on my ship that when viewed in Ship Configuration claims to have 100 hp and the Ablative enhancement. The resistance stats show as if it has the Ablative enhancement also. On the heads up display, it says "Ablative" by that armor segment, but it also says it has 130 hp instead of 100. If damaged, I can repair it up to 130 also. Woo hoo, double-enhanced armor!

I think(?) I wound up with this by using degenerating nanos at some point causing my armor to "lose its enhancement" when it had the +30% hp buff, then I applied the Ablative coating. Now it seems like I've got both buffs.

Hope this one gets fixed soon, it's all sorts of whacky.

Posted: Thu Dec 23, 2010 3:57 am
by Aury
So how did this get broken in the first place?

Posted: Thu Dec 23, 2010 10:31 am
by SiaFu
When considering armor HP enhancements, it would bear mentioning that Ingenuity in 1.03 enhances both current and max hp of a given segment by +20%/+50%.

I haven't tested it on damaged armor, though, but the damage is applied correctly to the enhanced armor from what I can tell (I had 0 HP and survived only due to Desperate escape triggering).

Posted: Fri Dec 24, 2010 1:01 am
by Ttech
SpongeJr wrote:...and my boy just found a workaround/fix for the problem. He said "Try replacing it with another armor segment then putting it back" and lo and behold, the armor segment now has 130 hp as it should!

Not bad for a kid, eh? Maybe he's got a future as a beta tester...

--
EDIT: It seems also that all armor buffs don't show up on the HUD until they are removed and re-installed. Now my question is whether or not the enhancements really are in effect before you "refresh" the armor segment like that or not? I'll try to find my own answer by checking out the xmls but not sure if the answer is there.

I think i see a future as one of those crazy game testers with video game stuff you see on tv.

And @Azar_Wolf I was joking.

Re: Bug: Carbon-weaver nanos and damage/hp calculations

Posted: Fri Jun 08, 2012 8:13 am
by Star Weaver
This is long since fixed (in 1.05), close.