13.09.2011, 12:14
(
Последний раз редактировалось Kingunit; 13.09.2011 в 20:47.
)
How to work with 'includes'
Probably there are already tutorials about includes - but I've decide to creat a own one since alot of the new people don't know how to work with a include.
In this tutorial I will explain how to install them and I will give some examples of how to use them. Okay - let's start!
List of populair includes:
- sscanf plugin - Credits are going to ******
- y_ini include - Credits are going to ******
- foreach include - Credits are going to ******
- zcmd include - Credits are going to Zeex
- MySQL Plugin - Credits are going to G-sTyLeZzZ
- Streamer Plugin - Credits are going to Incognito
Anyway let's start. The first thing you need to do is downloading the plugin/include. You can also use the search function if you need another plugin or include. When the download process is finished you need to paste is in the correct folder. Open your server folder and then open the pawno folder. There is a folder called 'include' - open it and past your include / plugin file. (\pawno\include)
When you are using a plugin you need to drop the plugin in the correct folder! (Paste them both into the folder .dll and .so) Open your server file and there is a folder called 'plugins'. Copy and past your plugins into that folder. (yourserver\plugins)
Now - to get it working we need to include the plugin / include. It's not that hard it's really easy! At every scrip you see at the top:
pawn Код:
#include <a_samp>
pawn Код:
#include <a_samp>
#include <sscanf2>
#include <zcmd>
// Go on
Example:
pawn Код:
CMD:rules(playerid, params[])
{
SendClientMessage(playerid, 0xFFFFFFFF, "Rules: Do not cheat on my server!");
return 1;
}
Extra:
If you are using a 'plugin' you need to config it correct. Let's start! Open your config.cfg file from your server. Search the line:
Код:
plugins
Код:
filterscripts plugins
Код:
filterscripts plugins streamer
Let's goto the Linux part. When you download the plugin you will recieve two files. f ex. "Streamer.dll" and "Streamer.so". The windows users need to use the .dll version and Linux the .so version! If you don't know what your host is using - you can simply create a ticket to your hoster and use their support!
Example for the Linux users:
Код:
filterscipts plugins streamer.so
Thank you for reading my tutorial. I hope I've helped some new people out!
~ Kingunit