Jump to content
nomadd

Help removing snakes and rabbits

Recommended Posts

I know this topic has come up before, but I am trying to find a way to remove just snakes and rabbits when playing on dedicated. I checked some of the mods on steam but they do not seem to work or do not work on dedicated. 

I also found 

enableEnvironment [false, true];

but this removes everything, ARMA maps are already so deserted I hate to remove any more ambient life than necessary. 

I guess I am also confused, are the snakes and rabbits just server side or do they spawn local for each player, so each player will see different snakes and rabbits. The above command says it is local so makes me think I need to run it for each player.

I did find some code for running a while loop to remove snakes but was looking for a cleaner way.

 

The reason I am asking is I have a convoy mission, I know convoys and ARMA and the pain it will induce. Everything works great with the convoy and the mission, mainly because I control where things spawn so nothing can get in the way of the convoy.

Except freaking snakes, I have watched a 30 ton APC swerve to miss a snake crossing the road and can then cause a chain reaction in the convoy. Every vehicle after ,which ever vehicle swerves will then swerve even though nothing is in the road. Sometimes vehicles further down the line

in the convoy will just stop and refuse to move, so half the convoy will continue on and half just stop in place. It is a random problem and the only thing I have found that causes it is when an animal gets in the road.

Share this post


Link to post
Share on other sites
45 minutes ago, nomadd said:

but this removes everything,

 

Hello there nomadd !

 

Check below :

[] spawn { 
	waitUntil { 
	{ 
	if(
	agent _x isKindOf "Snake_random_F"
		) then {
		deleteVehicle agent _x; 
        }; 
	}forEach agents; 
	sleep 5; 	
	//	systemchat "delete Snakes";	   
   }; 
};

 

  • Confused 1

Share this post


Link to post
Share on other sites

basically now that i see this , it's better like :

 

[] spawn { 
	waitUntil {uisleep 1; 
	{ 
	if(
	agent _x isKindOf "Snake_random_F"
		) then {
		deleteVehicle agent _x; 
        }; 
	}forEach agents; 
		systemchat "delete Snakes";	   
   }; 
};

 

  • Thanks 1

Share this post


Link to post
Share on other sites

I confirm environment is local (snakes, rabbits,... if I'm right: clouds, thunderstorms...); The weather forecast distribute some params and let's roll because this could be network demanding to synchronize all that stuff. For the rain start/stop, I don't know.

The enableEnvironment command is fine. If you don't want the rabbits and the snakes, why do you want to keep bees and flies. No interest...

NB: I imagine your convoy stuck by a butterfly...  Who knows? In Arma, let suppose the worst, you will never be deceived. :goodnight:

  • Like 1
  • Haha 1

Share this post


Link to post
Share on other sites

I thought you could only disable "environment" as they are are all grouped together. Yay or nay? 🐍🐇🦋

Share this post


Link to post
Share on other sites

Pierremgi

 

Guess I dont really care about the bees/flies/cicadas but they do add a tiny bit of ambiance. It also removes all the fish which is not a big deal for this particular mission, as there is no water activity. I know this has been reported, animals causing vehicles to swerve or even stop. I guess

I shouldn't be surprised but seems like BIS could have fixed this along time ago. The maps are pretty sterile as they are just hate making it even more so.

Share this post


Link to post
Share on other sites
8 hours ago, GEORGE FLOROS GR said:

basically now that i see this , it's better like :

 


[] spawn { 
	waitUntil {uisleep 1; 
	{ 
	if(
	agent _x isKindOf "Snake_random_F"
		) then {
		deleteVehicle agent _x; 
        }; 
	}forEach agents; 
		systemchat "delete Snakes";	   
   }; 
};

 

@GEORGE FLOROS  Thanks mate I'll use this in my mission.

 

Would I just execute this server side in MP ?

 

Cheers.

  • Thanks 1

Share this post


Link to post
Share on other sites
52 minutes ago, cb65 said:

Would I just execute this server side in MP ?

 

Thanks cb65 !

 

The best place should be in the initserver.sqf !  :thumbs-up:

  • Thanks 1

Share this post


Link to post
Share on other sites
4 hours ago, GEORGE FLOROS GR said:

 

Thanks cb65 !

 

The best place should be in the initserver.sqf !  :thumbs-up:

I always thought all the animals were locally rendered? Many a time I've seen a player shooting at a snake they can see that noone else can see.

  • Like 2

Share this post


Link to post
Share on other sites

https://community.bistudio.com/wiki/enableEnvironment

Quote

enableEnvironment [ambientLife, ambientSound]

enableEnvironment [FALSE, TRUE];

I would do this then create animals again where needed.

https://community.bistudio.com/wiki/createAgent

 

18 minutes ago, Tankbuster said:

I always thought all the animals were locally rendered? Many a time I've seen a player shooting at a snake they can see that noone else can see.

They are.

  • Like 2

Share this post


Link to post
Share on other sites

So running that code on the server would have little or no effect. Run it on player's machines, surely?

  • Like 1

Share this post


Link to post
Share on other sites

Yes, unless server is player (hosted). enableEnvironment can go in init.sqf though.

  • Like 1
  • Thanks 2

Share this post


Link to post
Share on other sites
Just now, HazJ said:

Yes, unless server is player (hosted).

Ah, yes. Good catch.

Share this post


Link to post
Share on other sites

Thanks HazJ that answered one of my main questions. One last question , I can probably figure it out with some tests , but you might know off hand. When I run enableEnvironment command will it continue to work throughout the whole map, meaning animals(snakes,rabbits) are generated around the player out to whatever distance. 

If the player moves to a new location will animals then be generated at the new location. Does enableEnvironment need to be run in a loop?

Share this post


Link to post
Share on other sites
4 minutes ago, nomadd said:

 When I run enableEnvironment command will it continue to work throughout the whole map...

Yes.

5 minutes ago, nomadd said:

Does enableEnvironment need to be run in a loop?

No.

 

EnableEnvironment can also be used inside a trigger zone, meaning you can disable animals and or sound when players are within a defined trigger zone, it can also re-enabled when player leaves a defined trigger zone. 

  • Like 2
  • Thanks 2

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

×