Jump to content
Sign in to follow this  

need view distance sript /dialog for client

Recommended Posts

Does anyone have a good view distance script / dialog that is client based? I see it in evolution, but that has so much going on, I can not tell what is part of the view distance script /dialog and what is not.

I just want to be able to stick this in a training mission, and be simple. People who are playing could go to an object while in game and select there view distance.

I checked the forums, but did not see anything on a seperate script / dialog for view distance on a client.

Share this post

Link to post
Share on other sites


Thanks for the answering my post. I looked at your mission, and I see a script for view distance, but I am not able to get it to work.

I just need something more like a basic template.

I do appreciate you trying to help.

Share this post

Link to post
Share on other sites

important: make certain that ALL playable guys are set as 'playable', not as 'player' for the menu parts to work properly.

first put this line in init.sqs or in an init trigger:


the modViewDist.sqs in there is a simple callable script that takes 1 parameter.

If you want to increase the viewdistance by say 1000 metres then call it thus:

[1000] exec "modViewDist.sqs";

if you want to reduce it by 300, call it thus:

[-300] exec "modViewDist.sqs";

It was designed to be used this way as it is tied to a menu option on the player's command menu,

added by the other script, addVDopts.sqs


;usage [_mv] exec "ArMo\modViewDist.sqs"

_mv=(_this select 3)select 0;

?(_mv<0):goto "MVDDEC";


setViewDistance iViewDist;hint format["ViewDistance set to %1",iViewDist];




setViewDistance iViewDist;hint format["ViewDistance set to %1",iViewDist];


and this next is called from a true trigger with 2 second countdown.



if(local player)then{_Pact00=player addAction ["ViewDist+","ArMo\modViewDist.sqs",[500],-1,false,true,""];_Pact01=player addAction ["ViewDist-","ArMo\modViewDist.sqs",[-500],-1,false,true,""];};

hint "use the [ ] action menu\nto change View Distance\nto suit your machine specs.";


note: the 10-second delay is needed as sometimes ArmA will not run stuff from true/init triggers properly under long-load time/desync conditions.

To use an object instead of the player menu, simply substitute that object name for the word player in the second script and remove the 'local' test condition.  There is no other way to attach those actions to an object.

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