BourneMcReady Posted June 10, 2018 Share Posted June 10, 2018 I would like to make a mod where the distance you can activate VATS is dynamic. I think it would be really cool to restrict low perception characters from pressing vats and finding targets that are too far away. It would also allow me to solve the major balance problem that is spamming the VATS button to detect enemies and mines from very far away. Would also like to make it so if a weapon is equipped with a scope the distance is much longer, but that would be added later. The game setting I need to change is fVATSMaxEngageDistance I would just handle this through a perk, but I cannot find a way to modify that game setting.First thing I want to do is do if perception 1, then engage distance is x. If perception is 2 then engage distance is x. If weather is raining or foggy then engage distance is x. And so on. Is there a setting for this that I am not seeing? If not, how would I go about making this? Link to comment Share on other sites More sharing options...
BourneMcReady Posted June 10, 2018 Author Share Posted June 10, 2018 If this setting doesn't exist, then I need to make a new perk entry point I believe. Is that even possible? I feel like it's not. Link to comment Share on other sites More sharing options...
Hoamaii Posted June 10, 2018 Share Posted June 10, 2018 Check F4SE's function "setGameSettingsFloat", it should allow you to do just that - fVATSMaxEngageDistance is very likely a float. Haven't done that in F04 yet, but if it works in any way the same it does in Skyrim, the only problem is that the new values you set in-game are not stored in your saves, you need to call that function again every time you load your game, but that's fairly easy to do. And, in your case wanting to change that value dynamically, that'd mean also checking what that value is before saving - I guess storing it as a Global every time it changes would do the trick. Link to comment Share on other sites More sharing options...
BourneMcReady Posted June 10, 2018 Author Share Posted June 10, 2018 (edited) Thank you for the answer. I have not learned enough about scripting yet, but I guess now is a good time. Is there any way to alter a game setting without using F4SE? Edited June 10, 2018 by bretton Link to comment Share on other sites More sharing options...
SKKmods Posted June 10, 2018 Share Posted June 10, 2018 Yes by changing the game setting in FO4EDIT or the Creation Kit menu [Gameplay:Settings] which hardcodes the new value into your mod .ESP but that's totally static and not dynamic. Link to comment Share on other sites More sharing options...
Recommended Posts