Knuckle Cracker

Knuckle Cracker => Support => Topic started by: GameGibu on October 31, 2017, 04:44:54 PM

Title: [Bug] Emergent current health not accessible via [G/S]etUnitHealth or variants
Post by: GameGibu on October 31, 2017, 04:44:54 PM
Currently, it appears that GetUnitHealth (and <-UID.unitHealth, etc) returns only the initial health for Emergent ("unit health"). Setting the minimum health of emergent in the editor to a higher (or lower) value will get that same higher/lower initial value returned, regardless of the Emergent's actual current damage/size ("demonstrated health"). Furthermore, SetUnitHealth (and ->UID.unitHealth) do not change the demonstrated health of the particle, though they change the unit health. It otherwise causes no change in the behaviour, durability or size of the Emergent.

Or is there another hidden set of undocumented commands that set/get health exclusively for Emergent units?
Title: Re: [Bug] Emergent current health not accessible via [G/S]etUnitHealth or variants
Post by: GoodMorning on October 31, 2017, 04:55:52 PM
Could be that Emergent, being based on a virtual particle, need a GetParticleHealth call.
Title: Re: [Bug] Emergent current health not accessible via [G/S]etUnitHealth or variants
Post by: GameGibu on October 31, 2017, 11:20:40 PM
Quote from: GoodMorning on October 31, 2017, 04:55:52 PM
Could be that Emergent, being based on a virtual particle, need a GetParticleHealth call.

Is there a way to get the virtual PID from a specific unit/UID without using any targeting commands that might not return the right thing?
Title: Re: [Bug] Emergent current health not accessible via [G/S]etUnitHealth or variants
Post by: GoodMorning on November 01, 2017, 12:53:36 AM
Not that I know of.

However, using a range of 0 and the pixel coords of the Emergent in question for a targeting command is one of the most reliable ways.