[Pomoc]Komanda /warpozovi [ID] i /warizbaci [ID]

Započeo Dane, Januar 03, 2012, 18:18:35 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:Noxicus
Detaljan opis problema:Znači kao Å¡ta naslov teme govori htio bh znate ako mi možete kazati kako da napravim komande te dvi.One bi trebale raditi sljedeće:Znači kada admin pokrene war komandom /zapocnirat da lideri koje je admin mafije/bande (2) odabrao da komandom /warpozovi [ID] portaju igraca na war a ako npr. neki igrac izaÄ'e sa servera upo wara a ima ostalih igraca online da onda njega portaju na war ili nekoga od ovih izbace sa komandom /warizbaci pa pozovu drugog online clana...Nadam se da ste me skontali.
Dio skripte:Evo vam komanda /zapocnirat pa vi od tge komande stavite da ne porta sve odma 2 ekipe nego da lider mora:
CMD:zapocnirat(playerid, params[])
{
new tim1,tim2,vrijemez, string[128];
new sendername[MAX_PLAYER_NAME];
GetPlayerName(playerid, sendername, sizeof(sendername));
if(sscanf(params, "ddd", tim1, tim2, vrijemez))
{
if(PlayerInfo[playerid][pAdmin] >= 2)
{
SCM(playerid, COLOR_GRAD3,"{168BFF}INFO: {959561} /zapocnirat [tim1] [tim2] [vrijeme(minute)]");
SCM(playerid, WHITE, "{FF0000}Dostupno: {FFFF80}5 - LCN | 6- Yakuza | 12-MS13 | 13 - Crips");
}
}
else
{
if(PlayerInfo[playerid][pAdmin] >= 2)
{
foreach (Player, i)
{
     if(PlayerInfo[i][pMember] == tim1 || PlayerInfo[i][pLeader] == tim1)
     {

SetPVarInt(i, "Ratuje", 1); SetPVarInt(i, "Tim1", 1);
new Float:fa, Float:fy, Float:fu;
GetPlayerPos( playerid, fa, fy, fu );
format(string, sizeof(string), "{FF0000}RAT| Pokrenuo Admin: {FFFF80}%s", sendername);SCM(i, WHITE, string);
ratnitext1 = CreatePlayer3DTextLabel(i,"{0080C0}Plavi {808080}Tim",0x46A3FFFF,fa,fy,fu,40.0, i);
SetPlayerInterior(i, 15);
new rande = random(sizeof(RandomArenaSpawnsTim1));
SetPlayerPos(i, RandomArenaSpawnsTim1[rande][0], RandomArenaSpawnsTim1[rande][1], RandomArenaSpawnsTim1[rande][2]);
GivePlayerWeapon(i, 4, 2);GivePlayerWeapon(i, 18, 50);GivePlayerWeapon(i, 24, 120);GivePlayerWeapon(i, 25, 120);GivePlayerWeapon(i, 29, 200);
GivePlayerWeapon(i, 33, 100);RatnoVrijeme = vrijemez*60;TextDrawShowForPlayer(i, crvenitim);plavitimkills= 0; crvenitimkills = 0;
TextDrawShowForPlayer(i, plavitim);
TextDrawShowForPlayer(i, ratnaz);
TextDrawShowForPlayer(i, preostalovrijeme);
 }
 if(PlayerInfo[i][pMember] == tim2 ||PlayerInfo[i][pLeader] == tim2)
{

SetPVarInt(i, "Ratuje", 1); SetPVarInt(i, "Tim2", 1);
SetPlayerInterior(i, 15);
new Float:fa, Float:fy, Float:fu;
GetPlayerPos( playerid, fa, fy, fu );format(string, sizeof(string), "{FF0000}RAT| Pokrenuo Admin: {FFFF80}%s", sendername);SCM(i, WHITE, string);
ratnitext2 = CreatePlayer3DTextLabel(i,"{FF4141}Crveni {808080}Tim",0xFF5E5EFF,fa,fy,fu,40.0, i);plavitimkills= 0; crvenitimkills = 0;
new rande = random(sizeof(RandomArenaSpawnsTim2));
RatnoVrijeme = vrijemez *60;
SetPlayerPos(i, RandomArenaSpawnsTim2[rande][0], RandomArenaSpawnsTim2[rande][1], RandomArenaSpawnsTim2[rande][2]);
GivePlayerWeapon(i, 4, 2);GivePlayerWeapon(i, 18, 50);GivePlayerWeapon(i, 24, 120);GivePlayerWeapon(i, 25, 120);GivePlayerWeapon(i, 29, 200);
GivePlayerWeapon(i, 33, 100);
TextDrawShowForPlayer(i, crvenitim);
TextDrawShowForPlayer(i, plavitim);
TextDrawShowForPlayer(i, ratnaz);
TextDrawShowForPlayer(i, preostalovrijeme);
}
}
 }
}
return 1;
}

Definicije:
new RatnoVrijeme = 0;
new plavitimkills = 0;
new crvenitimkills = 0;
new PlayerText3D:ratnitext2;
new PlayerText3D:ratnitext1;
new Text:crvenitim;
new Text:plavitim;
new Text:ratnaz;
new Text:preostalovrijeme;
SetPVarInt(playerid, "Ratuje", 0);

public SetPlayerSpawn(playerid)
{
if(GetPVarInt(playerid, "Ratuje") == 1)
{
if(GetPVarInt(playerid, "Tim1") == 1)
{
SetPlayerInterior(playerid, 15);
new rande = random(sizeof(RandomArenaSpawnsTim1));
//SetSpawnInfo(playerid, PlayerInfo[playerid][pTeam], PlayerInfo[playerid][pChar], RandomArenaSpawnsTim1[rande][0], RandomArenaSpawnsTim1[rande][1], RandomArenaSpawnsTim1[rande][2], 0.0, 4, 2, 18, 50, 29, 200)
SetPlayerPos(playerid, RandomArenaSpawnsTim1[rande][0], RandomArenaSpawnsTim1[rande][1], RandomArenaSpawnsTim1[rande][2]);
GivePlayerWeapon(playerid, 4, 2);GivePlayerWeapon(playerid, 18, 50);GivePlayerWeapon(playerid, 24, 120);GivePlayerWeapon(playerid, 25, 120);GivePlayerWeapon(playerid, 29, 200);
GivePlayerWeapon(playerid, 33, 100);
return 1;
}
else if(GetPVarInt(playerid, "Tim2") == 1)
{
SetPlayerInterior(playerid, 15);
new rande = random(sizeof(RandomArenaSpawnsTim2));
SetPlayerPos(playerid, RandomArenaSpawnsTim2[rande][0], RandomArenaSpawnsTim2[rande][1], RandomArenaSpawnsTim2[rande][2]);
GivePlayerWeapon(playerid, 4, 2);GivePlayerWeapon(playerid, 18, 50);GivePlayerWeapon(playerid, 24, 120);GivePlayerWeapon(playerid, 25, 120);GivePlayerWeapon(playerid, 29, 200);
GivePlayerWeapon(playerid, 33, 100);
return 1;
}
}

if(GetPVarInt(i, "Ratuje") == 1 && RatnoVrijeme != 0)
{

format(string, sizeof(string), "~g~Preostalo vrijeme:~b~%d sec", RatnoVrijeme);
TextDrawSetString(preostalovrijeme,string);
format(string, sizeof(string), "~r~Crveni tim:~b~%d", crvenitimkills);
TextDrawSetString(crvenitim, string);
format(string, sizeof(string), "~r~Plavi tim:~b~%d", plavitimkills);
TextDrawSetString(plavitim, string);
}
if(GetPVarInt(i, "Ratuje") == 1 && RatnoVrijeme <= 0)
{
DeletePlayer3DTextLabel(i, ratnitext1);DeletePlayer3DTextLabel(i, ratnitext2);SetPVarInt(i, "Tim1", 0);SetPVarInt(i, "Tim2", 0);
SetPVarInt(i, "Ratuje", 0); ResetPlayerWeapons(i); SpawnPlayer(i); TextDrawHideForPlayer(i, ratnaz);
TextDrawHideForPlayer(i, preostalovrijeme);TextDrawHideForPlayer(i, crvenitim);TextDrawHideForPlayer(i, plavitim);
}

RatnoVrijeme = strval(arrCoords[4]);

crvenitim = TextDrawCreate(25.000000, 238.000000, "~r~Crveni tim:~b~0");
TextDrawBackgroundColor(crvenitim, 255);
TextDrawFont(crvenitim, 1);
TextDrawLetterSize(crvenitim, 0.410000, 2.000000);
TextDrawColor(crvenitim, -1);
TextDrawSetOutline(crvenitim, 1);
TextDrawSetProportional(crvenitim, 1);
TextDrawUseBox(crvenitim, 1);
TextDrawBoxColor(crvenitim, 64);
TextDrawTextSize(crvenitim, 137.000000, 0.000000);

plavitim = TextDrawCreate(25.000000, 260.500000, "~b~Plavi tim:~r~0");
TextDrawBackgroundColor(plavitim, 255);
TextDrawFont(plavitim, 1);
TextDrawLetterSize(plavitim, 0.410000, 2.000000);
TextDrawColor(plavitim, -1);
TextDrawSetOutline(plavitim, 1);
TextDrawSetProportional(plavitim, 1);
TextDrawUseBox(plavitim, 1);
TextDrawBoxColor(plavitim, 64);
TextDrawTextSize(plavitim, 137.000000, 0.000000);

ratnaz = TextDrawCreate(59.000000, 214.000000, "~g~Rat");
TextDrawBackgroundColor(ratnaz, 255);
TextDrawFont(ratnaz, 0);
TextDrawLetterSize(ratnaz, 0.700000, 2.100000);
TextDrawColor(ratnaz, -1);
TextDrawSetOutline(ratnaz, 1);
TextDrawSetProportional(ratnaz, 1);
TextDrawUseBox(ratnaz, 1);
TextDrawBoxColor(ratnaz, 64);
TextDrawTextSize(ratnaz, 94.000000, 0.000000);

preostalovrijeme = TextDrawCreate(25.000000, 283.000000, "~g~Preostalo vrijeme:~b~120 sec");
TextDrawBackgroundColor(preostalovrijeme, 255);
TextDrawFont(preostalovrijeme, 1);
TextDrawLetterSize(preostalovrijeme, 0.310000, 1.700000);
TextDrawColor(preostalovrijeme, -1);
TextDrawSetOutline(preostalovrijeme, 1);
TextDrawSetProportional(preostalovrijeme, 1);
TextDrawUseBox(preostalovrijeme, 1);
TextDrawBoxColor(preostalovrijeme, 64);
TextDrawTextSize(preostalovrijeme, 137.000000, 0.000000);
oglasis = SetTimer("RandomMessage",20000,1);


Neke slike/video za lakse dobivanje pomoci(neobavezno)://

OVO U KODU NIJE SVE JEDNA KOMANDA TO JE SVE VEZANO ZA WAR  Å TO SAM NAÅ AO U GAMEMODU!!!
Poslednja Izmena: Januar 03, 2012, 18:26:05 POSLE PODNE od Dane

Citat: Dane poslato Januar 03, 2012, 18:18:35 POSLE PODNE
Skripta koju koristim:Noxicus
Detaljan opis problema:Znači kao Å¡ta naslov teme govori htio bh znate ako mi možete kazati kako da napravim komande te dvi.One bi trebale raditi sljedeće:Znači kada admin pokrene war komandom /zapocnirat da lideri koje je admin mafije/bande (2) odabrao da komandom /warpozovi [ID] portaju igraca na war a ako npr. neki igrac izaÄ'e sa servera upo wara a ima ostalih igraca online da onda njega portaju na war ili nekoga od ovih izbace sa komandom /warizbaci pa pozovu drugog online clana...Nadam se da ste me skontali.
Dio skripte:Evo vam komanda /zapocnirat pa vi od tge komande stavite da ne porta sve odma 2 ekipe nego da lider mora:
CMD:zapocnirat(playerid, params[])
{
new tim1,tim2,vrijemez, string[128];
new sendername[MAX_PLAYER_NAME];
GetPlayerName(playerid, sendername, sizeof(sendername));
if(sscanf(params, "ddd", tim1, tim2, vrijemez))
{
if(PlayerInfo[playerid][pAdmin] >= 2)
{
SCM(playerid, COLOR_GRAD3,"{168BFF}INFO: {959561} /zapocnirat [tim1] [tim2] [vrijeme(minute)]");
SCM(playerid, WHITE, "{FF0000}Dostupno: {FFFF80}5 - LCN | 6- Yakuza | 12-MS13 | 13 - Crips");
}
}
else
{
if(PlayerInfo[playerid][pAdmin] >= 2)
{
foreach (Player, i)
{
     if(PlayerInfo[i][pMember] == tim1 || PlayerInfo[i][pLeader] == tim1)
     {

SetPVarInt(i, "Ratuje", 1); SetPVarInt(i, "Tim1", 1);
new Float:fa, Float:fy, Float:fu;
GetPlayerPos( playerid, fa, fy, fu );
format(string, sizeof(string), "{FF0000}RAT| Pokrenuo Admin: {FFFF80}%s", sendername);SCM(i, WHITE, string);
ratnitext1 = CreatePlayer3DTextLabel(i,"{0080C0}Plavi {808080}Tim",0x46A3FFFF,fa,fy,fu,40.0, i);
SetPlayerInterior(i, 15);
new rande = random(sizeof(RandomArenaSpawnsTim1));
SetPlayerPos(i, RandomArenaSpawnsTim1[rande][0], RandomArenaSpawnsTim1[rande][1], RandomArenaSpawnsTim1[rande][2]);
GivePlayerWeapon(i, 4, 2);GivePlayerWeapon(i, 18, 50);GivePlayerWeapon(i, 24, 120);GivePlayerWeapon(i, 25, 120);GivePlayerWeapon(i, 29, 200);
GivePlayerWeapon(i, 33, 100);RatnoVrijeme = vrijemez*60;TextDrawShowForPlayer(i, crvenitim);plavitimkills= 0; crvenitimkills = 0;
TextDrawShowForPlayer(i, plavitim);
TextDrawShowForPlayer(i, ratnaz);
TextDrawShowForPlayer(i, preostalovrijeme);
 }
 if(PlayerInfo[i][pMember] == tim2 ||PlayerInfo[i][pLeader] == tim2)
{

SetPVarInt(i, "Ratuje", 1); SetPVarInt(i, "Tim2", 1);
SetPlayerInterior(i, 15);
new Float:fa, Float:fy, Float:fu;
GetPlayerPos( playerid, fa, fy, fu );format(string, sizeof(string), "{FF0000}RAT| Pokrenuo Admin: {FFFF80}%s", sendername);SCM(i, WHITE, string);
ratnitext2 = CreatePlayer3DTextLabel(i,"{FF4141}Crveni {808080}Tim",0xFF5E5EFF,fa,fy,fu,40.0, i);plavitimkills= 0; crvenitimkills = 0;
new rande = random(sizeof(RandomArenaSpawnsTim2));
RatnoVrijeme = vrijemez *60;
SetPlayerPos(i, RandomArenaSpawnsTim2[rande][0], RandomArenaSpawnsTim2[rande][1], RandomArenaSpawnsTim2[rande][2]);
GivePlayerWeapon(i, 4, 2);GivePlayerWeapon(i, 18, 50);GivePlayerWeapon(i, 24, 120);GivePlayerWeapon(i, 25, 120);GivePlayerWeapon(i, 29, 200);
GivePlayerWeapon(i, 33, 100);
TextDrawShowForPlayer(i, crvenitim);
TextDrawShowForPlayer(i, plavitim);
TextDrawShowForPlayer(i, ratnaz);
TextDrawShowForPlayer(i, preostalovrijeme);
}
}
 }
}
return 1;
}

Definicije:
new RatnoVrijeme = 0;
new plavitimkills = 0;
new crvenitimkills = 0;
new PlayerText3D:ratnitext2;
new PlayerText3D:ratnitext1;
new Text:crvenitim;
new Text:plavitim;
new Text:ratnaz;
new Text:preostalovrijeme;
SetPVarInt(playerid, "Ratuje", 0);

public SetPlayerSpawn(playerid)
{
if(GetPVarInt(playerid, "Ratuje") == 1)
{
if(GetPVarInt(playerid, "Tim1") == 1)
{
SetPlayerInterior(playerid, 15);
new rande = random(sizeof(RandomArenaSpawnsTim1));
//SetSpawnInfo(playerid, PlayerInfo[playerid][pTeam], PlayerInfo[playerid][pChar], RandomArenaSpawnsTim1[rande][0], RandomArenaSpawnsTim1[rande][1], RandomArenaSpawnsTim1[rande][2], 0.0, 4, 2, 18, 50, 29, 200)
SetPlayerPos(playerid, RandomArenaSpawnsTim1[rande][0], RandomArenaSpawnsTim1[rande][1], RandomArenaSpawnsTim1[rande][2]);
GivePlayerWeapon(playerid, 4, 2);GivePlayerWeapon(playerid, 18, 50);GivePlayerWeapon(playerid, 24, 120);GivePlayerWeapon(playerid, 25, 120);GivePlayerWeapon(playerid, 29, 200);
GivePlayerWeapon(playerid, 33, 100);
return 1;
}
else if(GetPVarInt(playerid, "Tim2") == 1)
{
SetPlayerInterior(playerid, 15);
new rande = random(sizeof(RandomArenaSpawnsTim2));
SetPlayerPos(playerid, RandomArenaSpawnsTim2[rande][0], RandomArenaSpawnsTim2[rande][1], RandomArenaSpawnsTim2[rande][2]);
GivePlayerWeapon(playerid, 4, 2);GivePlayerWeapon(playerid, 18, 50);GivePlayerWeapon(playerid, 24, 120);GivePlayerWeapon(playerid, 25, 120);GivePlayerWeapon(playerid, 29, 200);
GivePlayerWeapon(playerid, 33, 100);
return 1;
}
}

if(GetPVarInt(i, "Ratuje") == 1 && RatnoVrijeme != 0)
{

format(string, sizeof(string), "~g~Preostalo vrijeme:~b~%d sec", RatnoVrijeme);
TextDrawSetString(preostalovrijeme,string);
format(string, sizeof(string), "~r~Crveni tim:~b~%d", crvenitimkills);
TextDrawSetString(crvenitim, string);
format(string, sizeof(string), "~r~Plavi tim:~b~%d", plavitimkills);
TextDrawSetString(plavitim, string);
}
if(GetPVarInt(i, "Ratuje") == 1 && RatnoVrijeme <= 0)
{
DeletePlayer3DTextLabel(i, ratnitext1);DeletePlayer3DTextLabel(i, ratnitext2);SetPVarInt(i, "Tim1", 0);SetPVarInt(i, "Tim2", 0);
SetPVarInt(i, "Ratuje", 0); ResetPlayerWeapons(i); SpawnPlayer(i); TextDrawHideForPlayer(i, ratnaz);
TextDrawHideForPlayer(i, preostalovrijeme);TextDrawHideForPlayer(i, crvenitim);TextDrawHideForPlayer(i, plavitim);
}

RatnoVrijeme = strval(arrCoords[4]);

crvenitim = TextDrawCreate(25.000000, 238.000000, "~r~Crveni tim:~b~0");
TextDrawBackgroundColor(crvenitim, 255);
TextDrawFont(crvenitim, 1);
TextDrawLetterSize(crvenitim, 0.410000, 2.000000);
TextDrawColor(crvenitim, -1);
TextDrawSetOutline(crvenitim, 1);
TextDrawSetProportional(crvenitim, 1);
TextDrawUseBox(crvenitim, 1);
TextDrawBoxColor(crvenitim, 64);
TextDrawTextSize(crvenitim, 137.000000, 0.000000);

plavitim = TextDrawCreate(25.000000, 260.500000, "~b~Plavi tim:~r~0");
TextDrawBackgroundColor(plavitim, 255);
TextDrawFont(plavitim, 1);
TextDrawLetterSize(plavitim, 0.410000, 2.000000);
TextDrawColor(plavitim, -1);
TextDrawSetOutline(plavitim, 1);
TextDrawSetProportional(plavitim, 1);
TextDrawUseBox(plavitim, 1);
TextDrawBoxColor(plavitim, 64);
TextDrawTextSize(plavitim, 137.000000, 0.000000);

ratnaz = TextDrawCreate(59.000000, 214.000000, "~g~Rat");
TextDrawBackgroundColor(ratnaz, 255);
TextDrawFont(ratnaz, 0);
TextDrawLetterSize(ratnaz, 0.700000, 2.100000);
TextDrawColor(ratnaz, -1);
TextDrawSetOutline(ratnaz, 1);
TextDrawSetProportional(ratnaz, 1);
TextDrawUseBox(ratnaz, 1);
TextDrawBoxColor(ratnaz, 64);
TextDrawTextSize(ratnaz, 94.000000, 0.000000);

preostalovrijeme = TextDrawCreate(25.000000, 283.000000, "~g~Preostalo vrijeme:~b~120 sec");
TextDrawBackgroundColor(preostalovrijeme, 255);
TextDrawFont(preostalovrijeme, 1);
TextDrawLetterSize(preostalovrijeme, 0.310000, 1.700000);
TextDrawColor(preostalovrijeme, -1);
TextDrawSetOutline(preostalovrijeme, 1);
TextDrawSetProportional(preostalovrijeme, 1);
TextDrawUseBox(preostalovrijeme, 1);
TextDrawBoxColor(preostalovrijeme, 64);
TextDrawTextSize(preostalovrijeme, 137.000000, 0.000000);
oglasis = SetTimer("RandomMessage",20000,1);


Neke slike/video za lakse dobivanje pomoci(neobavezno)://

OVO U KODU NIJE SVE JEDNA KOMANDA TO JE SVE VEZANO ZA WAR  Å TO SAM NAÅ AO U GAMEMODU!!!


to sam i ja jedno vrijeme trazio,..


Ali slusaj, sto se tice /warizbaci mozes ti /kick-at igraca sa servera, pa je ta warizbaci nepotrebna...


Pa ako ovo netko znam nek pomgne, bio bih vam zahvalan

Pa dobro onda ali ja hoću te dvi komande ili samo /warpozovi [ID].

Napravi nesto i sam nemoze nista na tanjiru ..
/warprozovitim1 [ID/dio imena] stavis ovako i onda napravis varijablu za npr pTim1
/warprozovitim2 [ID/dio  imena] i opet napravis varijablu pTIm2

i onda samo gdje ti pise ovo
if(PlayerInfo[pMember] == tim1 || PlayerInfo[pLeader] == tim1)

stavis sebi
if(PlayerInfo[pTim1] == tim1)

i eto to je to bas lako ... ali necete razmisljat