Send message when patrol heli enters map?Solved
How would i go about using the onentityspawned hook to put a message in the console when the patrol heli enters the map? 
There is already a plugin called "Inbound" that already does that.
here you go king a simple way is to check if entity that spawns id the cargoship

void OnEntitySpawned(BaseNetworkable entity)
        {
            if(entity.PrefabName == " assets/content/vehicles/boats/cargoship/cargoshiptest.prefab")
            {
                //do stuff
            }
        }​
thanks so much!

you can cut that down even more 

void OnEntitySpawned(BaseEntity entity)
        {
            if(entity is CargoShip))
            {
                //do stuff
            }
        }


Merged post

I use ^^ in one of my creations...

then with one of the following 

BradleyAPC
CargoPlane
CargoShip
CH47Helicopter
BaseHelicopter
ScrapTransportHelicopter
MiniCopter
RidableHorse
HotAirBalloon
OreResourceEntity
CollectibleEntity
BaseBoat
BaseAnimalNPC​
thanks, i will keep that in mind
cheers orange
Locked automatically