Minefield Help. - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Minefield Help. (
/showthread.php?tid=442318)
Minefield Help. -
SilencedPistol - 06.06.2013
I want to create a minefield around Area 51 that only members of the Cop faction can use. I use ZCMD, Y_INI.
I don't really want you to tell me the command, just what functions to use and how to set it out, and which callback to place it under.
Re: Minefield Help. -
_chimera_ - 07.06.2013
pawn Код:
public OnPlayerUpdate(playerid)
{
if(GetPlayerPos(playerid, 210.4425,1908.4885,17.6406) return CreateExplosion(playerid,210.4425,1908.4885,17.6406);
return 1;
}
Re: Minefield Help. -
Hoborific - 07.06.2013
Use the Streamer plugin and use a DynamicArea, do NOT use OnPlayerUpdate, nobody needs to check if they are in a minefield and a certain faction 30+ times a second.
Re: Minefield Help. -
SilencedPistol - 07.06.2013
I was doing stuff like this:
pawn Код:
public OnPlayerConnect
{
if(PlayerInfo[playerid][Cop]
{
if(IsPlayerInRangeOfPoint(playerid, AREA51COORDINATES)) return CreateExplosion(playerid, AREA51COORDINATES))
}
Stuff like that was what I was doing, it was going wrong as you can imagine lol.