Skip to content

Commit

Permalink
Fix bad FINAL_VERSION checks
Browse files Browse the repository at this point in the history
  • Loading branch information
kaetemi committed Feb 21, 2023
1 parent 628f8cd commit c067b93
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion nel/include/nel/net/transport_class.h
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,7 @@ inline NLNET::CMessage &CTransportClass::write ()
nlassert (Init);
nlassert (Mode == 0);

#ifndef FINAL_VERSION
#if !FINAL_VERSION
// Did the programmer forget to register the transport class? Forbid sending then.
nlassert( LocalRegisteredClass.find( className() ) != LocalRegisteredClass.end() );
#endif
Expand Down
4 changes: 2 additions & 2 deletions ryzom/common/src/game_share/simlag.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ void sendUDP (CUdpSock *client, const uint8 *packet, uint32 packetSize, const CI
nlassert (packet != NULL);
nlassert (packetSize > 0);

#ifdef FINAL_VERSION
#if !FINAL_VERSION
if ((float)rand()/(float)(RAND_MAX)*100.0f >= PacketLoss)
{
sint32 lag = Lag /*+ (rand()%40) - 20*/;// void disordering
Expand Down Expand Up @@ -201,7 +201,7 @@ void sendUDP (CUdpSock *client, const uint8 *packet, uint32 packetSize, const CI
{
sendUDPNow (client, packet, packetSize, addr);
}
#ifdef FINAL_VERSION
#if !FINAL_VERSION
}
}
#endif
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ inline const NLMISC::CEntityId& CAIAliasTranslator::getEntityId(TAIAlias aiid) c
CHashMap< uint, NLMISC::CEntityId >::const_iterator it = _HashTableAiId.find(aiid);
if( it != _HashTableAiId.end() )
return (*it).second;
#ifndef FINAL_VERSION
#if !FINAL_VERSION
nlerror( "Illegal call to getEntityId on entity with no alias" ); // see
#endif
return NLMISC::CEntityId::Unknown;
Expand Down

0 comments on commit c067b93

Please sign in to comment.