3640: Bump version for the new protocol to DDNet 15.4 r=Learath2 a=heinrich5991

<!-- What is the motivation for the changes of this pull request -->

## 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 if it works standalone, system.c especially
- [ ] 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: heinrich5991 <heinrich5991@gmail.com>
This commit is contained in:
bors[bot] 2021-02-24 16:14:51 +00:00 committed by GitHub
commit 78041baf40
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View file

@ -114,7 +114,7 @@ enum
VERSION_DDNET_FIREDELAY_TUNE = 701,
VERSION_DDNET_UPDATER_FIXED = 707,
VERSION_DDNET_GAMETICK = 10042,
VERSION_DDNET_MSG_LEGACY = 15025,
VERSION_DDNET_MSG_LEGACY = 15040,
};
#endif

View file

@ -325,7 +325,7 @@ void CProjectile::Snap(int SnappingClient)
CNetObj_DDNetProjectile DDNetProjectile;
if(SnappingClientVersion >= VERSION_DDNET_ANTIPING_PROJECTILE && FillExtraInfo(&DDNetProjectile))
{
int Type = SnappingClientVersion <= VERSION_DDNET_MSG_LEGACY ? (int)NETOBJTYPE_PROJECTILE : NETOBJTYPE_DDNETPROJECTILE;
int Type = SnappingClientVersion < VERSION_DDNET_MSG_LEGACY ? (int)NETOBJTYPE_PROJECTILE : NETOBJTYPE_DDNETPROJECTILE;
void *pProj = Server()->SnapNewItem(Type, GetID(), sizeof(DDNetProjectile));
if(!pProj)
{

View file

@ -437,7 +437,7 @@ void CGameTeams::SendTeamsState(int ClientID)
Server()->SendMsg(&Msg, MSGFLAG_VITAL, ClientID);
int ClientVersion = m_pGameContext->m_apPlayers[ClientID]->GetClientVersion();
if(!Server()->IsSixup(ClientID) && VERSION_DDRACE < ClientVersion && ClientVersion <= VERSION_DDNET_MSG_LEGACY)
if(!Server()->IsSixup(ClientID) && VERSION_DDRACE < ClientVersion && ClientVersion < VERSION_DDNET_MSG_LEGACY)
{
Server()->SendMsg(&MsgLegacy, MSGFLAG_VITAL, ClientID);
}
@ -651,7 +651,7 @@ void CGameTeams::OnFinish(CPlayer *Player, float Time, const char *pTimestamp)
}
Server()->SendPackMsg(&Msg, MSGFLAG_VITAL, ClientID);
if(!Server()->IsSixup(ClientID) && VERSION_DDRACE <= Player->GetClientVersion() && Player->GetClientVersion() <= VERSION_DDNET_MSG_LEGACY)
if(!Server()->IsSixup(ClientID) && VERSION_DDRACE <= Player->GetClientVersion() && Player->GetClientVersion() < VERSION_DDNET_MSG_LEGACY)
{
Server()->SendPackMsg(&MsgLegacy, MSGFLAG_VITAL, ClientID);
}