Space Engineers

Space Engineers

Energy Shields
[HARK] Harudath 11. sep. 2016 kl. 12:18
Recharge Curve/Power Consumption Formulae
I was wondering if you'd mind releasing the formulae for the rate of decline of recharge before and after the 25% mark, and how power consumption changes with this figure.

Many thanks
< >
Viser 1-1 af 1 kommentarer
Cython  [udvikler] 15. sep. 2016 kl. 9:34 
Oh Steam never notifies me about new discussions. :O

The power consumption multiplier is exactly the same as the recharge speed multiplier. It is not a real formula though, just an approximation via if-else code switches. Here it is:

float multiplier = (m_currentShieldPoints / m_maximumShieldPoints);

if (multiplier > 0.99999f) {
multiplier = 0.00001f;
} else if ((multiplier > 0.9f) || (multiplier < 0.08f)) {
multiplier = 0.1f;
} else if ((multiplier > 0.7f) || (multiplier < 0.12f)) {
multiplier = 0.2f;
} else if ((multiplier > 0.5f) || (multiplier < 0.18f)) {
multiplier = 0.4f;
} else if ((multiplier > 0.35f) || (multiplier < 0.22f)) {
multiplier = 0.7f;
} else {
multiplier = 1.0f;
}

So between 35%-22% it has 100% power consumption and recharge rate.
Between 50%-35% and 22%-18% it is 70% and so on.

I hope this is what you were lokking for and helps you out.
< >
Viser 1-1 af 1 kommentarer
Per side: 1530 50