Jump to content

[KSP 1.12.2] Physics Range Extender v1.21.0 (04 Sep 2021)


jrodriguez

Recommended Posts

About

This is a KSP mod based on a initial piece of code written by BahamutoD for BDArmory and improved by myself and test with the help on the entire BDAc team.

Basically it extends game physics range and the terrain loading distance. This will allow you to switch between vessel that are far away or even to see an orbital station from a flying plane. 

REQUESTS  AND IDEAS TO IMPROVE THE MOD ARE ENCOURAGED!

Donations = Motivation

btn_donate_LG.gif

 

Download

https://github.com/jrodrigv/PhysicsRangeExtender/releases

Issues

https://github.com/jrodrigv/PhysicsRangeExtender/issues

Changelog

Spoiler

= v1.21.0
- Recompiled for KSP 1.12.2


= v1.20.0

  • Recompiled for KSP 1.11.0
  • Improved physics ease/landing method when TerrainExtender is Enabled

= v1.18.0
- Recompiled for KSP 1.9.0
- Fixed issue were the camera was broken after switching to a new landed vessel if the active vessel was in IVA.

= v1.17.0
- Recompiled for KSP 1.8.1
- Added extension method for other mods to enable/disable PRE if needed (Thanks to @DoctorDavinci)

= v1.16.0
- Recompiled for KSP 1.8.0

= v1.15.0
- Fixes issue were the initial loading was triggered when a 2nd vessel was loaded.
- Fixes issue in which the active vessel was lifted.

= v1.14.0

- Hotfixes for KSP 1.7.2.

- Flickering improvements for low altitude vessels.

= v1.13.0

- Fixes to terrain extender to avoid landed vessels to crash.

- Recompiled for KSP 1.7.2

v1.12.0

- More improvements for landing of boosters.

= v1.11.0
- Full rework of Terrain Extender to enable reusability of boosters.

= v1.10.0
- Recompiled for KSP 1.7.0
- Fixed critical issue which make landed vessel to crash through the ground when entering into physics range. 

= v1.9.0
- Recompiled for KSP 1.6.0
- Added the Cam fix multiplier option so users can tweak the camera distance if they are not happy with the fix.
 (Bear in mind that the camera fix is the only way to prevent the flickering when the active vessel is very far from the floating origin)

= v1.8.0
- Recompiled for KSP 1.5.1
- Default range reduced to 50 km
- UI simplifed. Removing options that were not used
- Added button to disable de mod.
- Added message to warn the user when the flickering fix is activated.

= v1.7.0
- Recompiled and upgraded for KSP 1.4.3
- Adding option to extend terrain loading distance (thanks to Gedas)
- Flickering fixed at 99% after applying a dynamic update of the near clip plane of the main camera.
- Landed range removed, only one range is needed now :)

= v1.6.0
- Recompiled and upgraded for KSP 1.4

= v1.5.0
- Fixes de-orbit vessels when entering Global Range distance.
- Unload landed or splashed vessels to prevent its destruction when the active vessel is about to change its reference frame (from rotation to inertial).
- If the user decide to increase the range while there are orbiting vessels unloaded. 
  The new range will not be applied to these vessels to prevent de-orbiting. The game should be saved and loaded again for safety.
- A new toggle button has been added to the UI allowing to "Force" the ranges, overriding all the safety checks.
  (This may cause undesired effects like orbiting vessels de-orbit or landed vessels destruction)
- New screen messages have been added to inform the user about events.
- PRE icon visible in all scenes

= v1.4.0
- Recompiled for KSP 1.3
= v1.3.0
- Added GUI to enable/disable the mod and adjust the ranges
- Several code improvements
= v1.2.0
- Added settings.cfg to allow adjust the ranges.
    RangeForLandedVessels: parameter that can be reduced in order to avoid landed vessels to crash into the terrain
    GlobalRange: For all scenarios different than Landed.
= v1.1.0
- Extending to 2000km. Compiled for KSP 1.2.9
= v1.0.0
- Release

(*) You might experience some of the following effects when the range is extended > 100 km: vessel shaking, lights flickering, phantom forces, etc.

Edited by jrodriguez
version 1.21
Link to comment
Share on other sites

5 minutes ago, stk2008 said:

hi there I have BDA installed latest version that came with this mod.

 

Is there an optoins page I can bring up for this mod or is it  set to 200km and thats it or?.

 

Thanks in advance :)

Not yet, at the moment it is hardcoded to 200 km. I would like to make configurable for the next version.

Link to comment
Share on other sites

Was this not possible to achieve by using MM to change the VesselRanges in the Physics.cfg file?

Spoiler

VesselRanges
{
    prelaunch
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    landed
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    splashed
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    flying
    {
        load = 2250
        unload = 22500
        pack = 25000
        unpack = 2000
    }
    orbit
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    subOrbital
    {
        load = 2250
        unload = 15000
        pack = 10000
        unpack = 200
    }
    escaping
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
}
 

 

Link to comment
Share on other sites

6 minutes ago, Warezcrawler said:

Was this not possible to achieve by using MM to change the VesselRanges in the Physics.cfg file?

  Hide contents


 

 

I have already try the MM approach and the result is not the expected for BDArmory scenarios. You can try it yourself and compare.

 

@PHYSICSGLOBALS
{
@VesselRanges
{
@flying
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@escaping
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@landed
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@orbit
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@prelaunch
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@splashed
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@subOrbital
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
}

}

 

Link to comment
Share on other sites

1 minute ago, jrodriguez said:

I have already try the MM approach and the result is not the expected for BDArmory scenarios. You can try it yourself and compare.

 


@PHYSICSGLOBALS
{
@VesselRanges
{
@flying
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@escaping
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@landed
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@orbit
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@prelaunch
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@splashed
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
@subOrbital
{
@pack = 200000
@unload = 190000
@load = 181000
@unpack = 172900
}
}

}

 

Fair enough... Seemed like the "stock" approach, but if it does not work, then plugin is the natural next step :)

Link to comment
Share on other sites

2 hours ago, Warezcrawler said:

Fair enough... Seemed like the "stock" approach, but if it does not work, then plugin is the natural next step :)

Now I'm wondering. I don't play with aircrafts too much, I really love building space stations and stations on other planets. I play with a lot of RO mods like real chutes and real fuels and the like and was wondering whether a) this plugin will allow me to see a station going over the KSC if it's at like 100kM with a lot of lights (also, if it's a larger station if that would cause more lag, even if I'm on the launch pad and b) if either the MM patch (which I had no idea those settings had been added) or the plugin would work better for large-part crafts, stations, etc.

I figure at some point I'd have to disable the plugin or change the MM patch so I can get close enough before the lag kicks in, but think being able to see satellites going by (maybe) overhead (also use distant object enhancements) would be pretty awesome. I just re-read what I typed and don't know how to word it better, I hope you understand what I'm trying to ask

Link to comment
Share on other sites

20 hours ago, shoe7ess said:

Now I'm wondering. I don't play with aircrafts too much, I really love building space stations and stations on other planets. I play with a lot of RO mods like real chutes and real fuels and the like and was wondering whether a) this plugin will allow me to see a station going over the KSC if it's at like 100kM with a lot of lights (also, if it's a larger station if that would cause more lag, even if I'm on the launch pad and b) if either the MM patch (which I had no idea those settings had been added) or the plugin would work better for large-part crafts, stations, etc.

I figure at some point I'd have to disable the plugin or change the MM patch so I can get close enough before the lag kicks in, but think being able to see satellites going by (maybe) overhead (also use distant object enhancements) would be pretty awesome. I just re-read what I typed and don't know how to word it better, I hope you understand what I'm trying to ask

So... I have done some testing today. And the answer is YES. I have created a massive ship (250 meters diameter UFO with lights) and using HyperEdit I have set a 72 km orbit and I have seen the ship orbiting over my flying plane. However, it is quite difficult to see it! I have a 4k monitor and it was like just few pixels! Almost impossible to see it, if it wasn't thanks to the target marker.

Link to comment
Share on other sites

2 hours ago, jrodriguez said:

So... I have done some testing today. And the answer is YES. I have created a massive ship (250 meters diameter UFO with lights) and using HyperEdit I have set a 72 km orbit and I have seen the ship orbiting over my flying plane. However, it is quite difficult to see it! I have a 4k monitor and it was like just few pixels! Almost impossible to see it, if it wasn't thanks to the target marker.

That's friggin awesome! When it flew overhead was there any major lag drop like you would see if you tried to dock with something that large? Either way I'm excited for this weekend when I'll have time to play around with this.

Link to comment
Share on other sites

On 2017-03-29 at 2:44 PM, Warezcrawler said:

Was this not possible to achieve by using MM to change the VesselRanges in the Physics.cfg file?

  Reveal hidden contents

VesselRanges
{
    prelaunch
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    landed
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    splashed
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    flying
    {
        load = 2250
        unload = 22500
        pack = 25000
        unpack = 2000
    }
    orbit
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
    subOrbital
    {
        load = 2250
        unload = 15000
        pack = 10000
        unpack = 200
    }
    escaping
    {
        load = 2250
        unload = 2500
        pack = 350
        unpack = 200
    }
}
 

 

Yes, it is possible to change the load distances with MM, however this does not work as expected with BDAc ... The code that JR came up with mitigates this issue

The Physics Range Extender mod was designed with BDAc in mind, however JR was kind enough to provide this code for the rest of the community who choose not to use or install BDAc ... Methinks this is a good thing as the 'Stock' system could use an improvement in regards to load distances and such

Thanks @jrodriguez

Link to comment
Share on other sites

9 hours ago, Drew Kerman said:

Hahah that shadow. Nice

Haha yes, I didn't expect it! Not sure if @SQUADdev team is aware of what can be done when forcing physics limits. 

In fact I'm going to update the mod going straight to full Kerbin Physics  Range (2000 km should be enough) 

Edited by jrodriguez
Link to comment
Share on other sites

Hello jrodriguez,

I seem to have ran into an issue, not sure if it's physics extender's fault or KK's.

On 3/29/2017 at 6:25 AM, jrodriguez said:

Known issues

Vessels landed on normal terrain can be destroyed when the terrain starting to get unloaded - this happens usually at 20 km distance. A workaround is to place your vessel on a static objects like runways, KSC, Kerbal Konstruct statics, etc.

Time warp will make your non active vessels disappear.

 

As you know there is a problem with terrain unloading if the mod is used with ground craft, however the work around you suggested seems to be broken as well, at about 20~25km my crafts fall through KK structures.

Thank-you in advance!

 

Edited by HorizonFulcrum
Changed order of quote and text.
Link to comment
Share on other sites

3 hours ago, HorizonFulcrum said:

Hello jrodriguez,

I seem to have ran into an issue, not sure if it's physics extender's fault or KK's.

As you know there is a problem with terrain unloading if the mod is used with ground craft, however the work around you suggested seems to be broken as well, at about 20~25km my crafts fall through KK structures.

Thank-you in advance!

 

Neither .. It is KSP's fault

 

Link to comment
Share on other sites

8 hours ago, HorizonFulcrum said:

Hello jrodriguez,

I seem to have ran into an issue, not sure if it's physics extender's fault or KK's.

As you know there is a problem with terrain unloading if the mod is used with ground craft, however the work around you suggested seems to be broken as well, at about 20~25km my crafts fall through KK structures.

Thank-you in advance!

 

Hi! Sorry I forgot to mention one thing.

You need to change a KK's property.

When you add a new static instance you need to change the VisibilityRange property. You can find your local instances here GameData\KerbalKonstructs\NewInstances

Then you just need to update the VisibilityRange.

With 2000 km you should be fine :) 

VisibilityRange = 2000000

***EDIT***

I think you don't need to change this for each instance manually. There is KerbalKonstructs.cfg that contains:

defaultEffectiveRange = 100000
maxEditorVisRange = 100000

I bet that updating this value will allow to set a higher default value every time you add a new instance.

Edited by jrodriguez
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...