mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
Merge pull request #1756 from nheir/patch-1
fix: missing damage indicators
This commit is contained in:
commit
9822fa858e
|
@ -234,8 +234,8 @@ Objects = [
|
||||||
NetEvent("Damage:Common", [ # Unused yet
|
NetEvent("Damage:Common", [ # Unused yet
|
||||||
NetIntRange("m_ClientID", 0, 'MAX_CLIENTS-1'),
|
NetIntRange("m_ClientID", 0, 'MAX_CLIENTS-1'),
|
||||||
NetIntAny("m_Angle"),
|
NetIntAny("m_Angle"),
|
||||||
NetIntRange("m_HealthAmount", 1, 9),
|
NetIntRange("m_HealthAmount", 0, 9),
|
||||||
NetIntRange("m_ArmorAmount", 1, 9),
|
NetIntRange("m_ArmorAmount", 0, 9),
|
||||||
NetBool("m_Self"),
|
NetBool("m_Self"),
|
||||||
]),
|
]),
|
||||||
]
|
]
|
||||||
|
|
|
@ -51,6 +51,10 @@ void CEffects::AirJump(vec2 Pos)
|
||||||
|
|
||||||
void CEffects::DamageIndicator(vec2 Pos, int Amount)
|
void CEffects::DamageIndicator(vec2 Pos, int Amount)
|
||||||
{
|
{
|
||||||
|
// ignore if there is no damage
|
||||||
|
if(Amount == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
m_DamageTaken++;
|
m_DamageTaken++;
|
||||||
int Angle;
|
int Angle;
|
||||||
// create healthmod indicator
|
// create healthmod indicator
|
||||||
|
|
Loading…
Reference in a new issue