mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Keep respawned players in multi view list on pvp servers
Assume every server that does not have ddnet or race in its gametype to be a pvp server. This allows spectators to follow multiple players during a fng/ctf/gctf/ictf round. Related issue #7509
This commit is contained in:
parent
3887eea18d
commit
4f4f32615a
|
@ -944,7 +944,8 @@ void CGameClient::OnMessage(int MsgId, CUnpacker *pUnpacker, int Conn, bool Dumm
|
|||
}
|
||||
|
||||
// if we are spectating a static id set (team 0) and somebody killed, and its not a guy in solo, we remove him from the list
|
||||
if(IsMultiViewIdSet() && m_MultiViewTeam == 0 && m_aMultiViewId[pMsg->m_Victim] && !m_aClients[pMsg->m_Victim].m_Spec && !m_MultiView.m_Solo)
|
||||
// never remove players from the list if it is a pvp server
|
||||
if(IsMultiViewIdSet() && m_MultiViewTeam == 0 && m_aMultiViewId[pMsg->m_Victim] && !m_aClients[pMsg->m_Victim].m_Spec && !m_MultiView.m_Solo && !m_GameInfo.m_Pvp)
|
||||
{
|
||||
m_aMultiViewId[pMsg->m_Victim] = false;
|
||||
|
||||
|
@ -1256,6 +1257,7 @@ static CGameInfo GetGameInfo(const CNetObj_GameInfoEx *pInfoEx, int InfoExSize,
|
|||
Info.m_EntitiesVanilla = Vanilla;
|
||||
Info.m_EntitiesBW = BlockWorlds;
|
||||
Info.m_Race = Race;
|
||||
Info.m_Pvp = !Race;
|
||||
Info.m_DontMaskEntities = !DDNet;
|
||||
Info.m_AllowXSkins = false;
|
||||
Info.m_EntitiesFDDrace = FDDrace;
|
||||
|
|
|
@ -87,6 +87,7 @@ public:
|
|||
bool m_EntitiesFDDrace;
|
||||
|
||||
bool m_Race;
|
||||
bool m_Pvp;
|
||||
|
||||
bool m_DontMaskEntities;
|
||||
bool m_AllowXSkins;
|
||||
|
|
Loading…
Reference in a new issue