Jump to content
Sign in to follow this  
liquidpinky

Waskally Wabbit

Recommended Posts

I have just started delving into the wonderful world of mission editing and have a small vermin problem at an airport.

I have set a C130 to land and drop my team, with a trigger at the area the plane usually stops at when uninterrupted. But every now and again while testing I get a random rabbit running on the runway in front of the C130 after touchdown, the pilot being an animal lover brakes and when the plane is stopped my team get out prematurely and miss the trigger.

Is there any way of creating an exclusion zone to keep the rabbits off the runway, or do I have to add some form of super crack rabbit sniping team to keep them little fluffy gits off my tarmac?

Share this post


Link to post
Share on other sites

Well, in a realistic game, realistic problems may occur even if not planned by the dev.

Share this post


Link to post
Share on other sites
Well, in a realistic game, realistic problems may occur even if not planned by the dev.

So the semi realistic exterminator sniper team it is then, any way of setting rabbits to unfriendly so I can have shooters take them out?

Share this post


Link to post
Share on other sites

Well you could make the trigger area cover the entire landingsstrip/airport and then make a check to see if the plane is under 5m in the air and the speed is very low. Eg. this && getPosATL hercules select 2 < 5 && speed hercules < 1.0. Then the plane has to be in the trigger area, under 5m in the air, less than 1m/s in order to trigger.

Share this post


Link to post
Share on other sites
Well you could make the trigger area cover the entire landingsstrip/airport and then make a check to see if the plane is under 5m in the air and the speed is very low. Eg. this && getPosATL hercules select 2 < 5 && speed hercules < 1.0. Then the plane has to be in the trigger area, under 5m in the air, less than 1m/s in order to trigger.

Thanks, i will see what I can do with this.

I have a suspicion it won't help though as the plane is already set to unload miles from the airport, the only way it will land on the first aprouch. The trigger itself is just to split my team from the C130 and A10 flight group when the plane usualy taxis to the hangers and stops to unload, leaving my team ready to be controlled.

It unloads prematurly when it stops for the rabbit while still taxiing down the runway and no where near the hangars.

Share this post


Link to post
Share on other sites

Not saying that this is effective.. But it will take care of your problem..

_counter = 0;

_eliminated = false;

while {! _eliminated} do {

_units = count agents;

while {true} do {

if(_counter < _units)

then {

sleep 0.1;

_counter = _counter + 1;

_name = agent (agents select _counter);

_name setDamage 1;

}

else {

_eliminated = true;

if (_eliminated) exitWith {};

};

};

};

Hope you understand it and can adjust it to your needs. Cause this is not exactly what you need but its the right way. Jeez I feel dirty, I wrote a script that kills all animals :(

Share this post


Link to post
Share on other sites
Not saying that this is effective.. But it will take care of your problem..

_counter = 0;

_eliminated = false;

while {! _eliminated} do {

_units = count agents;

while {true} do {

if(_counter < _units)

then {

sleep 0.1;

_counter = _counter + 1;

_name = agent (agents select _counter);

_name setDamage 1;

}

else {

_eliminated = true;

if (_eliminated) exitWith {};

};

};

};

Hope you understand it and can adjust it to your needs. Cause this is not exactly what you need but its the right way. Jeez I feel dirty, I wrote a script that kills all animals :(

Thanks, a bit out of my league at the moment but these things I intend to learn. I take it I can run this script while the aircraft is approaching then have it nullified by my trigger at the hangers or similar?

You have done me and Elmer proud, "bye bye Bugs". :smiley-evil:

Share this post


Link to post
Share on other sites
Jeez I feel dirty, I wrote a script that kills all animals :(

Doesnt deletevehicle work on agents? Its much more humane..

Share this post


Link to post
Share on other sites
Doesnt deletevehicle work on agents? Its much more humane..

Either way is more humane than the current MK17 pest control method currently in operation.

Share this post


Link to post
Share on other sites

Problem with this is that the script only runs once and not all the time checking for new agents to be "deleted".

Also I am not certainly sure if it deletes them all or not.. So just test it and tell me the result.

p.s put a file in your mission folder call it "kill.sqf" and then in the trigger activation line put : _kill = []execVM "kill.sqf";

that would execute it.

Share this post


Link to post
Share on other sites

I'm not sure it works, if instead of killing them I move the player to them the player ends up in the sea, it could be the location of a seagull though.

Also I've not seen it kill any birds, as for rabbits they never seem to show when you want one.

The OFP guide doesn't explain what agent/agents is and how this would apply to animals.

Share this post


Link to post
Share on other sites

I tested it before I posted it..

+ Obviously your player gets moved there cause it goes so quick that you cant see it all. (that's my guess atleast )

So what you do is you place like 100 random animals on the editor and run the script.

Or you add the animal module and run it.

Edited by Joshii

Share this post


Link to post
Share on other sites

I did place a delay between the loops and it always puts me in the same place, but it does work if I placed animals.

It would also place me in that location if no animals are found so not conclusive.

It does make it difficult to test without placing animals.

Are placed animals the same as the natural occurring animals?

I just had a bird above me and a placed object in front of me and only the placed object got killed.

Share this post


Link to post
Share on other sites

Birds != the same

You can't shoot them i.e they are not registered.

However it works with the animal module so yes I am 100% confident that it works with the normal ones.

+ I tested it with the debug console

What happens is that the rabbits and so forth are spawned closed. And as soon as they are spawned they are in the script so basically what you would have to do to make it work is to run the script all the time.

Edited by Joshii

Share this post


Link to post
Share on other sites

Looking through the wiki today and come across the enableEnvironment command.

From what I gather I could add a trigger and have it disable the bunnehs and then re-enable them once the C130 has taxied clear of the runway.

I will give it a try and see what happens.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×