02.07.2013, 16:12
Simple Commands & Functions
Client & ServerBefore you decide you want to script for your server, Make sure you have the latest server files from here: www.sa-mp.com/download.php and make sure your client is up to date too (Currently 0.3x is the latest).
Pawno
So, Make sure to have opened your server folder and have opened a program called 'Pawno'. Pawno is a complex scripting program used by mainly SA-MP scripters for handling and editing their server. Some people are obviously on different levels of expertise than others on scripting, So therefore this is a starters guide for those who may need help.
Simple Command
So, Under:
Code:
OnPlayerCommandText { return 1; }
Code:
SendClientMessage
Code:
SendClientMessage(playerid, 0xFFFFFF, "Replace me");
Lets get that straight.
Code:
SendClientMessage(playerid, 0xFFFFFF, "Replace me"); [The Function][Open Bracket][Target][comma][The colour][comma][speech marks][Text][speech marks][Close bracket][Semi Colon]
Code:
if (strcmp("/mycommand", cmdtext, true, 10) == 0) { SendClientMessage(playerid, 0xFFFFFF, "Replace me"); return 1; }
I hope that this will help those beginners to understand the meaning of "scripting" and now have a bit of knowledge about functions and declarations. More tutorials will be posted soon. Need help? PM me.
You are welcome to give me any feedback