<?xml version="1.0" encoding="ISO-8859-1"?>

<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		<title>SA-MP Forums - Includes</title>
		<link>http://forum.sa-mp.com/</link>
		<description>Script includes releases.</description>
		<language>en</language>
		<lastBuildDate>Mon, 20 May 2013 16:18:05 GMT</lastBuildDate>
		<generator>vBulletin</generator>
		<ttl>60</ttl>
		<image>
			<url>http://forum.sa-mp.com/images/misc/rss.jpg</url>
			<title>SA-MP Forums - Includes</title>
			<link>http://forum.sa-mp.com/</link>
		</image>
		<item>
			<title><![CDATA[[Include] "stringh.inc": Implementing useful functions from C's "string.h"]]></title>
			<link>http://forum.sa-mp.com/showthread.php?t=437944&amp;goto=newpost</link>
			<pubDate>Sat, 18 May 2013 01:22:55 GMT</pubDate>
			<description><![CDATA[About "stringh.inc": 
 
Hey... guess this is my first release here. Anyway, some of you (depending where you've come from) might know me as "Lunghi"....]]></description>
			<content:encoded><![CDATA[<div><i><font face="Georgia"><font color="Orange"><font size="7">About &quot;stringh.inc&quot;:</font></font></font></i><br />
<br />
Hey... guess this is my first release here. Anyway, some of you (depending where you've come from) might know me as &quot;Lunghi&quot;.<br />
<br />
This include is released under the Mozilla Public License v2.0 (MPL v2.0) and is a collection of macros seeking to build upon SA:MP's solid foundations in terms of support for string manipulation and add functionality for slightly more obscure functions, taken from the C standard. The aim from the start was to emulate the most useful, and at the time missing functions from &quot;string.h&quot;.<br />
<br />
<i><b><font face="Georgia"><font size="3">Functions included (click hyperlinks for function documentation):</font></font></b></i><br />
<ol style="list-style-type: decimal"><li><a href="http://www.cplusplus.com/reference/cstring/strcpy/" target="_blank">strcpy</a></li>
<li><a href="http://www.cplusplus.com/reference/cstring/strncpy/" target="_blank">strncpy</a></li>
<li><a href="http://www.cplusplus.com/reference/cstring/strncat/" target="_blank">strncat</a></li>
<li><a href="http://www.cplusplus.com/reference/cstring/strcmp/" target="_blank">strcmp</a></li>
<li><a href="http://www.cplusplus.com/reference/cstring/strncmp/" target="_blank">strncmp</a></li>
<li><a href="http://invisionfree.com/forums/CPPlearningcommunity/ar/t4874.htm" target="_blank">strcasecmp</a></li>
<li><a href="http://invisionfree.com/forums/CPPlearningcommunity/ar/t4874.htm" target="_blank">strncasecmp</a></li>
</ol><br />
Some of the definitions might seem useless, but the idea behind those particular definitions is to give PAWN a more C-like experience, for those who feel more comfortable with it, without mandating said preference for everybody else.<br />
<br />
In the source code, it is explained how to use each of these functions, with additional information about them alongside.<br />
<br />
I am not sure how often any of these will be useful, but hopefully they make life easier for someone either coming over from C or C++, or someone who needs to use one of the more advanced features not available yet in PAWN.<br />
<br />
I will be updating and maintining this as I see fit and on that note (<b>18/MAY/2013</b> - when the project was first uploaded), as I did this so late at night, there may be mistakes. If anyone notices any (there probably aren't any though), then just leave a message behind and I'll fix it ASAP.<br />
<br />
Documentation may come later (if necessary), as with an extended post and a better explanation in the body of this post about the functions.<br />
<br />
<b>Download (and source):</b> <a href="http://pastebin.com/LjQGUsQN" target="_blank">http://pastebin.com/LjQGUsQN</a> (Version: v0.5)<br />
<b>Credits: None (removed previous credited function(s) from the include)</b><br />
<b>Licence:</b> <a href="http://www.mozilla.org/MPL/2.0/" target="_blank">Mozilla Public License v2.0 (MPL v2.0)</a></div>

]]></content:encoded>
			<category domain="http://forum.sa-mp.com/forumdisplay.php?f=83">Includes</category>
			<dc:creator>Aeonosphere</dc:creator>
			<guid isPermaLink="true">http://forum.sa-mp.com/showthread.php?t=437944</guid>
		</item>
		<item>
			<title><![CDATA[[Include] Church System [Create church system/mission in one line]]]></title>
			<link>http://forum.sa-mp.com/showthread.php?t=437812&amp;goto=newpost</link>
			<pubDate>Fri, 17 May 2013 12:22:02 GMT</pubDate>
			<description><![CDATA[Church System  
[Create church system/mission in one line] 
 
 
*Introduction* 
 
I get this idea from Anak's Church System. 
 
You can create church...]]></description>
			<content:encoded><![CDATA[<div><font color="Orange"><font size="6"><div align="center">Church System <br />
[Create church system/mission in one line]</div></font></font><br />
<br />
<b>Introduction</b><br />
<br />
I get this idea from Anak's Church System.<br />
<br />
You can create church in one line. <br />
There is 4 callbacks to check if player enter/exit on church checkpoint.<br />
There is 2 callbacks to check if player enter/exit on church vehicle.<br />
There is 2 callbacks to check if player enter mission/enter a mission (double mission)<br />
<br />
4 function related all about church (If Church Exist/Vehicles/Entrance/Exit Points)<br />
5 function related all about church mission (Setting/Starting/Stopping/Next)<br />
<br />
You can either create church if it is enterable. If it is enterable. You can teleport him in a interior or in a place (although you can still do this when enterable is set to 0)<br />
<br />
If it is 0. You can only show it for menus. OnPlayerExitChurchMenu gets called when leave the checkpoint, still can be used for teleporting. <br />
<br />
<b>Callback</b><br />
<br />
OnPlayerEnterChurchMenu(playerid, churchid)<br />
parameters: playerid, churchid<br />
<br />
• Gets called when player enter the church cp (Only gets called if the church is created with enterable set to 0)<br />
<br />
OnPlayerExitChurchMenu(playerid, churchid)<br />
parameters: playerid, churchid<br />
<br />
• Gets called when player leave the church cp (Only gets called if the church is created with enterable set to 0)<br />
<br />
OnPlayerEnterChurch(playerid, churchid)<br />
parameters: playerid, churchid<br />
<br />
• Gets called when player enter the church cp (Only gets called if the church is created with enterable set to 1)<br />
<br />
OnPlayerEnterCEPoint(playerid, churchid)<br />
parameters: playerid, churchid<br />
<br />
• Gets called when player leave the church cp (Only gets called if the church is created with enterable set to 1)<br />
Note: The churchid isn't base on CreateChurch. It is base on SetChurchExit's churchid.<br />
<br />
OnPlayerEnterChurchVehicle(playerid, vehicleid, ispassenger)<br />
parameters: Same with OnPlayerEnterVehicle<br />
<br />
• Gets called when player enter the church vehicle<br />
<br />
OnPlayerExitChurchVehicle(playerid, vehicleid)<br />
parameters: playerid, vehicleid<br />
<br />
• Gets called when player exit the church vehicle<br />
<br />
OnPlayerEnterChurchMission(playerid)<br />
parameters: playerid<br />
<br />
• Gets called if the church mission is about 1 delivering only. <br />
<br />
OnPlayerEnterChurchMissionEx(playerid)<br />
parameters: playerid<br />
<br />
• Gets called if the church mission is more than 1 delivering mission (NextChurchMission)<br />
<br />
<b>Function</b><br />
<br />
CreateChurch(enterable = 0, interior = -1, world = -1, Float:cpsize = 2.0, Float:churchx, Float:churchy, Float:churchz, Float:churchdistance = 100.0)<br />
<br />
• enterable = if it is 0. OnPlayerEnter/ExitChurchMenu gets called. If it is 1. OnPlayerEnterChurch gets called instead.<br />
• interior = where interior can the church can be seen<br />
• world = where virtual world can the church can be seen.<br />
• cpsize = the checkpoint size for the church.<br />
• churchx, y, z = x, y, z coordinates<br />
• churchdistance = if player is not in the range of churchdistance the checkpoint disappears.<br />
<br />
SetChurchExit(&amp;id, interior = -1, world = -1, Float:cpsize = 2.0, Float:churchx, Float:churchy, Float:churchz, Float:churchdistance = 100.0)<br />
<br />
• Same with CreateChurch but with id parameter<br />
• id - stores the exit point id.<br />
<br />
SpawnChurchVehicle(vehicleid, Float:spawnx, Float:spawny, Float:spawnz, Float:spawnangle, color1, color2, spawndelay)<br />
<br />
• Like AddStaticVehicleEx. But when entered/exit on it. OnPlayerEnter/ExitChurchVehicle is called. <br />
<br />
StartChurchMission(playerid, Float:mx, Float:my, Float:mz, Float:cpsize = 5.0)<br />
<br />
• Like SetPlayerCheckpoint. Difference. Calls the callback OnPlayerEnterChurchMission<br />
<br />
NextChurchMission(playerid, Float:mx, Float:my, Float:mz, Float:cpsize = 5.0)<br />
<br />
• Like StartChurchMission. Difference. It can create more delivering mission more than 1. Calls the callback OnPlayerEnterChurchMissionEx.<br />
<br />
SetChurchMission(playerid, mission)<br />
<br />
• If setted to -1. It stops the mission and disables the checkpoint.<br />
<br />
GetChurchMission(playerid)<br />
<br />
• Gets the current church mission, returns integer not a string!<br />
<br />
IsValidChurch(churchid)<br />
<br />
• Checks if the church is created or not. if checking if it doesn't exist use (!) (without paranthesis)<br />
<br />
<b>Notices</b><br />
<br />
- You need latest version of streamer to make this work<br />
- use the church.pwn from the .rar file to see how to use it.<br />
- OnPlayerEnterMission cannot use GetChurchMission(playerid) &gt;= 1 since it only gets called for 1 delivering mission only.<br />
<br />
- OnPlayerEnterMissionEx needs GetChurchMission to make it function properly since it has no missionid parameter on the callback.<br />
<br />
Like<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">pawn Code:</div>
	<pre class="alt2" style="margin:0px; padding:6px; border: 1px solid #C2C2C2; width:800px; height:151px; overflow:auto"><div dir="ltr" style="text-align:left;"><div class="pawn" style="font-family:monospace;"><span style="color: #2222BB;">if</span><span style="color: #000000;">&#40;</span>GetChurchMission<span style="color: #000000;">&#40;</span>playerid<span style="color: #000000;">&#41;</span> <span style="color: #000000;">==</span> <span style="color: #000000;">1</span><span style="color: #000000;">&#41;</span> <span style="color: #228822;">//The nextchurchmission from OnPlayerEnterMission</span><br /><span style="color: #000000;">&#123;</span><br /><span style="color: #228822;">//code - nextchurchmission if needed</span><br /><span style="color: #000000;">&#125;</span><br /><span style="color: #2222BB;">else</span> <span style="color: #2222BB;">if</span><span style="color: #000000;">&#40;</span>GetChurchMission<span style="color: #000000;">&#40;</span>playerid<span style="color: #000000;">&#41;</span> <span style="color: #000000;">==</span> <span style="color: #000000;">2</span><span style="color: #000000;">&#41;</span><br /><span style="color: #000000;">&#123;</span><br /><span style="color: #228822;">//mission ended - code</span><br /><span style="color: #000000;">&#125;</span></div></div></pre>
</div><br />
<b>Screenshot</b><br />
<br />
<img src="http://i.imgur.com/EpkBjvi.jpg" border="0" alt="" /><br />
<img src="http://i.imgur.com/MD625xD.jpg" border="0" alt="" /><br />
<img src="http://i.imgur.com/GGknZ3Y.jpg" border="0" alt="" /><br />
<br />
<b>Downloadlink</b><br />
<br />
<a href="http://pastebin.com/M2A21jVd" target="_blank">Pastebin</a><br />
<a href="http://www.solidfiles.com/d/ca383c4762/" target="_blank">Solidfiles</a></div>

]]></content:encoded>
			<category domain="http://forum.sa-mp.com/forumdisplay.php?f=83">Includes</category>
			<dc:creator>_Jake_</dc:creator>
			<guid isPermaLink="true">http://forum.sa-mp.com/showthread.php?t=437812</guid>
		</item>
		<item>
			<title><![CDATA[[Include] Days [BETA]]]></title>
			<link>http://forum.sa-mp.com/showthread.php?t=437328&amp;goto=newpost</link>
			<pubDate>Wed, 15 May 2013 08:35:24 GMT</pubDate>
			<description>*Days 
* 
No known bugs as of now, although if you find some, report them 
 
IF no bugs are found, next update will be in July. 
 
 
#define    ...</description>
			<content:encoded><![CDATA[<div><b><font size="6"><div align="center">Days</div></font></b><br />
No known bugs as of now, although if you find some, report them<br />
<br />
IF no bugs are found, next update will be in July.<br />
<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">pawn Code:</div>
	<pre class="alt2" style="margin:0px; padding:6px; border: 1px solid #C2C2C2; width:800px; height:343px; overflow:auto"><div dir="ltr" style="text-align:left;"><div class="pawn" style="font-family:monospace;"><span style="color: #2222AA;">#define &nbsp; &nbsp; JANUARY &nbsp; &nbsp; 1</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; FEBRUARY &nbsp; &nbsp;2</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; MARCH &nbsp; &nbsp; &nbsp; 3</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; APRIL &nbsp; &nbsp; &nbsp; 4</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; MAY &nbsp; &nbsp; &nbsp; &nbsp; 5</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; JUNE &nbsp; &nbsp; &nbsp; &nbsp;6</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; JULY &nbsp; &nbsp; &nbsp; &nbsp;7</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; AUGUST &nbsp; &nbsp; &nbsp;8</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; SEPTEMBER &nbsp; 9</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; OCTOBER &nbsp; &nbsp; 10</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; NOVEMBER &nbsp; &nbsp;11</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; DECEMBER &nbsp; &nbsp;12</span><br /><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; MONDAY &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; 0</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; TUESDAY &nbsp; &nbsp; &nbsp; &nbsp; 1</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; WEDNESDAY &nbsp; &nbsp; &nbsp; 2</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; THURSDAY &nbsp; &nbsp;&nbsp; &nbsp; 3</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; FRIDAY &nbsp;&nbsp; &nbsp; 4</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; SATURDAY &nbsp; &nbsp;&nbsp; &nbsp; 5</span><br /><span style="color: #2222AA;">#define &nbsp; &nbsp; SUNDAY &nbsp;&nbsp; &nbsp; 6</span></div></div></pre>
</div><br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">pawn Code:</div>
	<pre class="alt2" style="margin:0px; padding:6px; border: 1px solid #C2C2C2; width:800px; height:135px; overflow:auto"><div dir="ltr" style="text-align:left;"><div class="pawn" style="font-family:monospace;"><span style="color: #2222BB;">native</span> GetMonthName<span style="color: #000000;">&#40;</span>month<span style="color: #000000;">&#41;</span>; <span style="color: #228822;">//number of month OR the NAME of the month in CAPITAL LETTERS</span><br /><span style="color: #2222BB;">native</span> GetDayName<span style="color: #000000;">&#40;</span>day<span style="color: #000000;">&#41;</span>; <span style="color: #228822;">// NUMBER of DAY or name of DAY in CAPITAL letters [0 TO 6]</span><br /><span style="color: #2222BB;">native</span> GetCurrentMonth<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>; <span style="color: #228822;">// returns the current month</span><br /><span style="color: #2222BB;">native</span> GetCurrentDay<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>; <span style="color: #228822;">// returns the current DATE</span><br /><span style="color: #2222BB;">native</span> IsLeapYear<span style="color: #000000;">&#40;</span>year<span style="color: #000000;">&#41;</span>; <span style="color: #228822;">// returns if the INPUT YEAR is a LEAP YEAR</span><br /><span style="color: #2222BB;">native</span> GetMonthDays<span style="color: #000000;">&#40;</span>month<span style="color: #000000;">&#41;</span>; <span style="color: #228822;">// RETURNS THE NUMBER OF DAYS OF THE INPUT MONTH</span><br /><span style="color: #2222BB;">native</span> GetDay<span style="color: #000000;">&#40;</span>date, month, year<span style="color: #000000;">&#41;</span>; <span style="color: #228822;">// returns the &gt;&gt; DAY &lt;&lt; (NOT DATE)</span></div></div></pre>
</div><br />
<br />
BETA V1 - <a href="http://pastebin.com/9tH7Bkqp" target="_blank">http://pastebin.com/9tH7Bkqp</a><br />
<br />
<br />
Test code -<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">pawn Code:</div>
	<pre class="alt2" style="margin:0px; padding:6px; border: 1px solid #C2C2C2; width:800px; height:87px; overflow:auto"><div dir="ltr" style="text-align:left;"><div class="pawn" style="font-family:monospace;">main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #000000;">&#123;</span><br />&nbsp; &nbsp; <span style="color: #222222;">printf</span><span style="color: #000000;">&#40;</span><span style="color: #000066;">&quot;%s&quot;</span>, GetDayName<span style="color: #000000;">&#40;</span>GetDay<span style="color: #000000;">&#40;</span><span style="color: #000000;">15</span>, JULY, <span style="color: #000000;">2013</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>;<br /><span style="color: #000000;">&#125;</span></div></div></pre>
</div></div>

]]></content:encoded>
			<category domain="http://forum.sa-mp.com/forumdisplay.php?f=83">Includes</category>
			<dc:creator>CreativityLacker</dc:creator>
			<guid isPermaLink="true">http://forum.sa-mp.com/showthread.php?t=437328</guid>
		</item>
	</channel>
</rss>
