No, it's the maximum size for a 19 bit unsigned integer number(20 bit signed). A 32 bit unsigned number will go up to about 4 billion(2 billion if sighted). I'm not sure they use integers though.
Also, it's not lazy. Any reasonable value for HP is going to fit in a 32 bit number(or even a 20 bit number, but I've no idea why they'd use 20 bit numbers). It would be silly and slow down arithmetic for them to use more complex number representations that can't be computed directly on the ALU for something like this.
To avoid stupid mappers giving bosses / units pointlessly huge amount of health that helps nothing except making the map more boring?
There are certain scenarios that require such huge hp amounts. For example, you want something to be almost unkillable, but with the right upgrades, to be killable. If you have 10 or 20 or more layers of that, the hp numbers can add up quite quickly!
There are certain scenarios that require such huge hp amounts. For example, you want something to be almost unkillable, but with the right upgrades, to be killable. If you have 10 or 20 or more layers of that, the hp numbers can add up quite quickly!
stupid low max real number. any way to get past this limitation? my bosses keep wrapping around to 0 HP or worse - HP
Give % dmg reduction to the boss. 50% dmg reduction for double health, 66% for triple etc.
Using multiple hp refills via triggers is neither elegant nor a mechanic players will like. It's like when you download something, and the time to finish keeps betting bigger.
stupid low max real number. any way to get past this limitation? my bosses keep wrapping around to 0 HP or worse - HP
@VeridianEntropy: Go
Give the boss multiple lives maybe? =/ each one worth 100k, when he's dying, refill his life to max x times.
@FuzzYD: Go
this is a seriously low number though... why would blizzard do this...
ah its the maximum size for a 32 bit number... that's just lazy
No, it's the maximum size for a 19 bit unsigned integer number(20 bit signed). A 32 bit unsigned number will go up to about 4 billion(2 billion if sighted). I'm not sure they use integers though.
Also, it's not lazy. Any reasonable value for HP is going to fit in a 32 bit number(or even a 20 bit number, but I've no idea why they'd use 20 bit numbers). It would be silly and slow down arithmetic for them to use more complex number representations that can't be computed directly on the ALU for something like this.
@VeridianEntropy: Go
To avoid stupid mappers giving bosses / units pointlessly huge amount of health that helps nothing except making the map more boring?
There are certain scenarios that require such huge hp amounts. For example, you want something to be almost unkillable, but with the right upgrades, to be killable. If you have 10 or 20 or more layers of that, the hp numbers can add up quite quickly!
This is the limit of the fixed type.
Naaah.
Give % dmg reduction to the boss. 50% dmg reduction for double health, 66% for triple etc.
Using multiple hp refills via triggers is neither elegant nor a mechanic players will like. It's like when you download something, and the time to finish keeps betting bigger.
@Vitkar: Go
Why in gods name would you ever need to give anything 600,000 hp
If you've played his retribution td you will know.
Anyways http:www.sc2mapster.com/assets/hp-above-520k/files/2-hp-above-520k-v0-1/
Something I wipped up in around 30 mins, also posted this on your retribution td comments.
I appreciate all the help (and criticism) I'm always willing to hear it all considering I"m not a super experienced programmer.
Regarding the ALU, I actually never considered that limitation. and they should be using floats rather than integers.
Anyways, I'm going to take a look at Salmon's solution, thanks guys.