Little teleport problem
#1

Quote:

C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(50) : error 017: undefined symbol "text"
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(50) : error 017: undefined symbol "strtok"
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(54) : error 079: inconsistent return types (array & non-array)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(64) : error 079: inconsistent return types (array & non-array)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(70) : error 079: inconsistent return types (array & non-array)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(7 : error 079: inconsistent return types (array & non-array)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(82) : error 079: inconsistent return types (array & non-array)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(91) : error 079: inconsistent return types (array & non-array)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(97) : error 037: invalid string (possibly non-terminated string)
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(97) : error 017: undefined symbol "Dobrodosli"
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(97) : error 017: undefined symbol "na"
C:\Users\NASTIE\Desktop\samp03asvr_R4_win32\gamemo des\LvParty.pwn(97) : fatal error 107: too many error messages on one line

And here is script from line 50 to line 97

Quote:

text = strtok(cmdtext, idx);

if(strcmp(cmd, "/admins", true) == 0) {
SendClientMessage(playerid,0xFFFFFFAA," Iz puno razloga ne pokazujemo listu online admina ali zapamti, stalno smo tu!!");
return 1;
}
if(strcmp(cmd, "/pravila", true) == 0) {
SendClientMessage(playerid,0x0FF0C,"[1] Nemoj pitati da postanes admin u igri.");
SendClientMessage(playerid,0x0FF0C,"[2] Nemoj ubijati igrace tek kada se stvore u server.");
SendClientMessage(playerid,0x0FF0C,"[3] Nemoj koristiti cheatove i modove.");
SendClientMessage(playerid,0x0FF0C,"[4] Postuj admine, pomoci ce ti.");
SendClientMessage(playerid,0x0FF0C,"[5] Postuj pravila.");
SendClientMessage(playerid,0x0FF0C,"[6] Postuj odluke od admina.");
SendClientMessage(playerid,0x0FF0C,"Hvala sto igrate na LasVenturas Party serveru!");
return 1;
}
if(strcmp(cmd, "/tele", true) == 0) {
SendClientMessage(playerid,0xFFFFFFAA,"*********** **************");
SendClientMessage(playerid,0xFFFF00AA,"/dm");
SendClientMessage(playerid,0xFFFFFFAA,"*********** **************");
return 1;
}
if(strcmp(cmd, "/pomoc", true) == 0) {
SendClientMessage(playerid,0xFFFFFFAA,"Za listu komandi /komande za teleportiranje napisi /tele.");
SendClientMessage(playerid,0xFFFFFFAA,"Prije igranja procitaj /pravila.");
SendClientMessage(playerid,0xFFFFFFAA,"Za slanje privatne poruke napisi /pm.");
SendClientMessage(playerid,0xFFFFFFAA,"Za listu dostupnih animacija napisi /anims");
SendClientMessage(playerid,0xFFFFFFAA,"Hvala sto igrate na LasVenturas Party serveru!");
return 1;
}
if(strcmp(cmd, "/komande", true) == 0) {
SendClientMessage(playerid,0xFFFF00AA,"/anims /tele /admins /pravila /pm /info");
return 1;
}
if(strcmp(cmd, "/info", true) == 0) {
SendClientMessage(playerid,0xFFFFFFAA,"Owner/Vlasnik: ExtremePower");
SendClientMessage(playerid,0xFFFFFFAA,"Skripter: ExtremePower");
SendClientMessage(playerid,0xFFFFFFAA,"Skripta: Skripta pisana od 0 lines!");
SendClientMessage(playerid,0xFFFFFFAA,"Kontakt: MSN: kiki.dubrava@hotmail.com");
SendClientMessage(playerid,0xFFFFFFAA,"Xfire: dollar3tv ili Skype: dollar3tv");
SendClientMessage(playerid,0xFFFFFFAA,"Zemlja: Hrvatska");
return 1;
}
//------Dm arena-----/
if(strcmp(cmdtext, "/pocetak", true)== 0)
{
SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto )
SetPlayerInterior(playerid, 0);
return 1;
}

Reply
#2

You already started this post http://forum.sa-mp.com/index.php?top...7569#msg887569 there is no reason to start another.

Pretty simple bugs.
undefined symbol "text"
You haven't defined text: new text[128];
undefined symbol "strtok"
you need to define strtok
https://sampwiki.blast.hk/wiki/Strtok
Other Errors
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto" )
^
See if you get any more after those fixes
Reply
#3

Change:

pawn Код:
text = strtok(cmdtext, idx);
To:

pawn Код:
new cmd[256], idx;
cmd = strtok(cmdtext, idx);
or:
pawn Код:
new text[256];
And Change:

pawn Код:
//------Dm arena-----/
if(strcmp(cmdtext, "/pocetak", true)== 0)
{
SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto )
SetPlayerInterior(playerid, 0);
return 1;
}
To:

pawn Код:
//------Dm arena-----/
if(strcmp(cmdtext, "/pocetak", true)== 0)
{
SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto");
SetPlayerInterior(playerid, 0);
return 1;
}
Then, put 'strtok' in your Script:
pawn Код:
strtok(const string[], &index)
{
    new length = strlen(string);
    while ((index < length) && (string[index] <= ' ')) {
        index++;
    }
    new offset = index;
    new result[20];
    while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1))) {
        result[index - offset] = string[index];
        index++;
    }
    result[index - offset] = EOS;
    return result;
}


Reply
#4

Can you please put taht when i put again errors but not that please here it is that script
Код:
#include <a_samp>
#include <core>
#include <float>
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_YELLOW 0xFFFF00AA


#pragma tabsize 0

main()
{
  print("\n----------------------------------");
  print(" LasVenturas Party by:ExtremePower\n");
  print("----------------------------------\n");
}

public OnPlayerConnect(playerid)
{
  GivePlayerMoney(playerid, 10000);
  SetPlayerArmour(playerid, 100.0);
	new string[64], pName[MAX_PLAYER_NAME];
  GetPlayerName(playerid,pName,MAX_PLAYER_NAME);
  format(string,sizeof string,"**((%s))** Se prikljucio na Party Server. Dobrodosao!",pName);
  SendClientMessageToAll(0x33AA33AA,string);
  return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
  new
    string[64],
    name[MAX_PLAYER_NAME];
  GetPlayerName(playerid,name,MAX_PLAYER_NAME);
  switch(reason)
  {
    case 0: format(string,sizeof string,"**((%s))** Je napustio server. (Timed out)",name);
    case 1: format(string,sizeof string,"**((%s))** Je napustio server. (Leaving)",name);
    case 2: format(string,sizeof string,"**((%s))** Je napustio server. (Kicked/Banned)",name);
  }
  SendClientMessageToAll(0xFFFF00AA,string);
  return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
  new idx;
  new cmd[256];

  cmd = strtok(cmdtext, idx);

  if(strcmp(cmd, "/admins", true) == 0) {
  SendClientMessage(playerid,0xFFFFFFAA," Iz puno razloga ne pokazujemo listu online admina ali zapamti, stalno smo tu!!");
   return 1;
  }
  if(strcmp(cmd, "/pravila", true) == 0) {
  SendClientMessage(playerid,0x0FF0C,"[1] Nemoj pitati da postanes admin u igri.");
  SendClientMessage(playerid,0x0FF0C,"[2] Nemoj ubijati igrace tek kada se stvore u server.");
  SendClientMessage(playerid,0x0FF0C,"[3] Nemoj koristiti cheatove i modove.");
  SendClientMessage(playerid,0x0FF0C,"[4] Postuj admine, pomoci ce ti.");
  SendClientMessage(playerid,0x0FF0C,"[5] Postuj pravila.");
  SendClientMessage(playerid,0x0FF0C,"[6] Postuj odluke od admina.");
  SendClientMessage(playerid,0x0FF0C,"Hvala sto igrate na LasVenturas Party serveru!");
   return 1;
   }
   if(strcmp(cmd, "/tele", true) == 0) {
	SendClientMessage(playerid,0xFFFFFFAA,"*************************");
	SendClientMessage(playerid,0xFFFF00AA,"/dm");
  SendClientMessage(playerid,0xFFFFFFAA,"*************************");
   return 1;
  }
  if(strcmp(cmd, "/pomoc", true) == 0) {
  SendClientMessage(playerid,0xFFFFFFAA,"Za listu komandi /komande za teleportiranje napisi /tele.");
  SendClientMessage(playerid,0xFFFFFFAA,"Prije igranja procitaj /pravila.");
  SendClientMessage(playerid,0xFFFFFFAA,"Za slanje privatne poruke napisi /pm.");
  SendClientMessage(playerid,0xFFFFFFAA,"Za listu dostupnih animacija napisi /anims");
  SendClientMessage(playerid,0xFFFFFFAA,"Hvala sto igrate na LasVenturas Party serveru!");
   return 1;
  }
  if(strcmp(cmd, "/komande", true) == 0) {
  SendClientMessage(playerid,0xFFFF00AA,"/anims /tele /admins /pravila /pm /info");
   return 1;
  }
  if(strcmp(cmd, "/info", true) == 0) {
  SendClientMessage(playerid,0xFFFFFFAA,"Owner/Vlasnik: ExtremePower");
  SendClientMessage(playerid,0xFFFFFFAA,"Skripter: ExtremePower");
  SendClientMessage(playerid,0xFFFFFFAA,"Skripta: Skripta pisana od 0 lines!");
  SendClientMessage(playerid,0xFFFFFFAA,"Kontakt: MSN: kiki.dubrava@hotmail.com");
	SendClientMessage(playerid,0xFFFFFFAA,"Xfire: dollar3tv ili Skype: dollar3tv");
	SendClientMessage(playerid,0xFFFFFFAA,"Zemlja: Hrvatska");
   return 1;
  }
  //--------Mali anti-cheat------//
  if(GetPlayerPing(playerid) > 500) Kick(playerid);
  if(GetPlayerWeapon(playerid)> 38) Ban(playerid);

  //------Dm arena-----/
  if(strcmp(cmdtext, "/dm", true) == 0)
    {
     GivePlayerWeapon(playerid, 26, 500);
     GivePlayerWeapon(playerid, 31, 500);
     SendClientMessage(playerid,0xFFFF00AA,"Dobio si M4 i shootgun zato jer si napisao /DM, sretno u borbi!");
		 new cartype = GetPlayerVehicleID(playerid);
		 SetPlayerInterior(playerid,0);
     if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
     {
     SetPlayerPos(playerid,1374.8513,1769.3303,10.8203);
     }
     else if(IsPlayerInVehicle(playerid, cartype) == 1)
     {
     SetVehiclePos(cartype,1374.8513,1769.3303,10.8203);
     SetVehicleZAngle(cartype,30.6101);
     }
     else
     {
     SetPlayerPos(playerid,1374.8513,1769.3303,10.8203);
     }
     GameTextForPlayer(playerid,"dobro dosli u DM arenu",2500,3);
     return 1;
   }
     return 0;
  }
  
public OnPlayerSpawn(playerid)
{
  SetPlayerInterior(playerid,0);
  TogglePlayerClock(playerid,0);
  return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
  SendDeathMessage(killerid, playerid, reason);
  return 1;
}

SetupPlayerForClassSelection(playerid)
{
	SetPlayerInterior(playerid,14);
  	SetPlayerPos(playerid,349.0453,193.2271,1014.1797);
  	SetPlayerFacingAngle(playerid, 286.25);
  	SetPlayerCameraPos(playerid,352.9164,194.5702,1014.1875);
	SetPlayerCameraLookAt(playerid,349.0453,193.2271,1014.1797);
}

public OnPlayerRequestClass(playerid, classid)
{
  SetupPlayerForClassSelection(playerid);
  return 1;
}

public OnGameModeInit()
{
  SetGameModeText("Lv Party");
  ShowPlayerMarkers(1);
  ShowNameTags(1);
  AllowAdminTeleport(1);

  AddPlayerClass(83,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(84,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(131,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(171,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(287,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(227,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(264,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(256,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(19,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(18,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(17,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
//------------Objekti--------------//

CreateObject(1309, 1712.304688, 1606.560791, 21.687422, 0, 0, -22.4999953447); // object
CreateObject(3249, 1707.663940, 1608.471802, 9.015626, 0, 0, -22.4999953447); // object (Cool
  return 1;
}

strtok(const string[], &index)
{
  new length = strlen(string);
  while ((index < length) && (string[index] <= ' '))
  {
   index++;
  }

  new offset = index;
  new result[20];
  while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
  {
   result[index - offset] = string[index];
   index++;
  }
  result[index - offset] = EOS;
  return result;
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  new string[128];
  format(string, sizeof(string), "Ulazis u vozilo %i",vehicleid);
  SendClientMessage(playerid, 0xFFFFFFFF, string);
  return 1;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
  new string[128];
  format(string, sizeof(string), "Izlazis iz vozila %i", vehicleid);
  SendClientMessage(playerid, 0xFFFFFFFF, string);
  return 1;
}
Reply
#5

Quote:
Originally Posted by nastoe
Can you please put taht when i put again errors but not that please here it is that script
Код:
...
The script seems to be correct! Here this has compiled, and without any error...
Reply
#6

yes but there is no tele commands can you then add

Код:
if(strcmp(cmdtext, "/pocetak", true)== 0)
   {
     SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
     SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto )
     SetPlayerInterior(playerid, 0);
     return 1;
   }
You will see error
Reply
#7

Quote:
Originally Posted by nastoe
yes but there is no tele commands can you then add

Код:
if(strcmp(cmdtext, "/pocetak", true)== 0)
   {
     SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
     SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto )
     SetPlayerInterior(playerid, 0);
     return 1;
   }
You will see error
Here is the GameMode.
In .pwn and in .amx , and I put some teleports:

Script.rar
Reply
#8

If you can on this

Код:
#include <a_samp>
#include <core>
#include <float>
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_RED 0xAA3333AA
#define COLOR_ORANGE 0xFF9900AA
#define COLOR_PINK 0xFF66FFAA


#pragma tabsize 0

main()
{
  print("\n----------------------------------");
  print(" LasVenturas Party by:ExtremePower\n");
  print("----------------------------------\n");
}

public OnPlayerConnect(playerid)
{
  GivePlayerMoney(playerid, 10000);
  SetPlayerArmour(playerid, 100.0);
	new string[64], pName[MAX_PLAYER_NAME];
  GetPlayerName(playerid,pName,MAX_PLAYER_NAME);
  format(string,sizeof string,"**((%s))** Se prikljucio na Party Server. Dobrodosao!",pName);
  SendClientMessageToAll(0x33AA33AA,string);
  return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
  new
    string[64],
    name[MAX_PLAYER_NAME];
  GetPlayerName(playerid,name,MAX_PLAYER_NAME);
  switch(reason)
  {
    case 0: format(string,sizeof string,"**((%s))** Je napustio server. (Timed out)",name);
    case 1: format(string,sizeof string,"**((%s))** Je napustio server. (Leaving)",name);
    case 2: format(string,sizeof string,"**((%s))** Je napustio server. (Kicked/Banned)",name);
  }
  SendClientMessageToAll(0xFFFF00AA,string);
  return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
  new idx;
  new cmd[256];

  cmd = strtok(cmdtext, idx);

  if(strcmp(cmd, "/admins", true) == 0) {
  SendClientMessage(playerid,0xFFFFFFAA," Iz puno razloga ne pokazujemo listu online admina ali zapamti, stalno smo tu!!");
   return 1;
  }
  if(strcmp(cmd, "/pravila", true) == 0) {
  SendClientMessage(playerid,0x0FF0C,"[1] Nemoj pitati da postanes admin u igri.");
  SendClientMessage(playerid,0x0FF0C,"[2] Nemoj ubijati igrace tek kada se stvore u server.");
  SendClientMessage(playerid,0x0FF0C,"[3] Nemoj koristiti cheatove i modove.");
  SendClientMessage(playerid,0x0FF0C,"[4] Postuj admine, pomoci ce ti.");
  SendClientMessage(playerid,0x0FF0C,"[5] Postuj pravila.");
  SendClientMessage(playerid,0x0FF0C,"[6] Postuj odluke od admina.");
  SendClientMessage(playerid,0x0FF0C,"Hvala sto igrate na LasVenturas Party serveru!");
   return 1;
   }
   if(strcmp(cmd, "/tele", true) == 0) {
	SendClientMessage(playerid,0xFFFFFFAA,"*************************");
	SendClientMessage(playerid,0xFFFF00AA,"/dm");
  SendClientMessage(playerid,0xFFFFFFAA,"*************************");
   return 1;
  }
  if(strcmp(cmd, "/pomoc", true) == 0) {
  SendClientMessage(playerid,0xFFFFFFAA,"Za listu komandi /komande za teleportiranje napisi /tele.");
  SendClientMessage(playerid,0xFFFFFFAA,"Prije igranja procitaj /pravila.");
  SendClientMessage(playerid,0xFFFFFFAA,"Za slanje privatne poruke napisi /pm.");
  SendClientMessage(playerid,0xFFFFFFAA,"Za listu dostupnih animacija napisi /anims");
  SendClientMessage(playerid,0xFFFFFFAA,"Hvala sto igrate na LasVenturas Party serveru!");
   return 1;
  }
  if(strcmp(cmd, "/komande", true) == 0) {
  SendClientMessage(playerid,0xFFFF00AA,"/anims /tele /admins /pravila /pm /info");
   return 1;
  }
  if(strcmp(cmd, "/info", true) == 0) {
  SendClientMessage(playerid,0xFFFFFFAA,"Owner/Vlasnik: ExtremePower");
  SendClientMessage(playerid,0xFFFFFFAA,"Skripter: ExtremePower");
  SendClientMessage(playerid,0xFFFFFFAA,"Skripta: Skripta pisana od 0 lines!");
  SendClientMessage(playerid,0xFFFFFFAA,"Kontakt: MSN: kiki.dubrava@hotmail.com");
	SendClientMessage(playerid,0xFFFFFFAA,"Xfire: dollar3tv ili Skype: dollar3tv");
	SendClientMessage(playerid,0xFFFFFFAA,"Zemlja: Hrvatska");
   return 1;
  }
  //--------Mali anti-cheat------//
  if(GetPlayerPing(playerid) > 500) Kick(playerid);
  if(GetPlayerWeapon(playerid)> 38) Ban(playerid);

  //------Dm arena-----/
  if(strcmp(cmdtext, "/dm", true) == 0)
    {
     GivePlayerWeapon(playerid, 26, 500);
     GivePlayerWeapon(playerid, 31, 500);
     SendClientMessage(playerid,0xFFFF00AA,"Dobio si M4 i shootgun zato jer si napisao /DM, sretno u borbi!");
		 new cartype = GetPlayerVehicleID(playerid);
		 SetPlayerInterior(playerid,0);
     if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
     {
     SetPlayerPos(playerid,1374.8513,1769.3303,10.8203);
     }
     else if(IsPlayerInVehicle(playerid, cartype) == 1)
     {
     SetVehiclePos(cartype,1374.8513,1769.3303,10.8203);
     SetVehicleZAngle(cartype,30.6101);
     }
     else
     {
     SetPlayerPos(playerid,1374.8513,1769.3303,10.8203);
     }
     GameTextForPlayer(playerid,"dobro dosli u DM arenu",2500,3);
     return 1;
   }
     return 0;
  }
  
public OnPlayerSpawn(playerid)
{
  SetPlayerInterior(playerid,0);
  TogglePlayerClock(playerid,0);
  return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
  SendDeathMessage(killerid, playerid, reason);
  return 1;
}

SetupPlayerForClassSelection(playerid)
{
	SetPlayerInterior(playerid,14);
  	SetPlayerPos(playerid,349.0453,193.2271,1014.1797);
  	SetPlayerFacingAngle(playerid, 286.25);
  	SetPlayerCameraPos(playerid,352.9164,194.5702,1014.1875);
	SetPlayerCameraLookAt(playerid,349.0453,193.2271,1014.1797);
}

public OnPlayerRequestClass(playerid, classid)
{
  SetupPlayerForClassSelection(playerid);
  return 1;
}

public OnGameModeInit()
{
  SetGameModeText("Lv Party");
  ShowPlayerMarkers(1);
  ShowNameTags(1);
  AllowAdminTeleport(1);

  AddPlayerClass(83,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(84,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(131,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(171,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(287,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(227,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(264,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(256,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(19,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(18,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);
  AddPlayerClass(17,1320.0809,1261.2794,10.8203,0.7322,10,0,0,0,0,0);

//-----------Vozila------------//

CreateVehicle(411, 1306.538330, 1279.499146, 10.480690, 360, -1, -1, 300); // spawnpoint (1)
CreateVehicle(411, 1310.379028, 1279.728271, 10.480690, 360, -1, -1, 300); // spawnpoint (2)
CreateVehicle(411, 1313.759277, 1279.343628, 10.480690, 360, -1, -1, 300); // spawnpoint (3)
CreateVehicle(411, 1317.071655, 1279.627808, 10.480690, 360, -1, -1, 300); // spawnpoint (4)
CreateVehicle(411, 1319.883545, 1280.028076, 10.480690, 360, -1, -1, 300); // spawnpoint (5)
CreateVehicle(411, 1323.293335, 1279.864746, 10.480690, 360, -1, -1, 300); // spawnpoint (6)
CreateVehicle(411, 1326.394775, 1279.808594, 10.480691, 360, -1, -1, 300); // spawnpoint (7)
CreateVehicle(411, 1329.290894, 1279.639893, 10.480690, 360, -1, -1, 300); // spawnpoint (Cool
CreateVehicle(522,1283.534790, 1287.406250, 10.480690, 271, -1, -1, 300); // spawnpoint (9)
CreateVehicle(522, 1283.664063, 1291.661621, 10.480690, 271, -1, -1, 300); // spawnpoint (10)
CreateVehicle(522, 1283.671021, 1294.718872, 10.480690, 271, -1, -1, 300); // spawnpoint (11)
CreateVehicle(522, 1283.325195, 1297.806885, 10.480690, 282, -1, -1, 300); // spawnpoint (12)
CreateVehicle(522, 1283.798706, 1300.750000, 10.480690, 271, -1, -1, 300); // spawnpoint (13)
CreateVehicle(522, 1283.172729, 1304.852295, 10.480690, 271, -1, -1, 300); // spawnpoint (14)
CreateVehicle(522, 1283.735352, 1307.734863, 10.480690, 271, -1, -1, 300); // spawnpoint (15)
CreateVehicle(522, 1283.443726, 1310.575562, 10.480690, 271, -1, -1, 300); // spawnpoint (16)
CreateVehicle(522, 1507.142090, 1365.637939, 69.986275, 360, -1, -1, 300); // spawnpoint (17)
CreateVehicle(522, 1502.985352, 1365.784790, 69.986275, 360, -1, -1, 300); // spawnpoint (18)
CreateVehicle(522, 1498.234985, 1365.447632, 69.986275, 360, -1, -1, 300); // spawnpoint (19)
CreateVehicle(522, 1435.534912, 1413.135864, 110.558243, 271, -1, -1, 300); // spawnpoint (20)
CreateVehicle(522, 1435.550293, 1416.087036, 110.558243, 271, -1, -1, 300); // spawnpoint (21)
CreateVehicle(522, 1435.517456, 1419.401123, 110.558243, 271, -1, -1, 300); // spawnpoint (22)
CreateVehicle(522, 1482.145386, 1579.850098, 39.607594, 78, -1, -1, 300); // spawnpoint (23)
CreateVehicle(522, 1481.841553, 1576.485107, 39.607594, 89, -1, -1, 300); // spawnpoint (24)
CreateVehicle(522, 1481.552856, 1572.959961, 39.607594, 89, -1, -1, 300); // spawnpoint (25)
CreateVehicle(522, 1371.410156, 1563.417603, 39.607594, 271, -1, -1, 300); // spawnpoint (26)
CreateVehicle(522, 1368.956543, 1591.165527, 39.607594, 270, -1, -1, 300); // spawnpoint (27)
  return 1;
}

strtok(const string[], &index)
{
  new length = strlen(string);
  while ((index < length) && (string[index] <= ' '))
  {
   index++;
  }

  new offset = index;
  new result[20];
  while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
  {
   result[index - offset] = string[index];
   index++;
  }
  result[index - offset] = EOS;
  return result;
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  new string[128];
  format(string, sizeof(string), "Ulazis u vozilo %i",vehicleid);
  SendClientMessage(playerid, 0xFF9900AA, string);
  return 1;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
  new string[128];
  format(string, sizeof(string), "Izlazis iz vozila %i", vehicleid);
  SendClientMessage(playerid, 0xFF66FFAA, string);
  return 1;
}
Put this
Код:
if(strcmp(cmdtext, "/pocetak", true)== 0)
   {
     SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
     SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto )
     SetPlayerInterior(playerid, 0);
     return 1;
   }
Then you will see errors i have one tele command but when i add another then i have errors
Reply
#9

Wrong:
pawn Код:
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto )
Correct:
pawn Код:
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto");

Then:
pawn Код:
if(strcmp(cmdtext, "/pocetak", true)== 0)
{
SetPlayerPos(playerid, 1318.4937,1266.2261,10.8203);
SendClientMessage(playerid,0xFFFF00AA,"Dobrodosli na SPAWN mijesto");
SetPlayerInterior(playerid, 0);
return 1;
}
Reply
#10

I have one world for you: YOUR RULES YOU ARE MASTER I TRYING TO FIX HOLE DAY AND THEY YOU COM AND FIX FOR 5min
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)