Jump to content
  • 0

pomoc Jak mam udelat warp ?


konasek

Dotaz

6 odpovědí na tuto otázku

Recommended Posts

  • 0

Hore medzi define

 

 

#define dcmd(%1,%2,%3) if (!strcmp((%3)[1], #%1, true, (%2)) && ((((%3)[(%2) + 1] == '\0') && (dcmd_%1(playerid, ""))) || (((%3)[(%2) + 1] == ' ') && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1

 

#define DIALOG_CMDS 10293

 

 

OnPlayerCommandText

 

 

dcmd(warp, 4, cmdtext);

 

 

mimo publici

 

 

dcmd_warp(playerid, params[])

{

#pragma unused params

new warp[256];

strcat(warp, "TVOJ TEXT \n");

strcat(warp, "TVOJ TEXT \n");

strcat(warp, "TVOJ TEXT \n");

ShowPlayerDialog(playerid, DIALOG_CMDS, DIALOG_STYLE_LIST,"Warpy",warp,"Portnuť","Zavrieť");

}

 

 

OnDialogResponse

 

 

 

if ( dialogid == DIALOG_CMDS) // Ak je dialog CMDS

{

if ( response ) // Klikol prvý button

{

switch ( listitem )

{

case 0: // Prvá položka

{

SetPlayerPos(playerid, X, Y, Z);

SetPlayerInterior(playerid, virtuálny svet);

// + si môžeš dodať nejaký tvoje veci čo by si chcel napr že mu za to zobere prachy atd...

}

 

case 1: // Druhá položka

{

SetPlayerPos(playerid, X, Y, Z);

SetPlayerInterior(playerid, virtuálny svet);

// + si môžeš dodať nejaký tvoje veci čo by si chcel napr že mu za to zobere prachy atd...

}

 

case 2: // Tretia položka

{

SetPlayerPos(playerid, X, Y, Z);

SetPlayerInterior(playerid, virtuálny svet);

// + si môžeš dodať nejaký tvoje veci čo by si chcel napr že mu za to zobere prachy atd...

}

}

}

return 1;

}

 

 

 

Ak som sa niekde sekol nwm skús malo by to fungovať.

Link to comment
Share on other sites

  • 0

Pokud nechceš hodně warpů, tak je lepší toto

if (strcmp("/warp", cmdtext, true, 10) == 0)
{
SetPlayerPos(playerid, x, y, z);
return 1;
}

 

Místo x, y, z doplň souřadnice

Link to comment
Share on other sites

  • 0

Hore medzi define

 

 

#define dcmd(%1,%2,%3) if (!strcmp((%3)[1], #%1, true, (%2)) && ((((%3)[(%2) + 1] == '\0') && (dcmd_%1(playerid, ""))) || (((%3)[(%2) + 1] == ' ') && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1

 

#define DIALOG_CMDS 10293

 

 

OnPlayerCommandText

 

 

dcmd(warp, 4, cmdtext);

 

 

mimo publici

 

 

dcmd_warp(playerid, params[])

{

new warp[256];

strcat(warp, "TVOJ TEXT \n");

strcat(warp, "TVOJ TEXT \n");

strcat(warp, "TVOJ TEXT \n");

ShowPlayerDialog(playerid, DIALOG_CMDS, DIALOG_STYLE_LIST,Warpy,warp,"Portnuť","Zavrieť"

}

 

 

OnDialogResponse

 

 

 

if ( dialogid == DIALOG_CMDS) // Ak je dialog CMDS

{

if ( response ) // Klikol prvý button

{

switch ( listitem )

{

case 0: // Prvá položka

{

SetPlayerPos(playerid, X, Y, Z);

SetPlayerInterior(playerid, virtuálny svet);

// + si môžeš dodať nejaký tvoje veci čo by si chcel napr že mu za to zobere prachy atd...

}

 

case 1: // Druhá položka

{

SetPlayerPos(playerid, X, Y, Z);

SetPlayerInterior(playerid, virtuálny svet);

// + si môžeš dodať nejaký tvoje veci čo by si chcel napr že mu za to zobere prachy atd...

}

 

case 2: // Tretia položka

{

SetPlayerPos(playerid, X, Y, Z);

SetPlayerInterior(playerid, virtuálny svet);

// + si môžeš dodať nejaký tvoje veci čo by si chcel napr že mu za to zobere prachy atd...

}

}

}

return 1;

}

 

 

 

Ak som sa niekde sekol nwm skús malo by to fungovať.

nechci bu****vat ale někde máš chybu :d nebudu říkat kde

 

Pokud nechceš hodně warpů, tak je lepší toto

if (strcmp("/warp", cmdtext, true, 10) == 0)
{
SetPlayerPos(playerid, x, y, z);
return 1;
}

 

Místo x, y, z doplň souřadnice

ještě by musel vědět co jsou souřadnice :d

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...