-
Notifications
You must be signed in to change notification settings - Fork 739
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
View Distance Module #1063
View Distance Module #1063
Conversation
ace_viewdistance_moduleViewDistanceLimit always returning as any. No error in the RPT relating to readSettingfromModule failing
An improvement for performance would be to add https://community.bistudio.com/wiki/setObjectViewDistance, maybe at a preset co-efficient of the viewdistance, so it scales accordingly. Example: OVD = 0.75 * VD |
class GVAR(viewDistanceLimit) { | ||
typeName = "SCALAR"; | ||
value = 11; // setting the highest number in the array below means no limit. | ||
values[] = {0,1,2,3,4,5,6,7,8,9,10,11}; // correspond to the INDEX values |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be strings, until we support other types in the options menu.
Per @Glowbal's comment
Module limit still not being set properly.
Reworked a number of things as per comments and @esteldunedain 's advice on slack. My module value is still not being read and is always taking the default value of whatever there is specified in the config instead of taking the value in the module and overwriting GVAR(limit). |
Module bug fixed thanks to @esteldunedain |
For future limiting of terraingrid
They're only shown when the player changes the setting.
private["_land_vehicle","_air_vehicle"]; | ||
|
||
_land_vehicle = (vehicle player) isKindOf "LandVehicle"; | ||
_air_vehicle = (vehicle player) isKindOf "Air"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
player should be ACE_player
private ["_return"]; | ||
|
||
_return = switch (_index) do | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please adjust to match our style:
_return = switch (_index) do {
Also use 4 spaces for indentation.
Looks good. I'll try to test it ingame soon |
@Winter259, I've tried this and found a problem:
However To work around this, I think using For this I have two ideas 2- Create a setting called "Dynamic object view distance" with the following options: Off, Low, Medium, High, etc. The default would be off, so no I lean toward (2). @Winter259, what do you think? Would you add this things or you prefer I do it before you refork? |
@esteldunedain I will implement option 2, I should (hopefully) not need to refork for this PR. Do these coefficients make sense? |
Yes, but maybe add a couple more? Very low: 0.20 |
Centred prompts, fixed erroneous if statement, adjusted function headers.
Merged, thanks @Winter259 and congratulations |
Big thanks to you @esteldunedain and to everyone else on slack who put up with my questions 👍 |
Could this be expanded with an toggle for enable/disable? Also this does not work reliably for JIP units. Should be expanded with a JIP event. |
I'll open another pull request for the above as I've since reforked my repo as it was broken. |
After two days and several stupid questions on the slack chat I'm happy with the progress I've made in this.
Everything works, except for GVAR(moduleViewDistanceLimit) which is always returning ANY, as discussed in slack chat.