Refuses the count score
#3

Quote:
Originally Posted by Backwardsman97
View Post
Here you go man.

http://pastebin.com/NrUf18RD

I got rid of the timers because there is no need. It's a lot more efficient to just update the scores under OnPlayerDeath since that is the only time when they would change. I also fixed a few logic errors such as this one:

pawn Code:
if ( killerid == TEAM_NBG )

//Should be

if ( gTeam[killerid] == TEAM_NBG )
Because killerid is the id of the player who killed the other player. So you don't need to see if his id matches TEAM_NBG but if his gTeam variable matches it. And the reason the textdraws weren't updating is because you were formating them with %s which means string. You needed to be using %d for integer. Compiled fine and should be ready go now. Have fun.
Thanks for "cleaning" up the mess in it! However, I just tested it and when I kill my enemy one of the textdraws disappears, and when I get killed the second textdraw disappears too. :/
Reply


Messages In This Thread
Refuses to count score - by erxaz - 03.04.2011, 22:02
Re: Refuses the count score - by Backwardsman97 - 03.04.2011, 22:34
Re: Refuses the count score - by erxaz - 03.04.2011, 22:44
Re: Refuses the count score - by Backwardsman97 - 03.04.2011, 22:54
Re: Refuses the count score - by erxaz - 03.04.2011, 23:16
Re: Refuses the count score - by Backwardsman97 - 03.04.2011, 23:32

Forum Jump:


Users browsing this thread: 1 Guest(s)