Szerző Téma: [HELP]Új teleport pont  (Megtekintve 668 alkalommal)

[HELP]Új teleport pont
« Dátum: 2012. június 18. - 20:15:37 »
0 Show voters
Sziasztok Lenne egy problémám van olyan benn a módba hogy /rescue és az jelzi hogy te hova szeretnél menni KACC stb.... Na és ezt én hogy bõvíthetem hogy itt több teleport legyen benn és több helyre tudjanak elmenni a játékosok

Nem elérhető zeteni

  • 1970
  • Ex-Scripter
    • Profil megtekintése
[HELP]Új teleport pont
« Válasz #1 Dátum: 2012. június 18. - 20:16:07 »
0 Show voters
Másold be a rescue parancsot

[HELP]Új teleport pont
« Válasz #2 Dátum: 2012. június 18. - 20:24:28 »
0 Show voters
// Lets the player choose where he wants to respawn (costs $200)
COMMAND:teleport(playerid, params[])
{
// Send the command to all admins so they can see it
SendAdminText(playerid, \"/rescue\", params);
// Check if the player has logged in
if (APlayerData[playerid][LoggedIn] == true)
{
   // Check if the player has a wanted level of less than 3
   if (GetPlayerWantedLevel(playerid) < 3)
   {
      // Check if the player isn\'t in jail
      if (APlayerData[playerid][PlayerJailed] == 0)
      {
         if (APlayerData[playerid][JobStarted] == false)
         {
            // Make sure you can\'t use \"/rescue\" when you\'re inside a vehicle (doesn\'t respawn you at the requested coords
            // and puts a random item (bottle, sigarette, ...) in the player\'s hands
            if (GetPlayerVehicleID(playerid) == 0)
            {
                // Create a dialog based on the player\'s class
               switch (APlayerData[playerid][PlayerClass])
               {
                  case ClassTruckDriver: // Ask where the trucker player wants to respawn
                     ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Kaminoos depók:\", \"{00FF00}Fallen Tree Depó\\r\\n{FF0000}Flint Trucking Depó\\r\\n{00FF00}LVA Freight Depó\\r\\n{FF0000}Doherty Depó\\r\\n{00FF00}El Corona Depó\\r\\n{FF0000}Las Payasdas Depó\\r\\n{00FF00}Bánya\\r\\n{FF0000}Shady Creek Depó\\r\\n{00FF00}K.A.C.C-i depó\", \"Spawn\", \"Cancel\");
                  case ClassBusDriver: // Ask where the busdriver wants to respawn
                     ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Busz pályaudvarok:\", \"{FF0000}Los Santos\\r\\n{00FF00}San Fierro\\r\\n{FF0000}Las Venturas\", \"Spawn\", \"Cancel\");
                  case ClassPilot: // Ask where the pilot wants to respawn
                     ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Choose pilot spawn point:\", \"{00FF00}Los Santos\\r\\n{FF0000}San Fierro\\r\\n{00FF00}Las Venturas\\r\\n{FF0000}Los Santos\\r\\n{00FF00}San Fierro\\r\\n{FF0000}Las Venturas\", \"Spawn\", \"Cancel\");
                  case ClassPolice: // Ask where the police player wants to respawn
                     ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Rendõrségek:\", \"{FF0000}Los Santos\\r\\nS{00FF00}an Fierro\\r\\n{FF0000}Las Venturas\", \"Spawn\", \"Cancel\");
                  case ClassCourier: // Ask where the courier player wants to respawn
                     ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Csomagkihordó telepek:\", \"{00FF00}Los Santos\\r\\n{FF0000}San Fierro\\r\\n{00FF00}Las Venturas\", \"Spawn\", \"Cancel\");
                  case ClassKukasDriver: // Ask where the courier player wants to respawn
                     ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Szemét telepek:\", \"{FF0000}Bayside\\r\\n{00FF00}Las Vegas\\r\\n{FF0000}San Fierro\\r\\n{00FF00}Angel Pine\\r\\n{FF0000}Los Santos\", \"Spawn\", \"Cancel\");
               }

Nem elérhető ZyZu.

  • Globális moderátor
  • 8939
  • my turbo diesel forum
  • Discord: ZyZu.
    • Profil megtekintése
[HELP]Új teleport pont
« Válasz #3 Dátum: 2012. június 18. - 20:36:43 »
0 Show voters
Code tagokban!

[HELP]Új teleport pont
« Válasz #4 Dátum: 2012. június 18. - 20:39:02 »
0 Show voters
// Lets the player choose where he wants to respawn (costs $200)
COMMAND:teleport(playerid, params[])
{
// Send the command to all admins so they can see it
SendAdminText(playerid, \"/teleport\", params);
// Check if the player has logged in
if (APlayerData[playerid][LoggedIn] == true)
{
// Check if the player has a wanted level of less than 3
if (GetPlayerWantedLevel(playerid) < 3)
{
   // Check if the player isn\'t in jail
   if (APlayerData[playerid][PlayerJailed] == 0)
   {
      if (APlayerData[playerid][JobStarted] == false)
      {
         // Make sure you can\'t use \"/rescue\" when you\'re inside a vehicle (doesn\'t respawn you at the requested coords
         // and puts a random item (bottle, sigarette, ...) in the player\'s hands
         if (GetPlayerVehicleID(playerid) == 0)
         {
             // Create a dialog based on the player\'s class
            switch (APlayerData[playerid][PlayerClass])
            {
               case ClassTruckDriver: // Ask where the trucker player wants to respawn
                  ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Kaminoos depók:\", \"{00FF00}Fallen Tree Depó\\r\\n{FF0000}Flint Trucking Depó\\r\\n{00FF00}LVA Freight Depó\\r\\n{FF0000}Doherty Depó\\r\\n{00FF00}El Corona Depó\\r\\n{FF0000}Las Payasdas Depó\\r\\n{00FF00}Bánya\\r\\n{FF0000}Shady Creek Depó\\r\\n{00FF00}K.A.C.C-i depó\", \"Spawn\", \"Cancel\");
               case ClassBusDriver: // Ask where the busdriver wants to respawn
                  ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Busz pályaudvarok:\", \"{FF0000}Los Santos\\r\\n{00FF00}San Fierro\\r\\n{FF0000}Las Venturas\", \"Spawn\", \"Cancel\");
               case ClassPilot: // Ask where the pilot wants to respawn
                  ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Choose pilot spawn point:\", \"{00FF00}Los Santos\\r\\n{FF0000}San Fierro\\r\\n{00FF00}Las Venturas\\r\\n{FF0000}Los Santos\\r\\n{00FF00}San Fierro\\r\\n{FF0000}Las Venturas\", \"Spawn\", \"Cancel\");
               case ClassPolice: // Ask where the police player wants to respawn
                  ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Rendõrségek:\", \"{FF0000}Los Santos\\r\\nS{00FF00}an Fierro\\r\\n{FF0000}Las Venturas\", \"Spawn\", \"Cancel\");
               case ClassCourier: // Ask where the courier player wants to respawn
                  ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Csomagkihordó telepek:\", \"{00FF00}Los Santos\\r\\n{FF0000}San Fierro\\r\\n{00FF00}Las Venturas\", \"Spawn\", \"Cancel\");
               case ClassKukasDriver: // Ask where the courier player wants to respawn
                  ShowPlayerDialog(playerid, DialogRescue, DIALOG_STYLE_LIST, \"Szemét telepek:\", \"{FF0000}Bayside\\r\\n{00FF00}Las Vegas\\r\\n{FF0000}San Fierro\\r\\n{00FF00}Angel Pine\\r\\n{FF0000}Los Santos\", \"Spawn\", \"Cancel\");
            }
         }
         else
            SendClientMessage(playerid, 0xFF7318FF, \"Nem tudod használni a  \'/teleport\' parancsot ha jármûben vagy\"); // \"/rescue\" doesn\'t work inside a vehicle
      }
      else
          SendClientMessage(playerid, 0xFF7318FF, \"Nem tudod használni a teleport-t ha munkában vagy\"); // \"/rescue\" doesn\'t work during a job
   }
   else
       SendClientMessage(playerid, 0xFF7318FF, \"Nem tudod használni a /teleport parancsot a börtönbe\");
}
else
    SendClientMessage(playerid, 0xFF7318FF, \"{FF0000}Nem tudod használni a  /teleport parancsot körözés alatt\");
}
else
    return 0;
// Let the server know that this was a valid command
return 1;

 

Dupla hozzászólás automatikusan összefûzve. ( 2012. június 18. - 21:03:01 )

/ Setup all the fields for a spawnlocation
enum TSpawnLocation
{
Float:SpawnX,
Float:SpawnY,
Float:SpawnZ,
Float:SpawnAngle
}
new ASpawnLocationsTrucker[][TSpawnLocation] =
{
{-525.0, -502.0, 26.0, 0.0}, // Fallen Tree Depot
{-74.7, -1137.5, 4.5, 0.0}, // Flint Trucking Depot
{1457.0, 975.5, 11.0, 0.0}, // LVA Freight Depot
{-2136.0, -247.5, 36.5, 270.0}, // Doherty Depot
{1766.5, -2040.7, 14.0, 270.0}, // El Corona Depot
{-546.0, 2594.0, 54.0, 270.0}, // Las Payasdas Depot
{332.0, 900.0, 25.0, 205.0}, // Quarry Top
{-1575.0, -2724.0, 49.0, 146.0} // Whetstone Depot
};
new ASpawnLocationsBusDriver[][TSpawnLocation] =
{
{1809.0, -1905.0, 13.6, 90.0}, // Los Santos busdepot
{-1983.0, 110.0, 27.7, 180.0}, // San Fierro busdepot
{1060.0, 1260.0, 11.0, 270.0} // Las Venturas busdepot
};
new ASpawnLocationsPilot[][TSpawnLocation] =
{
{2010.0, -2345.0, 13.6, 90.0}, // Los Santos airport
{-1211.0, -105.0, 14.2, 135.0}, // San Fierro airport
{1630.0, 1615.0, 10.9, 90.0} // Las Venturas airport
};
new ASpawnLocationsPolice[][TSpawnLocation] =
{
{1568.5, -1693.5, 6.0, 180.0}, // Los Santos police station
{-1590.0, 716.25, -5.0, 270.0}, // San Fierro police station
{2275.0, 2460.0, 10.9, 90.0} // Las Venturas police station
};
new ASpawnLocationsMafia[][TSpawnLocation] =
{
{2822.5, 898.5, 10.8, 0.0} // Mafia hideout
};
new ASpawnLocationsCourier[][TSpawnLocation] =
{
{798.0, -618.75, 16.4, 0.0}, // Los Santos
{-1849.25, -135.0, 12.0, 90.0}, // San Fierro
{1050.5, 1931.0, 10.9, 270.0}, // Las Venturas
{-2197.1, -2154.8, 46.8, 0.0}, // Chilliadi depó
{-2459.68, 2238.0, 4.79, 0.0}, // Bayside
{-2244.47, -2305.10, 30.63, 233.00} // Angel Pine
};
new ASpawnLocationsAssistance[][TSpawnLocation] =
{
{211.25, 24.75, 2.6, 270.0}
};
new ASpawnLocationsRoadWorker[][TSpawnLocation] =
{
{-1866.25, -1715.25, 22.7, 125.0} // Junkyard
};
new ASpawnLocationsKukasDriver[][TSpawnLocation] =
{
{-2401.8904,2369.1118,4.9289,230.9574}, // bayside
{2780.0513,2686.7649,10.8203,91.4652},
{-2569.0674,1393.9148,7.5707,168.6592}, //SF
{-1865.1222,-1714.3632,22.6953,128.5216},
{2173.6841,-1995.7412,19.3947,311.5052}
};
new ASpawnLocationsDumper[][TSpawnLocation] =
{
{821.0770,861.7659,16.0667,254.5322} // bánya
};
new ASpawnLocationsVonatDriver[][TSpawnLocation] =
{
{-1952.1995,120.4660,26.2813,230.9574}, // SF
{837.9533,-1372.2104,-0.5015,142.1015},
{2830.6335,83.0059,27.5130,81.7767},
{2852.2141,1290.7085,11.3906,273.8560},
{1408.5400,2625.5303,11.3926,309.3354}
};
« Utoljára szerkesztve: 2012. június 18. - 21:03:01 írta jozsi0502 »

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal