To add heat to the vehicle of you're choice, you're going to need to edit several values. These values can be edited in the Floats section of the weapon tag. You will need to edit the following values (mostly explained by Nex):
Heat Recovery Threshold. This is a value between 0 and 1, and it determines at what "position" or "amount" of heat you can resume firing after an overheat. A value of 0.5 would mean that after an overheat, firing can resume once the heat threshold has dropped to 50% or lower. A value of 33% would be roughly 1/3 of the heat bar.
Next is the Overheat Threshold. Also a [0,1] value. This should be set to 1 pretty much always. This will determine the (go figure) threshold for overheating. If you set this to 0.5, for instance, then when the heat bar fills to 50%, your weapon will overheat. Therefore, at a value of 1, when the heat meter fills up completely, it will overheat, so this is best kept at 1.
Heat Loss Per Second. This guy is yet again between [0,1] and is how much (in percentage) of the heat bar drains per second. If you set it to 1, that means that 100% of the heat is lost in 1 second, so therefore it would take 1 second to go from completely overheated (full heat meter) to completely back to normal (empty heat meter). A value anywhere from 0.1 to 0.3 should be pretty good for a decent "cooldown" time for a weapon. Any faster and the whole point of overheating weapons is sort of defeated.
Heat Generated Per Round. This value controls how much heat is generated per round. If you set it to 0.5, you could fire 2 bullets in a second, then it would overheat the vehicle's weapon.
To add the 'heat' to the vehicle weapon tag, swap the nulled out weapon HUD with the "ui\hud\master fuel" (or master fuel+ if you dupilicated the HUD tag), in the weapon hud linked to the vehicle you're adding heat to.
Open up the "ui\hud\master fuel" tag, then go to the Bitmask32 section of the weapon HUD, click on 'flag' and untick 'use parent hud flashing parametters'.
Next, go to the Int16s section, and change 'total ammo cutoff' and 'loaded ammo cutoff' to 9999. Then change 'heat cutoff' value to something appropriate. Heat cutoff controls when the meter will start/stop flashing.
Optional: If you want to get the same HUD as Phoenix 2 or 3, you will needed to move certain elements around.
Code: Select all
Static Elements: Static Elements 1 & 2: Go to the Int16s change the 'anchor offset - x' to -100. Static Elements 3, 4 & 5 : Go to the Int16s change the 'anchor offset - y' to 0. Meter Elements: Meter Elements 1: Go to the Int16s change the 'anchor offset - x' to 6, then change the 'anchor offset - y' to 0. Meter Elements 2: Go to the Int16s change the 'anchor offset - y' to 0. Number Elements: Number Elements 1: Go to the Int16s change the 'anchor offset - x' to -100. Crosshairs: Crosshair 2 & 3: Go to the Int16s change the 'anchor offset - x' to 999. Overlays: Overlay 1: Go to the Int16s change the 'anchor offset - x' to -100.
Big thanks to NeX for saving me some time.