Breath cheat fix: server side
Breath is now handled server side. Changing this behaviour required some modifications to core: * Ignore TOSERVER_BREATH package, marking it as obsolete * Clients doesn't send the breath to server anymore * Use PlayerSAO pointer instead of peer_id in Server::SendPlayerBreath to prevent a useless lookup (little perf gain) * drop a useless static_cast in emergePlayer
This commit is contained in:
@@ -148,7 +148,7 @@ void RemotePlayer::deSerialize(std::istream &is, const std::string &playername,
|
||||
} catch (SettingNotFoundException &e) {}
|
||||
|
||||
try {
|
||||
sao->setBreath(args.getS32("breath"));
|
||||
sao->setBreath(args.getS32("breath"), false);
|
||||
} catch (SettingNotFoundException &e) {}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user