Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ovu komandu sam dodo pod staru /invite
- if(strcmp(cmd, "/invite", true) == 0)
- {
- if(IsPlayerConnected(playerid))
- {
- tmp = strtok(cmdtext, idx);
- if(!strlen(tmp))
- {
- SendClientMessage(playerid, COLOR_WHITE, "{6EF83C}INFO:{FFFFFF}/invite [ID/Ime na Igrac]");
- return 1;
- }
- giveplayerid = ReturnUser(tmp);
- if(IsPlayerConnected(giveplayerid))
- {
- if(giveplayerid != INVALID_PLAYER_ID)
- {
- if(ProxDetectorS(3.0, playerid, giveplayerid))
- {
- if (PlayerInfo[playerid][pLeader] >= 1)
- {
- new sendername[MAX_PLAYER_NAME];
- GetPlayerName(playerid, sendername, sizeof(sendername));
- GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
- new string[261];
- format(string, sizeof(string),"\nJas: %s te pokanuvam da rabotis za mene i da bides moj clen.\nDokolku Prifakjas pristisni 'Prifakjam'\nDokolku Odbivas pritisni 'Odbivam'\nDokolku se predomislis pobaraj me na Tel.Broj %d", sendername,broj);
- ShowPlayerDialog(giveplayerid, DIALOG_POKANA, DIALOG_STYLE_MSGBOX, "Pokana za Clenstvo", string, "Prifakjam","Odbivam");
- format(string, sizeof(string), "%s go pokanuva igracot %s da bide negov clen", sendername, giveplayer);
- printf("%s go pokanuva igracot %s da bide negov clen.", sendername, giveplayer);
- ProxDetector(10.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
- Pokana[giveplayerid] = 1;
- Pokanet[giveplayerid] = 1;
- Pokanuvac[giveplayerid] = playerid;
- Invite[giveplayerid] = PlayerInfo[playerid][pLeader];
- return 1;
- }
- }
- }
- }
- }
- return 1;
- }
- ovo pod OnDialogResponse
- if(dialogid == DIALOG_POKANA)
- {
- if(response)
- {
- if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 1) { PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; ftext = "PD"; ChosenSkin[playerid] = 282; SetPlayerSkin(playerid, 282); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 2) { PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; ftext = "MBI"; ChosenSkin[playerid] = 24; SetPlayerSkin(playerid, 24); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 3) { PlayerInfo[playerid][pTeam] = 1; gTeam[playerid] = 1; ftext = "ARM"; ChosenSkin[playerid] = 285; SetPlayerSkin(playerid, 285); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 4) { PlayerInfo[playerid][pTeam] = 1; gTeam[playerid] = 1; ftext = "MD"; ChosenSkin[playerid] = 276; SetPlayerSkin(playerid, 276); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 5) { PlayerInfo[playerid][pTeam] = 6; gTeam[playerid] = 6; ftext = "Yakuza"; ChosenSkin[playerid] = 121; SetPlayerSkin(playerid, 121); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 6) { PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; ftext = "LCN"; ChosenSkin[playerid] = 112; SetPlayerSkin(playerid, 112); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 7) { PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; ftext = "Vlada"; ChosenSkin[playerid] = 164; SetPlayerSkin(playerid, 164); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 8) { PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; ftext = "Hitman"; ChosenSkin[playerid] = 20; SetPlayerSkin(playerid, 20); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 9) { PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; ftext = "Kanal 7"; ChosenSkin[playerid] = 1; SetPlayerSkin(playerid, 1); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 10) { PlayerInfo[playerid][pTeam] = 15; gTeam[playerid] = 15; ftext = "Taxi"; ChosenSkin[playerid] = 210; SetPlayerSkin(playerid, 210); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 11) { PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; ftext = "LSG"; ChosenSkin[playerid] = 175; SetPlayerSkin(playerid, 175); }
- else if(PlayerInfo[Pokanuvac[playerid]][pLeader] == 12) { PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; ftext = "GSF"; ChosenSkin[playerid] = 105; SetPlayerSkin(playerid, 105); }
- GetPlayerName(playerid, sendername, sizeof(sendername));
- PlayerInfo[playerid][pMember] = PlayerInfo[Pokanuvac[playerid]][pLeader];
- PlayerInfo[playerid][pRank] = 1;
- format(string, sizeof(string), "%s ja prifati ponudata za clenstvo.", sendername);
- ProxDetector(10.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
- Pokana[playerid] = 1;
- SacuvajIgraca(playerid)
- }
- else
- {
- GetPlayerName(playerid, sendername, sizeof(sendername));
- format(string, sizeof(string), "%s ja odbi ponudata za clenstvo.", sendername);
- ProxDetector(10.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
- Pokana[playerid] = 0;
- SacuvajIgraca(playerid)
- }
- i ovo kod new .
- new Invite[MAX_PLAYERS];
- new Pokanet[MAX_PLAYERS];
- new Pokanuvac[MAX_PLAYERS];
- new Pokana[MAX_PLAYERS];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement