02.07.2009, 10:16
I wanted to try to make something from scratch using YSI, because I had just decided to use it.
And I wanted to make something a bit more advanced, because I'm just a bit above a novice.
So here is my script:
Surprisngly at this point it compiled well, except for something in the YSI include failed..
Here are my errors:
Help me please?
And I wanted to make something a bit more advanced, because I'm just a bit above a novice.
So here is my script:
Код:
#include <a_samp> #define FILTERSCRIPT #include <YSI> #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 forward ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5); //________________________________________________________________________________________ Script_OnPlayerCommandText(playerid, cmdtext[]) { dcmd(deal, 4, cmdtext); { dcmd(acceptdeal, 10, cmdtext); return 0; } dcmd_deal(playerid, params[]) { new id, text1[128], text2[210], deal[200], offered, playername[MAX_PLAYER_NAME]; if (sscanf(params, "us", id, deal)) return Text_Send(playerid, 0xFF0000AA, "USAGE: \"/deal <playerid> <text>\""), 1; if ( ! IsPlayerConnected(id) ) Text_Send(playerid, 0xFF0000AA, "Player Offline"); else { GetPlayerName(id, playername, MAX_PLAYER_NAME); format(text1, 127, "%s Wants you to accept a contract, the contract is as follows:", playername); format(text2, 199, "** %s **", deal); Text_Send(id, 0xFF0000AA, text1); Text_Send(id, 0x9EC73DAA, text2); Text_Send(id, 0xFF0000AA, "If you would like to accept please type /acceptdeal."); offered = 1; return 1; } dcmd_acceptdeal(playerid, params[]) { new id, accepted, text3[100], playername[MAX_PLAYER_NAME]; if offered = 1; GetPlayerName(id, playername, MAX_PLAYER_NAME); Text_Send(id, 0xFF0000AA, "You have accepted the deal, signing your name at the bottom"); format(text3, 99, "* %s grabs a pen, and continues to sign the contract, accepting it.", playername); ProxDetector(30.0, playerid, text3,0xC2A2DAAA,0xC2A2DAAA,0xC2A2DAAA,0xC2A2DAAA,0xC2A2DAAA); accepted = 1; return 1;
Here are my errors:
Код:
include\YSI/System/YSI_default.own(601) : error 004: function "OnPlayerRequestClassExFS" is not implemented include\YSI/System/YSI_default.own(808) : error 004: function "OnPlayerRequestSpawnExFS" is not implemented (44) : warning 203: symbol is never used: "Langs_AddFile" (44 -- 350) : warning 203: symbol is never used: "Langs_AddLanguage" (44 -- 350) : warning 203: symbol is never used: "Script_OnPlayerCommandText"