Serega_Blink
Изучающий
- Регистрация
- 6 Июл 2011
- Сообщения
- 687
- Лучшие ответы
- 0
- Репутация
- 65
Добрый день!
Этот скрипт позволяет работать фальшивомонетчиком!
Устроиться и купить бумагу можно у магазина 24\7 лс у Юнити Стейшен (Станция Юнити). Распечатать можно у респы вагос в трубе у моста.
Вот он сам:
Скрипт работает с mxINI, только почему-то не работает сохранение бумаги(деньги сохраняются!).
Автор : LeoLivorno
Этот скрипт позволяет работать фальшивомонетчиком!
Устроиться и купить бумагу можно у магазина 24\7 лс у Юнити Стейшен (Станция Юнити). Распечатать можно у респы вагос в трубе у моста.
Вот он сам:
PHP:
//---------------------------------------------------------------------------//
#include <a_players>
#include <a_objects>
#include <a_samp>
#include <mxINI>
//---------------------------------------------------------------------------//
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_GREY 0xAFAFAFAA
//---------------------------------------------------------------------------//
#define NET_BUMAGI SendClientMessage(playerid, COLOR_GREY, "Íåò áóìàãè!");
#define NET_DENEG SendClientMessage(playerid, COLOR_GREY, "Íåò äåíåã!");
#define DALEKO SendClientMessage(playerid, COLOR_GREY, "Âû äàëåêî!");
#define NET_RABOTA SendClientMessage(playerid, COLOR_GREY, "Âû íå ðàáîòàåòå ôàëüøèâîìîíåò÷èêîì!");
#define EST_RABOTA SendClientMessage(playerid, COLOR_GREY, "Âû óæå ðàáîòàåòå ôàëüøèâîìîíåò÷èêîì!");
#define FS_VERSION "Ôàëüøèâîìîíåò÷èêè 1.0"
//---------------------------------------------------------------------------//
new string[128];
new vhod, vihod;
new job;
new fs[MAX_PLAYERS];
new PlayerName[MAX_PLAYERS];
//---------------------------------------------------------------------------//
enum pFS
{
pBumaga,
}
//---------------------------------------------------------------------------//
new FSInfo[MAX_PLAYERS][pFS];
//---------------------------------------------------------------------------//
forward SaveBumaga();
forward LoadBumaga();
forward PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z);
//---------------------------------------------------------------------------//
public OnFilterScriptInit()
{
vhod = AddStaticPickup(1239, 23, 2711.6458,-1424.3062,16.2500);
vihod = AddStaticPickup(1239, 23, 2713.4529,-1424.2330,16.2500);
job = AddStaticPickup(1239, 23, 1832.8685,-1847.3293,13.5781);
LoadBumaga();
format(string, sizeof(string), "%s - çàãðóæåí", FS_VERSION);
printf(string);
Create3DTextLabel("~~~~~~~~~~~~~~~~~~\nÊóïèòü áóìàãó: /buydbumaga\n~~~~~~~~~~~~~~~~~~", COLOR_GREEN, 1847.7197,-1871.7141,13.5781, 15, 0, 0);
Create3DTextLabel("~~~~~~~~~~~~~~~~~~\nÓñòðîèòñÿ ôàëüøèâîìîíåò÷èêîì: /job\n~~~~~~~~~~~~~~~~~~", COLOR_GREEN, 1832.8685,-1847.3293,13.5781, 15, 0, 0);
Create3DTextLabel("~~~~~~~~~~~~~~~~~~\nÍà÷àòü ïå÷àòàòü äåíüãè: /makemoney\n~~~~~~~~~~~~~~~~~~", COLOR_GREEN, 2738.4976,-1421.9766,17.6731, 15, 0, 0);
return 1;
}
//---------------------------------------------------------------------------//
public OnFilterScriptExit()
{
SaveBumaga();
format(string, sizeof(string), "%s - âûãðóæåí", FS_VERSION);
printf(string);
return 1;
}
public OnPlayerSpawn(playerid)
{
fs[playerid] = 0;
return 1;
}
//---------------------------------------------------------------------------//
public SaveBumaga()
{
new bumaga = FSInfo[pFS][pBumaga];
new iniFile = ini_openFile("bumaga.ini");
ini_setInteger(iniFile, "Bumaga",bumaga);
return 1;
}
//---------------------------------------------------------------------------//
public LoadBumaga()
{
new bumaga = FSInfo[pFS][pBumaga];
new iniFile = ini_openFile("bumaga.ini");
ini_getInteger(iniFile,"Bumaga",bumaga);
return 1;
}
//---------------------------------------------------------------------------//
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/buybumaga", cmdtext, true, 10) == 0)
{
if(PlayerToPoint(10.0,playerid,1847.7197,-1871.7141,13.5781))
{
if(GetPlayerMoney(playerid) >= 100)
{
if(fs[playerid] == 1)
{
FSInfo[pFS][pBumaga] += 500;
SendClientMessage(playerid, COLOR_YELLOW, "Âû êóïèëè 500 ëèñòîâ áóìàãè");
return 1;
}
else
{
NET_RABOTA
return 1;
}
}
else
{
NET_DENEG
return 1;
}
}
else
{
DALEKO
return 1;
}
}
if (strcmp("/job", cmdtext, true, 10) == 0)
{
if(PlayerToPoint(5.0, playerid, 1832.8685,-1847.3293,13.5781))
{
SendClientMessage(playerid, COLOR_YELLOW, "Âû óñòðîèëèñü ôàëüøèâîìîíåò÷èêîì");
fs[playerid] = 1;
return 1;
}
else
{
DALEKO
return 1;
}
}
if (strcmp("/makemoney", cmdtext, true, 10) == 0)
{
if(FSInfo[pFS][pBumaga] >=100)
{
if(PlayerToPoint(5.0, playerid, 2738.0103,-1423.1763,16.2562))
{
if(fs[playerid] == 1)
{
new makemoney = random(1000);
GetPlayerName(playerid, PlayerName, 30);
format(string, sizeof(string), "%s íàïå÷àòàë %d ôàëüøèâûõ äåíåã", PlayerName, makemoney);
SendClientMessage(playerid, COLOR_YELLOW, string);
GivePlayerMoney(playerid, makemoney);
FSInfo[pFS][pBumaga] -= 100;
return 1;
}
else
{
NET_RABOTA
return 1;
}
}
else
{
DALEKO
return 1;
}
}
else
{
NET_BUMAGI
return 1;
}
}
if (strcmp("/test", cmdtext, true, 10) == 0)
{
fs[playerid] = 1;
return 1;
}
return 0;
}
//---------------------------------------------------------------------------//
public PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z)
{
if(IsPlayerConnected(playerid))
{
new Float:oldposx, Float:oldposy, Float:oldposz;
new Float:tempposx, Float:tempposy, Float:tempposz;
GetPlayerPos(playerid, oldposx, oldposy, oldposz);
tempposx = (oldposx -x);
tempposy = (oldposy -y);
tempposz = (oldposz -z);
if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
{
return 1;
}
}
return 0;
}
//---------------------------------------------------------------------------//
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == vhod)
{
if(fs[playerid] == 1)
{
SetPlayerPos(playerid, 2715.9849,-1424.1293,16.2500);
return 1;
}
else
{
NET_RABOTA
return 1;
}
}
if(pickupid == vihod)
{
if(fs[playerid] == 1)
{
SetPlayerPos(playerid, 2708.9441,-1424.4951,16.2500);
return 1;
}
else
{
NET_RABOTA
return 1;
}
}
if(pickupid == job)
{
return 1;
}
return 0;
}
Автор : LeoLivorno
Последнее редактирование: