Salut Deci Am Sa va Arat Un Tutorial Cum sa Faci O FUnctie Mai Scurta

Sa Incepem Prima Oara

[pawn]#include <a_samp>[/pawn]

Dupaia

Va dau eu un exemplu aici happy
[pawn]#define SPP SetPlayerPos[/pawn]

am Facut Si O Comanda Pt voi sa Vedeti happy

[pawn]#define SCM SendClientMessage
#define SPH SetPlayerHealth
#define SPA SetPlayerArmour
#define SPD ShowPlayerDialog
#define D_S_P DIALOG_STYLE_PASSWORD
#define SGT SetGameModeText
#define APC AddPlayerClass
#define SPP SetPlayerPos
#define SPCP SetPlayerCameraPos
#define SPCL SetPlayerCameraLookAt
#define GTFA GameTextForAll
#define GPM GivePlayerMoney
#define SPS SetPlayerScore
#define PASFP PlayAudioStreamForPlayer
#define SPSFP StopAudioStreamForPlayer
#define CO CreateObject[/pawn]

asa Acuma COmanda Cu Functiile

[pawn]if (strcmp("/test", cmdtext, true, 10) == 0)
{
new string[200];
SCM(playerid,-1,"Test Madafakaaaa");
SPH(playerid,100);
SPA(playerid,100);
SPD(playerid,-1,D_S_P,"Test", string, "Ok", "Cancel");
GPM(playerid,10000);
SPS(playerid,10000);
PASFP(playerid, "http://somafm.com/tags.pls");
SPSFP(playerid);
return 1;
}[/pawn]

OnGameModeInit

[pawn]public OnGameModeInit()
{

SGT("Test Script");
APC(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
CO(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
return 1;
}[/pawn]

[pawn]public OnPlayerRequestClass(playerid, classid)
{
SPP(playerid, 1958.3783, 1343.1572, 15.3746);
SPCP(playerid, 1958.3783, 1343.1572, 15.3746);
SPCL(playerid, 1958.3783, 1343.1572, 15.3746);
return 1;
}[/pawn]


Cam Atat Este Tutorialu Deci ati inteles

Puneti In Tot Deauna
[pawn]#define Numele si Functia![/pawn]

Sper Ca Va Ajutat happy
See Yea

Sursa:www.sa-mp.ro/forum/index.php/topic,20544.0.html