Breath cheat fix: server side 4978/head
authorLoic Blot <loic.blot@unix-experience.fr>
Sun, 1 Jan 2017 15:13:01 +0000 (16:13 +0100)
committerLoic Blot <loic.blot@unix-experience.fr>
Sun, 1 Jan 2017 22:11:26 +0000 (23:11 +0100)
commit52ba1f867e5edb579a59a44fbb8286d4f1e54931
treed95e2032d3fcf18bd972cc018e6b44470664d75c
parenta1346c916e1d0f0cde2ccecc680857896c717a3d
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
13 files changed:
src/client.cpp
src/content_sao.cpp
src/content_sao.h
src/environment.cpp
src/network/clientopcodes.cpp
src/network/networkprotocol.h
src/network/serveropcodes.cpp
src/network/serverpackethandler.cpp
src/remoteplayer.cpp
src/script/lua_api/l_object.cpp
src/server.cpp
src/server.h
src/unittest/test_player.cpp