[Patch] Drowning Fix
Posted: Sun May 30, 2010 11:48 am
This fixes the issue where you continue to drown even after leaving the water or swimming to the top. Tested before and after the change on my server. Also went to another public server to verify the problem existed there. The problem was that the GetDrowningVictim function was not returning the correct value.
Code: Select all
--- zoneserver.cpp (revision 437)
+++ zoneserver.cpp (working copy)
@@ -1078,7 +1078,7 @@
Client* ZoneServer::GetDrowningVictim(Player* player){
Client* client = GetClientBySpawn(player);
- if(client && drowning_victims.count(client) == 0)
+ if(client && drowning_victims.count(client) > 0)
return(client);
return 0;
}