"Trebam nešto" - tema

Započeo Correlli, Jul 30, 2010, 15:11:25 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 27 gostiju pregledaju ovu temu.


Citat: Darko a.k.a OptX poslato Jul 03, 2011, 17:18:01 POSLE PODNE
Citat: [TG]$--L84S--$ poslato Jul 03, 2011, 16:31:29 POSLE PODNE
Citat: Darko a.k.a OptX poslato Jul 02, 2011, 15:00:18 POSLE PODNE
Citat: Darko a.k.a OptX poslato Jul 02, 2011, 11:07:10 PRE PODNE
Trazim komandu /naruci(za kafic)

Hoce mi ko odg ?
Zcmd il strcmp ??

A sta je to? xD
Evo primjer
ZCMD ti je ovo :
//dcmd: 
dcmd_suicide(playerid, params[]) 
//zcmd: 
CMD:suicide(playerid, params[]) 

a strcmp :
if( !strcmp( cmdtext, "/suicide", true )) 
e sad koji ti radis ?

@pHon ti trebas port  dobis uskoro evo nseto da nbrzinu cu slozit.?



Citat: pHon poslato Jul 03, 2011, 17:28:47 POSLE PODNE
dada /port,hvala ti.
evo napravio nesto nabrzinu u dialogu znaci ti dodaj jos mjesta ako zelis i samo stavi svoje kordinate :
if(strcmp("/port", cmdtext, true, 10) == 0)
{
if (PlayerInfo[playerid][pAdmin] >= 1)
{
ShowPlayerDialog(playerid, 51, DIALOG_STYLE_LIST, "Teleport", "Burg \nSpawn \nBanka \nKolodvor \nVineWood \nBurg(Marina) ", "U redu", "Odustani");
return 1;
}
else
{
           SendClientMessage(playerid, COLOR_GREEN, "Nisi ovlasten.");
   return 1;
}
}


Pod public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
stavis jos daloge :


if(dialogid == 51)
{
if(response)
{
if(listitem == 0) // Burg
{
if (GetPlayerState(playerid) == 2)
       {
new tmpcar = GetPlayerVehicleID(playerid);
SetVehiclePos(tmpcar,x,y,z);
TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
}
else
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerPos(playerid, x,y,z);
PlayerInfo[playerid][pInt] = 0;
}
}
if(listitem == 1) // Spawn
{
if (GetPlayerState(playerid) == 2)
       {
new tmpcar = GetPlayerVehicleID(playerid);
SetVehiclePos(tmpcar, x,y,z);
TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
}
else
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerPos(playerid, x,y,z);
PlayerInfo[playerid][pInt] = 0;
}
}
if(listitem == 2) // banka
{
if (GetPlayerState(playerid) == 2)
       {
new tmpcar = GetPlayerVehicleID(playerid);
SetVehiclePos(tmpcar, x,y,z);
TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
}
else
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerPos(playerid, x,y,z);
PlayerInfo[playerid][pInt] = 0;
}
}
if(listitem == 3) // Kolodvor
{
if (GetPlayerState(playerid) == 2)
       {
new tmpcar = GetPlayerVehicleID(playerid);
SetVehiclePos(tmpcar, x,y,z);
TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
}
else
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerPos(playerid, x,y,z);
PlayerInfo[playerid][pInt] = 0;
}
}
if(listitem == 4) // VW
{
       if (GetPlayerState(playerid) == 2)
       {
new tmpcar = GetPlayerVehicleID(playerid);
SetVehiclePos(tmpcar, x,y,z);
TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
}
else
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerPos(playerid, x,y,z);
PlayerInfo[playerid][pInt] = 0;
}
}
if(listitem == 5) // Burg marina
{
if (GetPlayerState(playerid) == 2)
       {
new tmpcar = GetPlayerVehicleID(playerid);
SetVehiclePos(tmpcar, x,y,z);
TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
}
else
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerPos(playerid, x,y,z);
PlayerInfo[playerid][pInt] = 0;
}
}
 }
}

Nije testirano provjeri da li radi.
samo umjesto x,y,z stavljas svoje kordinate.
Poslednja Izmena: Jul 03, 2011, 17:42:00 POSLE PODNE od [TG]$--L84S--$

ako hoces sa /port [parametri] ja cu ti uraditi za strcmp...
Just one more time.

Radi savršeno,hvala.

Još da mi netko ono za /W i /sms xD

Trebaju mi komande /pokreniwar i /zaustaviwar

Trebaju mi komande za /report /pomoc i da admin odgovori nekome igricu sa /areci... i ono za evente da sto napise ima range da se to vidi....
Sve komande su u zcmd-u....
evo komande kako su kod mene:

COMMAND:getstats(playerid, params[])
{
if(PlayerInfo[playerid][AdminLevel] >= 2)
{
    SendClientMessage(playerid, 0xD8D8D8FF, "Komanda jos ne postoji!!");
    return 1;
}
else return SendClientMessage(playerid, 0xFF0000FF, "Admini SAMO.");
}


Tak sam da bude /report /pomoc  /areci i /ereci
Poslednja Izmena: Jul 04, 2011, 00:51:01 PRE PODNE od Mladen Smiljan
Trenutni projekt: NightLife Roleplay

Bizz System 40%
House System 70%
Car Ownership 20%
Log/reg System 100%
Poslovi 20%
Anticheat 0%
Organizacije 50%
Event System 0%
Komande 20%

Citat: pHon poslato Jul 03, 2011, 17:53:15 POSLE PODNE
Radi savršeno,hvala.

Još da mi netko ono za /W i /sms xD

Bump ! Molio bih nekoga da mi ovo uradi :D
Unaprijed hvala,LP

Citat: Darko a.k.a OptX poslato Jul 02, 2011, 11:07:10 PRE PODNE
Trazim komandu /naruci(za kafic)
evo ti :
nesto ovako posto radis sa strcmp :
if(strcmp(cmd, "/naruci", true) == 0)
{
      if(IsPlayerInRangeOfPoint(playerid, 10, x,y,z))
        {
if(PlayerInfo[playerid][pRegularRank] >= 1)
{
SendClientMessage(playerid, COLOR_WHITE, "---------------[Kafic]---------------");
SendClientMessage(playerid, COLOR_WHITE, "Možeš kupiti Pivo - /pivo - $0");
SendClientMessage(playerid, COLOR_WHITE, "---------------[Kafic]---------------");
}
}
}
return 1;
}

i onda napravis si jos /pivo
if(strcmp(cmd, "/pivo", true) == 0)
{
        if(!IsPlayerInRangeOfPoint(playerid, 10,x,y,z))
        {
            SendClientMessage(playerid, COLOR_NICERED, "Niste u Kaficu!");
            return 1;
}
SetPlayerSpecialAction(playerid, SPECIAL_ACTION_DRINK_BEER);
GameTextForPlayer(playerid, "~W~Kupio ~Y~Pivo ",4000,1);
return 1;
}

evo ti report i pomoc dacu ti sad za /areci
CMD:report(playerid, params[])
{
new id, reason[128], string[128];
if(sscanf(params, "us[128]", id, reason)) return SendClientMessage(playerid, COLOR_WHITE, "Korištenje: /report [ID] [Razlog]");
   else if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_WHITE, "PogreÅ¡an ID");
   else
format(string, sizeof(string), "Igrač %s prijavljuje igrača %s: %s", GetName(playerid), GetName(id), reason);
ABroadCast(COLOR_YELLOW, string);
SendClientMessage(playerid, COLOR_LIME, "Vaša prijava je poslana administraciji servera!");
  return 1;
}

CMD:pomoc(playerid, params[])
{
   new pTxt[128], string[128];
if(sscanf(params, "s[128]", pTxt)) SendClientMessage(playerid, COLOR_WHITE, "Korištenje: /pomoc [text]");
   format(string, sizeof(string), "Igrač %s traži pomoć: %s", GetName(playerid), pTxt);
   ABroadCast(COLOR_LIGHTBLUE, string);
   SendClientMessage(playerid, COLOR_LIME, "VaÅ¡a pomoć je poslana administraciji servera!");
   return 1;
}

funkcija ABroadCast

stock ABroadCast(color,const string[])
{
foreach(Player, i)
if (IsPlayerAdmin(i) || PlayerInfo[playerid][AdminLevel] >= 1)
{
SendClientMessage(i, color, string);
}
return 1;
}


funkcija GetName
stock GetName(playerid)
{
new
   pName[MAX_PLAYER_NAME];
   
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
return pName;
}


edi:
evo i areci
CMD:areci(playerid, params[])
{
new id, tekst[128], string[128], string2[128];
if(IsPlayerAdmin(playerid) || PlayerInfo[playerid][AdminLevel] >= 1)
{
    if(sscanf(params, "us[128]", id, tekst)) return SendClientMessage(playerid, -1, "Koristenje: /areci [ID] [Tekst]");
    else if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "PogreÅ¡an ID");
    else
    format(string, sizeof(string), "Poruka od admina %s: %s", GetName(playerid), tekst);
    SendClientMessage(id, -1, string);
      format(string2, sizeof(string2), "Poslali ste poruku igracu %s", GetName(id));
    SendClientMessage(playerid, -1, string2);
}
return 1;
}
Poslednja Izmena: Jul 04, 2011, 07:47:43 PRE PODNE od System32
Uskoro novi stunt server iStunt. DoÄ'ite i zabavite se!




   
   




Dizajniram za $$$
Popis stvari koje radim:

Wallpaper √  Signature ×  Logo √  Dizajn stranice (Ne kodiranje) √  Baner √  Avatar √  Animacija √  Intro √

Oprostite al bitno mi je .. ima li komanda da se unisti /veh vozila?

Znaci ja sad spawnam vozilo sa /veh i da ima komanda koja ce unistiti to ?

/destroycars

|| Edimax Admin || Edimax Mapper ||



daj tu komandu za veh
Uskoro novi stunt server iStunt. DoÄ'ite i zabavite se!




   
   




Dizajniram za $$$
Popis stvari koje radim:

Wallpaper √  Signature ×  Logo √  Dizajn stranice (Ne kodiranje) √  Baner √  Avatar √  Animacija √  Intro √