1

Topic: changing team resets score to 0

hi there, thanks for such a completely awesome game!

i hope it's not presumptuous of me to be reporting this as a 'bug' but i checked in the development forum here :

http://teeworlds.com/forum/viewtopic.php?id=1989

and the general consensus is that there is no reason why an individual's score should be reset to 0 when they change team, especially as the team score is kept (and scored) separate from the individual scores anyway.

i think this would aid the team-unbalancing problem, since people might be more likely to change team mid-match if there was no real penalty smile

2 (edited by GSGDani 2008-08-28 19:02:38)

Re: changing team resets score to 0

use scosus mods.. for example race mod.. if you change the team your score is the same than before wink;);)

*edit*
Race Mod

Remember me? Questions? Just leave a message, I will respond within 72 hrs!

3 (edited by sengoku 2008-08-30 00:28:24)

Re: changing team resets score to 0

thanks, but it shouldn't need a mod should it?

here's a simple patch to fix it (against latest svn) smile

Index: src/game/server/player.cpp
===================================================================
--- src/game/server/player.cpp    (revision 1436)
+++ src/game/server/player.cpp    (working copy)
@@ -15,6 +15,7 @@
     mem_zero(this, sizeof(*this));
     new(this) PLAYER();
     this->client_id = client_id;
+    score = 0;
 }
 
 void PLAYER::tick()
@@ -132,7 +133,6 @@
     
     kill_character();
     team = new_team;
-    score = 0;
     dbg_msg("game", "team_join player='%d:%s' team=%d", client_id, server_clientname(client_id), team);
     
     game.controller->on_player_info_change(&game.players[client_id]);

(edited to set score to 0 on init, probably not needed since mem_zero takes care of it anyway)