[FilterScript] [FS] Bomber script / MapAndreas usage example
#21

Quote:
Originally Posted by braduz
there was only 1 file included
Yeah, but it would take 5 seconds to search for it:
http://forum.sa-mp.com/index.php?topic=145196.0
Reply
#22

would be fun to do with hydra, or rustler.. or maybe a RC Baron!
Reply
#23

http://forum.sa-mp.com/index.php?top...0058#msg880058

http://darkbyte.ath.cx/samp/zmap.inc
Reply
#24

Very nice.
Reply
#25

I Love this script
Reply
#26

haha i love this
Reply
#27

Hi, i like very your FS and i have make it with your ideas to understand how this work, but i have a problem when i press the FIRE_KEY this make nothing 0_0 and make lag the map but not the computer, the map bug and after few time this stop bug but nothing please can you help me ?


Код:
#include <a_samp>
#include <mapandreas>

#define MAX_ROCKET 150
new Rocket[MAX_PLAYERS][MAX_ROCKET];
new Bomb[MAX_PLAYERS];


#define RELEASED(%0) \
	(((newkeys & (%0)) != (%0)) && ((oldkeys & (%0)) == (%0)))

#define PRESSED(%0) \
	(((newkeys & (%0)) == (%0)) && ((oldkeys & (%0)) != (%0)))


public OnFilterScriptInit()
{
	MapAndreas_Init(2);

	print("\n--------------------------------------");
	print(" Blank Filterscript by your name here");
	print("--------------------------------------\n");
	return 1;
}

public OnFilterScriptExit()
{
	return 1;
}

main()
{
	print("\n----------------------------------");
	print(" Blank Gamemode by your name here");
	print("----------------------------------\n");
}


public OnPlayerRequestClass(playerid, classid)
{
	return 1;
}

public OnPlayerConnect(playerid)
{
	return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
	return 1;
}

public OnPlayerText(playerid, text[])
{
	return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
	if (strcmp("/mycmd", cmdtext, true, 10) == 0)
	{
		return 1;
	}
	return 0;
}

public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
	return 1;
}

public OnPlayerStateChange(playerid, newstate, oldstate)
{
	return 1;
}

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
	if(RELEASED(KEY_FIRE))
	{
		KillTimer(Bomb[playerid]);
		return 1;
	}
	else if(PRESSED(KEY_FIRE))
	{
		if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 592 || GetVehicleModel(GetPlayerVehicleID(playerid)) == 553 || GetVehicleModel(GetPlayerVehicleID(playerid)) == 476)
		{
			new Float:X,Float:Y,Float:Z,Float:FZ;
			GetPlayerPos(playerid, X, Y, Z);
			MapAndreas_FindZ_For2DCoord(X, Y, FZ);
	 		if(FZ < (Z - 2.0))
	 		{
				Bomb[playerid] = SetTimerEx("Bombing", 100, true, "i", playerid);
			}
			else
			{
	 			SendClientMessage(playerid, 0xFFFFFFFF, "Your current Z co-ord is lower than the ground Z co-ordinate - offset!");
	 			SendClientMessage(playerid, 0xFFFFFFFF, "Make sure you're not landed nor below bridges/inside buildings");
			}
			return 1;
		}
	}

	return 1;
}


forward Bombing(playerid);
public Bombing(playerid)
{
	for(new RocketID=0;RocketID<MAX_ROCKET;RocketID++)
	{
		new Float:X,Float:Y,Float:Z,Float:FZ;
		GetPlayerPos(playerid, X, Y, Z);
		Rocket[playerid][RocketID] = CreateObject(3790, X, Y, Z-2.0, 0.0, 0.0, 0.0);
		MapAndreas_FindZ_For2DCoord(X, Y, FZ);
		MoveObject(Rocket[playerid][RocketID], X, Y, FZ, 5.0);
	}
	return 1;
}


public OnObjectMoved(objectid)
{
	for(new pid=0;pid<MAX_PLAYERS;pid++)
	{
 		for(new RocketID=0;RocketID<MAX_ROCKET;RocketID++)
 		{
  			if(Rocket[pid][RocketID] == objectid)
  			{
   			new Float:X, Float:Y, Float:Z;
				GetObjectPos(objectid, X, Y, Z);
				WhenBombTuchGround(X, Y, Z);
				DestroyObject(objectid);
				Rocket[pid][RocketID] = 0;
	    }
	  }
	}
}

forward WhenBombTuchGround(Float:X, Float:Y, Float:Z);
public WhenBombTuchGround(Float:X, Float:Y, Float:Z)
{
  CreateExplosion(X, Y, Z, 7, 2.0);
  return 1;
}
Reply
#28

great work
Reply
#29

Any mirrors?

I need it to see how can I use MapAndreas
Reply
#30

The download link does not work.
Reply
#31

Plz give me download link new The download link now not work
Reply
#32

Plz give me download link new The download link now not work
Reply
#33

Change the download link & share it.

DOWNLOAD LINK !! Put a new one, I need this
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)