Üdv . Készitettem 1 Postás Munka FilterScriptet!
Készitési idõ : 5 perc
Készitette : Blade.
Parancsok:
-/posta
-/munkakezd
-/felmond
Extra:
3 percenként fizetés : 100.000 $
PVarral lett elkészitve.
#include <a_samp>
#include zcmd
#if defined FILTERSCRIPT
#define POSTAS 1
#define NemPostas 2
#define COLOR_RED 0xFF0000AA
new Float: Cimzet[][3] =
{
{2208.7939,-89.5540,27.2060},
{2199.3223,-60.4340,28.1535},
{2245.4441,-2.5914,28.1536},
{2270.9336,-9.1012,28.1535},
{2293.7800,-124.4951,28.1535},
{2321.7454,-123.8729,28.1536},
{2367.1797,-47.7296,28.1535},
{2383.9070,-53.9904,28.1536},
{2415.6831,-51.2760,28.1535},
{2438.6204,-53.4686,28.1535}
};
forward fizetes(playerid);
CMD:posta(playerid)
{
SetPVarInt(playerid,\"Postás\",POSTAS);
SetPlayerPos(playerid,2438.6204,-53.4686,28.1535);
new
str[200],
name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(str,200,\"%s postásnak állt! /posta\",name);
SendClientMessageToAll(5,str);
SendClientMessage(playerid,10,\"Szálj bele a Pony-ba!!\");
SendClientMessage(playerid,10,\"ÉS írd be hogy /munkakezd!\");
return 1;
}
CMD:munkakezd(playerid,params[])
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 413)
{
if(GetPVarInt(playerid,\"Postás\",POSTAS);
{
SendClientMessage(playerid,COLOR_RED,\"Elkezdted a munkát! Menj a cimzetekhez!\");
new rand = random(sizeof(Cimzet));
SetPlayerCheckpoint(playerid,rand[Cimzet][0],rand[Cimzet][1],rand[Cimzet][2],4.0\");
}
else if(GetPVarInt(playerid,\"NemPostas\",NemPostas);
SendClientMessage(playerid,COLOR_RED,\"Nem vagy postás!\");
}
return 1;
}
CMD:felmond(playerid)
{
SetPVarInt(playerid,\"NemPostas\",NemPostas);
SendClientMessage(playerid,10,\"Felmondtál!\");
DisablePlayerCheckPoint(playerid);
KillTimer(fizetes);
return 1;
}
public OnFilterScriptInit()
{
print(\"\\n--------------------------------------\");
print(\" Postás Munka By Blade.\");
print(\"--------------------------------------\\n\");
AddStaticVehicle(413,2261.1089,-83.5065,26.5998,180.7293,4,6); // postás1
AddStaticVehicle(413,2256.2217,-82.2238,26.6119,182.6032,42,1); //
AddStaticVehicle(413,2254.3625,-93.2671,26.4908,89.4322,36,90); // postás3
SetTimer(\"fizetes\",200000,true);
return 1;
}
public OnFilterScriptExit()
{
DestroyVehicle(413);
DestroyVehicle(413);
DestroyVehicle(413);
DisablePlayerCheckpoint(playerid);
KillTimer(fizetes);
return 1;
}
public OnPlayerEnterCheckpoint(playerid)
{
new rand = random(sizeof(Cimzet));
SetPlayerCheckpoint(playerid,rand[Cimzet][0],rand[Cimzet][1],rand[Cimzet][2],4.0\");
new penz = random(100);
GivePlayerMoney(playerid,penz);
return 1;
}
public fizetes(playerid)
{
GivePlayerMoney(playerid,100000);
SendClientMessage(playerid,COLOR_RED,\"Fizetést Kaptál!!\");
SendClientMessage(playerid,COLOR_RED,\"Legközelebbi 3 perc múlva!!\");
SendClientMessage(playerid,COLOR_RED,\"Jó Munkát!\");
return 1;
}
#endif