mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Merge #6651
6651: Fix swapping with dragger beams (fixes #6597) r=Robyt3 a=def- ## Checklist - [ ] Tested the change ingame - [ ] Provided screenshots if it is a visual change - [ ] Tested in combination with possibly related configuration options - [ ] Written a unit test (especially base/) or added coverage to integration test - [ ] Considered possible null pointers and out of bounds array indexing - [ ] Changed no physics that affect existing maps - [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional) Co-authored-by: Dennis Felsing <dennis@felsin9.de>
This commit is contained in:
commit
fa2e7ca7f6
|
@ -218,3 +218,8 @@ void CDragger::Snap(int SnappingClient)
|
|||
GameServer()->SnapLaserObject(CSnapContext(SnappingClientVersion), GetID(),
|
||||
m_Pos, m_Pos, StartTick, -1, LASERTYPE_DRAGGER, Subtype, m_Number);
|
||||
}
|
||||
|
||||
void CDragger::SwapClients(int Client1, int Client2)
|
||||
{
|
||||
std::swap(m_apDraggerBeam[Client1], m_apDraggerBeam[Client2]);
|
||||
}
|
||||
|
|
|
@ -40,6 +40,7 @@ public:
|
|||
void Reset() override;
|
||||
void Tick() override;
|
||||
void Snap(int SnappingClient) override;
|
||||
void SwapClients(int Client1, int Client2) override;
|
||||
};
|
||||
|
||||
#endif // GAME_SERVER_ENTITIES_DRAGGER_H
|
||||
|
|
Loading…
Reference in a new issue