Live data from Hacker News

Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

reddit.com

1–10 of 267 posts

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#2
From the comments:

"This was caused by a floating point rounding error. A unit switching jobs internally becomes a different unit (i.e. a monk with a relic becomes a monk without a relic), and when doing that, HP is scaled proportionally based on the old and new max HP using 32-bit floating point maths."

And there are YouTube videos about this https://www.youtube.com/watch?v=MytWNbpnAVY

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#3
This is a fantastic out of context change log.

For even more abstract ones I cannot recommend enough the Dwarf Fortress Bugs Twitter account[0]

The last of which is

> Flying creatures keep exploding into pieces and dying: Are they crashing into trees?

[0]sadly no Mastodon, https://twitter.com/DwarfFortBugs

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#5
post #4

I was stopping myself from buying Definitive Edition but I guess I am buying it today...

Note that the April 2023 patch is live, and perhaps one of the biggest changes to the meta ever. I don't think anyone really knows how the new meta will shake out.

Build orders will absolutely change this patch. Though I guess that only matters if you were hoping to get to a competitive level.

Definitive Edition does have a very good tutorial mode for people interested in online combat, and "Extreme" AI is 100% legitimate (AoE2 Extreme does NOT cheat, you're fighting it fair-and-square, but Extreme does a proper build order so it just "feels" quick if you haven't studied build orders yet)

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#6
post #2

From the comments: "This was caused by a floating point rounding error. A unit switching jobs internally becomes a different unit (i.e. a monk with a relic becomes a monk without a relic), and when doing that, HP is scaled proportionally based on the old and new max HP using 32-bit floating point maths." And there are YouTube videos about this https://www.youtube.com/watch?v=MytWNbpnAVY

> The formula was probably `return new_maxhp * (old_hp / old_maxhp);` ...

> Due to floating point rounding errors, convert_hp(1, 55, 55) equals 0.999999940395355224609375, which is less than 1, which means the unit dies.

Ahh. The old "Multiplying and dividing is associative... for the set of reals, not for the subset that you can actually afford to compute with." So it should have been `(new_maxhp * old_hp) / old_maxhp`. ffmpeg has a whole AVRational class for the same type of problem when converting timestamps accurately between 2 timebases.

Reminds me of the TF2 ammo boxes that give 40 metal on Linux and 41 on Windows https://www.youtube.com/watch?v=QzZoo1yAQag&pp=ygUfdGYyIGhlY...

Apparently the compiler used on Linux chose a less-accurate multiply instruction for 0.2 * 200.

Two wrongs make a right - After being less accurate but rounding up where you don't need to, the Linux binary correctly arrives at 40, and the Windows binary arrives at 41.

For percents (and dollars) I always do everything in cents and divide by 100 at the very end. "20 * 200 / 100" can be done with pure ints, and f32 can represent i16 exactly.

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#7
post #4

I was stopping myself from buying Definitive Edition but I guess I am buying it today...

Note that the April 2023 patch is live, and perhaps one of the biggest changes to the meta ever. I don't think anyone really knows how the new meta will shake out. Build orders will absolutely change this patch. Though I guess that only matters if you were hoping to get to a competitive level. Definitive Edition does have a very good tutorial mode for people interested in online combat, and "Extreme" AI is 100% legit…

What’s new? Seems kind of crazy to introduce a meta changing past to an old game like this that has managed to stay popular.

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#9

Earlier quoted context omitted.

Note that the April 2023 patch is live, and perhaps one of the biggest changes to the meta ever. I don't think anyone really knows how the new meta will shake out. Build orders will absolutely change this patch. Though I guess that only matters if you were hoping to get to a competitive level. Definitive Edition does have a very good tutorial mode for people interested in online combat, and "Extreme" AI is 100% legit…

What’s new? Seems kind of crazy to introduce a meta changing past to an old game like this that has managed to stay popular.

Several infantry civs like inka, sicilians, slavs, vikings, celts and dravidians got many huge buffs. Main change to like 50% of the civs is called gambesons, which adds 1 pierce armor to the militia line, basically reducing the damage they get from skirmisher by 50%.

Re: Aztec monks with 1/55 HP no longer die when picking up or dropping a relic

#10
post #4

I was stopping myself from buying Definitive Edition but I guess I am buying it today...

Note that the April 2023 patch is live, and perhaps one of the biggest changes to the meta ever. I don't think anyone really knows how the new meta will shake out. Build orders will absolutely change this patch. Though I guess that only matters if you were hoping to get to a competitive level. Definitive Edition does have a very good tutorial mode for people interested in online combat, and "Extreme" AI is 100% legit…

What's up with all of these 18 feudal builds?? And to Hell with the Portuguese fast castle, organ gun OP on arena.
Post reply on HN