How to do this..??? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: How to do this..??? (
/showthread.php?tid=181123)
How to do this..??? -
eixas10000 - 04.10.2010
..
went gteam = 3; kill gteam = 3;
Point + 1
and
how to
make command for check Kill Point?
Sorry I'm English not good
Re: How to do this..??? -
Crashty - 04.10.2010
I'm not sure what you really want, this MAY work:
pawn Код:
#include <a_samp>
#include "../include/gl_common.inc"
new Team1Score;
new Team2Score;
new gTeam[MAX_PLAYERS];
public OnPlayerDeath(playerid,killerid,reason)
{
SetPlayerScore(killerid,(GetPlayerScore(playerid)) +1); // Gives the player 1 point
if(gTeam[killerid] == 1)
{
Team1Score ++; // Gives the team 1 score
}
else
{
Team2Score ++; // Gives the team 1 score
}
return 1;
}
public OnPlayerCommandText(playerid,cmdtext[])
{
new Text[256];
new Text2[256];
new cmd[256];
new idx;
cmd = strtok(cmdtext,idx);
if(strcmp(cmd,"/Score",true)==0)
{
format(Text,sizeof(Text),"Team one's score: %d",Team1Score);
format(Text2,sizeof(Text2),"Team two's Score: %d",Team2Score);
SendClientMessage(playerid,0xAFAFAFF,Text);
SendClientMessage(playerid,0xAFAFAFF,Text2);
return 1;
}
return 1;
}
it will give the player 1 score, the team will get 1 score too..
You should edit that code btw..