Update connection.cpp
This commit is contained in:
parent
99a5054c8f
commit
11458214d0
@ -171,12 +171,14 @@ Timestamp Connection::Run(World* world) {
|
|||||||
}
|
}
|
||||||
else toggle = false;
|
else toggle = false;
|
||||||
|
|
||||||
out.states.jumpshot = false;
|
out.states.shooting = in.keys.shoot;
|
||||||
|
|
||||||
|
if (out.states.jumping && out.states.shooting)
|
||||||
|
out.states.jumpshot = true;
|
||||||
|
else out.states.jumpshot = false;
|
||||||
|
|
||||||
if (in.keys.shoot && m_shoot_acc <= 0.) {
|
if (in.keys.shoot && m_shoot_acc <= 0.) {
|
||||||
Bullets.emplace_back(new Bullet(player->GetPOV() + player->GetDirection(), player->GetDirection(), GetHash(true)));
|
Bullets.emplace_back(new Bullet(player->GetPOV() + player->GetDirection(), player->GetDirection(), GetHash(true)));
|
||||||
out.states.shooting = true;
|
|
||||||
if (out.states.jumping)
|
|
||||||
out.states.jumpshot = true;
|
|
||||||
m_shoot_acc = BULLET_TIME;
|
m_shoot_acc = BULLET_TIME;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user