Jump to content

(NOT WORKING) KSP-performance-fix


Recommended Posts

NOT WORKING

KSP-performance-fix

I don't know how but for me it cut the loading time in half and improves the performance. My intention was to set a fps limit to the loading screen but it did a little mor than that.

Sorry for my bad english.

I would be very happy for feedback.

License:  GNU GPLv2

Github is set to Private

download+source(Github) https://github.com/Leo0806-studios/KSP-performance-fix

Issues(Github) https://github.com/Leo0806-studios/KSP-performance-fix/issues

NO LOG = NO SUPPORT

 

Edited by Leo0806-studios
NOT WORKING
Link to comment
Share on other sites

Hello @Leo0806-studios, and welcome to the forums!  Thank you for contributing to the modding community.  :)

It's great to see you posting your mod here, but there are a few points to fix, per the add-on posting rules:

  1. Could you please edit your forum post, above, to say what the license is?  (From looking at your github repository, it looks as though you're using Gnu GPL v2.  So if you could just add a note to your post, above, saying "License:  GNU GPLv2", then that would satisfy this requirement.)
  2. You also need to include the license file in your downloadable zip.  When I download your zip file from SpaceDock, all it has is a DLL in it.  It should include the LICENSE file from your repo, so that when a user installs it on their KSP machine, they'll have the license file there.
  3. Where is your source code?  Maybe I'm missing something, but when I go to your github repository that you link, above, I don't see any actual code.  All I see is a README and a license file.  Where's the actual code?  Your code link (i.e. your github repo) should include all the source files that you use to build your DLL-- i.e. the .sln file, .csproj file, all the .cs files, etc.  It needs to be so that any user can clone your repo and build the DLL themselves.

Thanks again for posting the mod!   (And please don't worry about your English-- you're doing just fine, and lots of people here have English as a second language, nobody worries about that.)  :)

Cheers,
Snark

[EDIT]  I see you've already fixedthe issues.  :)

Link to comment
Share on other sites

3 minutes ago, Leo0806-studios said:

now it shoud be included

Thank you, looks great!  You're all set.  :)

Just for your information:  I see that you've included bin/Debug in your github repo.  There's nothing wrong with that, but you don't actually need to include the "bin" directory in your repo.  That's because it doesn't contain source; it contains the build result, and so users don't actually need to download that (since when they download the source code and press the "build" button in Visual Studio, the "bin" folder will be generated for them).

I'm not sure how familiar you are with github, but if you'd like to exclude the "bin" directory from your repo so that the git client won't always be pestering you to upate it, you can include a .gitignore file with your repo.  Totally optional, it's up to you.  :)

(Here's an example of a .gitignore from one of my own mods, as an example of something that works.  My own .gitignore has "src/" on each line, because that's where I put my source files, so if you add your own .gitignore to your repo, you may need to adjust that.)

Link to comment
Share on other sites

Interesting discovery. In case anyone else is curious, this mod sets Application.targetFrameRate to 60. Here's the Unity documentation for that property:

https://docs.unity3d.com/ScriptReference/Application-targetFrameRate.html

Quote

The default targetFrameRate is a special value of -1, which indicates that the game should render at the platform's default frame rate. This default rate depends on the platform:

- On standalone platforms the default frame rate is the maximum achievable frame rate.

So this mod does something on systems that typically run at greater than 60 FPS; if your system's maximum achievable frame rate is less than 60, then this mod would do nothing. Maybe limiting the framerate gives the game more time to handle non-graphical calculations?

Link to comment
Share on other sites

no. my system isn't even close to 60 fps but it got stabelised at about 15-30 fps. i think it has something to do with vsync

and it also speeds up the loading but i don't knwo how it does that

one point on my todo list is a config to modify the target framerat but i don't no how to do that(yet).

Edited by Leo0806-studios
Link to comment
Share on other sites

4 hours ago, Leo0806-studios said:

yes but it is manly for the loading screen because there is no fps cap(if I remember corectly)

Ahh, I see, thanks.

Does the loading screen need frames at all? What about setting it to 15 FPS? Then the game setting can take over once the main menu loads.

Link to comment
Share on other sites

The part compiler is tied to frame rate. It runs in a coroutine with one action per frame so completely unlocking the frame rate drastically speeds up load times, i.e. 1000+ actions per second rather than 60.

Edited by Poodmund
Link to comment
Share on other sites

21 minutes ago, Poodmund said:

The part compiler is tied to frame rate. It runs in a coroutine with one action per frame so completely unlocking the frame rate drastically speeds up load times, i.e. 1000+ actions per second rather than 60.

But the property's default value is -1, which is unlocked. What you're suggesting should already happen with no intervention.

Link to comment
Share on other sites

30 minutes ago, Poodmund said:

The part compiler is tied to frame rate. It runs in a coroutine with one action per frame so completely unlocking the frame rate drastically speeds up load times, i.e. 1000+ actions per second rather than 60.

Why, Squad? Why?

Link to comment
Share on other sites

28 minutes ago, HebaruSan said:

But the property's default value is -1, which is unlocked. What you're suggesting should already happen with no intervention.

Isn't my framerate doing that already? I often see frame rates of > 1000 from my video card's hardware display until I get to the main menu.

Link to comment
Share on other sites

2 minutes ago, OrbitalManeuvers said:

Isn't my framerate doing that already? I often see frame rates of > 1000 from my video card's hardware display until I get to the main menu.

Yes, that's what I was trying to say. This mod's change only reduces frame rates.

Edited by HebaruSan
Link to comment
Share on other sites

2 minutes ago, HebaruSan said:

Yes, that's what I was trying to say.

You did indeed - which reminded me that I see that regularly.

So, I have a long enough startup time on one of my installs (85 mods, ~13k patches) that I'm going to take one for the team and do some with/without timing comparisons.  Since MM rebuilds everything when you change something, I guess I'll check timings for both the 1st run after installed/uninstalling this mod, and also the 2nd run to get the MM + cache times too.

 

 

Link to comment
Share on other sites

1 hour ago, Poodmund said:

The part compiler is tied to frame rate. It runs in a coroutine with one action per frame so completely unlocking the frame rate drastically speeds up load times, i.e. 1000+ actions per second rather than 60.

but rendering whit uncapet framerat can put a lot of stress on your system especially on low end pcs.

Link to comment
Share on other sites

Disclaimer:  it's Windows. Timing things on Windows is questionable from the word go. That said, I did as much as I could to mitigate other factors.

Without mod, MM cache missing 8:20
Without mod, MM cache present 6:15
With mod, MM cache missing 8:06
With mod, MM cache present 6:26

MM cache present/missing just means that I added the mod which caused MM to rebuild the cache, so I recorded that time, exited, and restarted without any other changes and recorded that time too.

tl;dr: it's no-op on my system

Link to comment
Share on other sites

Mod does nothing to my 90+ mod install.

Still need (tested 5 times + reboot) 1.40 to 2.30 minutes to load to space center, meassured by "QickLoad".
So -> delete by useless.

I was wondering that after a "decade" and hordes of people and threads THE magic performance mod pop up.
Just an Illusion.

Link to comment
Share on other sites

2 minutes ago, Jansn67 said:

I was wondering that after a "decade" and hordes of people and threads THE magic performance mod pop up.
Just an Illusion.

In the long ago times there was a mod that loaded textures as required instead of loading all textures into memory at once --  this was primarily done to keep under the 32-bit memory limit (as was the custom at the time) but a revival might be helpful when people are routinely managing 9-10 GB of part mods plus another 4-5 GB of textures from planet packs.

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...