Jump to content

Recommended Posts

Hi.

Sorry.

New guy here.

I can't make this work and I can't find an answer. I looked. I really did.

I downloaded version 1.1.2. (Linux) and thing were fine or seemed to be. Then I played with the screen size. I have two screen. The program would open on my second screen for one thing.

I tried adjusting one more time then the screen became very wide and thin. Unusable to readjust any parameter.

Tried re-extracting 1.1.2 and got the same result. Deleted everything and downloaded fresh.

Now the secondary screen flashes and nothing happens (I presume the game loads and crashes). Same thing with 1.0.5.....

 

I don't get it. Does the game save a persistent file somewhere with game parameters?

I need my fix. Build and fly something. Who will help those two Klowns I sent to orbit the sun in the Sunlab?

 

 

Link to comment
Share on other sites

Try this:

rm ~/.config/unity3d/Squad/Kerbal\ Space\ Program/prefs

If you're still having the problem, you can try to fully nuke it.

CAUTION: this should wipe ALL preferences for ANY games you have installed that rely on the Unity game engine:

rm -rf ~/.config/unity3d/

EDIT: I use the second because the only Unity game I have installed is KSP. The issue has manifested for me in the global Unity prefs as well as both Squad (Game) and SQUAD (Launcher) prefs.

Issues affecting the window behavior tend to be related to Unity bugs. If you clear your configuration, you should at least be able to see the KSP window.

Good luck moving it afterwards. That breaks Unity as often as not.

Edited by seevee
Added warning
Link to comment
Share on other sites

10 minutes ago, seevee said:

Try this:


rm -rf ~/.config/unity3d/

@Martian Emigrant You want "rm ~/.config/unity3d/Squad/Kerbal\ Space\ Program/prefs" as that is the offending file. If you have other Unity games installed, the the above will nuke their settings too.

If you remove it, there's a fair chance Unity will just create a new equally borked copy - setting a good resolution in that file then making it read-only may work, though TBH I have given up on windowed mode altogether, it's just plain broken.

Edited by steve_v
Brain-dead editor inserting spurious linefeeds.
Link to comment
Share on other sites

Fair enough, I will amend that. I haven't encountered the re-borking on config wipe, but I have clearly been wiping the entire Unity config.

Ninja edit: I just realized that I had been doing that since I encountered the prefs getting saved to ~/.config/unity3d/SQUAD/ as well as ~/.config/unity3d/Squad/

Edited by seevee
Removed empty line for readability
Link to comment
Share on other sites

1 hour ago, seevee said:

Ninja edit: I just realized that I had been doing that since I encountered the prefs getting saved to ~/.config/unity3d/SQUAD/ as well as ~/.config/unity3d/Squad/

SQUAD is the directory for the launcher, Squad is the directory for the actual game. Why? Beats me. :confused:

Link to comment
Share on other sites

3 hours ago, steve_v said:

SQUAD is the directory for the launcher, Squad is the directory for the actual game. Why? Beats me. :confused:

My guess: Because Windows coders don't need to care and are thus not used to pay attention.

Link to comment
Share on other sites

Thanks a lot.

I completely nuked "Unity". I only have one game installed.

Now 1.1.2 will run. Yeah.

My saves are incompatible. Boo. Looks like I can't save my two Klowns I sent to orbit the sun....Good thing they are only sprites or something like that.

Still load on my secondary monitor. Boo again. Plus round object, like say Kerbal, are oval. I will work on that.

So.....Still confused here....Unity is the engine that run the game. Part interaction. etc.....And it isn't installed with the game....So who installed it on my machine?

 

Edited by Martian Emigrant
Link to comment
Share on other sites

1 hour ago, Martian Emigrant said:

Unity is the engine that run the game. Part interaction. etc.....And it isn't installed with the game

It sure is. Not the Unity editor (used by Squad to create KSP, but not included in the DL), but the Unity3D player - without this there is no game. It's in disguise of course, and goes by the name "KSP.x86_64". To put it another way, Unity is the game. It's the only part that runs natively on your OS, KSP itself is a bunch of assets and managed code that is loaded by, and runs inside Unity.

This is the easy way to make a cross-platform game, because the same managed code can run on any operating system unity can, without modification. Unfortunately it's also the easy way to leave your game at the mercy of bugs in code you didn't write, as we have seen here today.

Edited by steve_v
Link to comment
Share on other sites

8 hours ago, Martian Emigrant said:

So.....Still confused here....Unity is the engine that run the game. Part interaction. etc.....And it isn't installed with the game....So who installed it on my machine?
 

 

Unity engine is installed with game. Dunno why it needs configs  of its own somewhere, but its not really against anything or something. You've just encountered a bug in unity, driver, xorg or, most likely, some weird interaction of all three.

Also, if you happen to run Ubuntu, you have Unity desktop environment, which is completely different thing that just happen to share a name.

7 hours ago, sal_vager said:

You might find the following command line argument useful.

-adapter N

Where N is the screen you want KSP on, it only works for fullscreen however.

More info here. (It's not Windows only)

Windowed game window is managed by window manager. Could not resist that :-) Upshot is that you can set screen (and position and size and frame and icon and about zilion other things), but details depend on what window manager is Martian using. Fullscreen? Bah, thats what loosers with single display use :-P
 

Link to comment
Share on other sites

39 minutes ago, radonek said:

Fullscreen? Bah, thats what loosers with single display use :-P

Sure, I'd love to use windowed-mode... Assuming, that is, that it  creates a window of a reasonable, predictable size.

If "windowed" means a non-resizeable window at some insane geometry like 4000x1 or 10x10, I guess I'll have to run it in full-screen.
Seriously guys, placing windows on the screen correctly has been a thing for some 20 years, it boggles the mind that Unity can fail so spectacularly at this simple task.
On that note, what exactly are we supposed to do with the "Launcher"? It suffers the same issues and has no fullscreen mode... So?
 

Link to comment
Share on other sites

2 hours ago, radonek said:

....Also, if you happen to run Ubuntu, you have Unity desktop environment, which is completely different thing that just happen to share a name....
 

Yes, It did confuse me initially. I confuse easily.

1 hour ago, steve_v said:

Sure, I'd love to use windowed-mode... Assuming, that is, that it  creates a window of a reasonable, predictable size.

If "windowed" means a non-resizeable window at some insane geometry like 4000x1 or 10x10, I guess I'll have to run it in full-screen.
Seriously guys, placing windows on the screen correctly has been a thing for some 20 years, it boggles the mind that Unity can fail so spectacularly at this simple task.
On that note, what exactly are we supposed to do with the "Launcher"? It suffers the same issues and has no fullscreen mode... So?
 

Right now I gave up trying to get the game to run on my main (Read big) Screen.

Every time I try moving the window to the other screen and resize it the game goes weird.

I end up (Immediately or on the next boot) with the window being microscopic (Invisible) in the top-left corner of the screen I don't want or a really strange size.

Such as half an inch wide the whole height of the monitor or 2 inch high the whole width of the monitor.

In one instance I got the window so wide it was halfway in the other monitor. And about 2 inch high.

 

The only solution I have left is to exchange the monitors. But I like them that way.

Might try swapping their connections one is connected through VGA the other through DVI

There is a wall on my right and my current arrangement is great for working, film and playing.

 

Ho well. Thanks guys. I know this is a big endeavour. Bugs are expected.

 

Edited by Martian Emigrant
Link to comment
Share on other sites

2 hours ago, steve_v said:

Sure, I'd love to use windowed-mode... Assuming, that is, that it  creates a window of a reasonable, predictable size.

If "windowed" means a non-resizeable window at some insane geometry like 4000x1 or 10x10, I guess I'll have to run it in full-screen.
Seriously guys, placing windows on the screen correctly has been a thing for some 20 years, it boggles the mind that Unity can fail so spectacularly at this simple task.
On that note, what exactly are we supposed to do with the "Launcher"? It suffers the same issues and has no fullscreen mode... So?



 

Now you are streching it. Desktop apps, sure, but games? Nah, I run dual head for years now and always had issues. Linux have quirks around xinerama, xrandr and drivers at large. Windows do better just by mostly ignoring second screen.  As usual, I tamed ksp on both linux and windows by turning off fullscreen and editing config file to proper width and height. Worked well, except it got reset to desktop resolution whenever I changed anything in game settings menu… until 1.1 came. Now it even shows "custom" screen size and respects it, so I am a happy camper and suggest you guys to do the same. Unity having additional config is news to me, but from what I gather here you can just delete it and have it recreated from game's own config. Once you have game rendering to window of proper size, you can let window manager handle the rest. Dunno about Unity (desktop), but KDE gives me this:

4TfQi.png

Note that nvidia drivers (and maybe others) have all displays in one bigass framebuffer and xinerama info (about screen sizes and positions) is just faked from that, so "screen" selection may not work  (I have older card with legacy driver, maybe newer drivers fare better). If thats the case, you just adjust position in that big virtual display.

Also note that game renders to fixed size buffer, so enforcing size in window manager wont do any good. More fun can be have with "borderless" settings, but one should know how to set placement or move window via shortcuts which again depends on window manager of your choice.
 

Edited by radonek
Link to comment
Share on other sites

1 hour ago, radonek said:

Now you are streching it. Desktop apps, sure, but games?

So you missed the bit where I mentioned that the launcher does  this too? - it's a 2D window with an image, some text and what, 4 buttons? How is this any more complicated than a "Desktop app"?

Drawing a 2D window like this in X11 is not complicated, I can provide example code (C) if required.

Yes, I do realise that he launcher is Unity too. And no, that's not a good excuse.
 

Quote

I run dual head for years now and always had issues. Linux have quirks around xinerama, xrandr and drivers at large.

Nowhere did I suggest that I have more than one monitor, because I do not. It does this with a single display too. Strike xinerama off the list.
I have run dual head in the past... guess what? no problems like this encountered.

Aside, care to enlighten me about these "quirks" in xrandr? My code works just fine and I've never had any problem with xrandr, so I'm not sure what you're talking about.

If this is really so difficult, why have I not encountered, in over ~15 years with X, a single native application that behaves like this?
Honestly, I still can't figure out how to draw a window as broken as what I see from Unity (other than explicitly coding this behaviour) - even when rendering the contents in OpenGL.

I don't have the Unity sources, so I'm not going to look too far into what it's doing. As far as I can tell, there's no real explanation other than "it's doing it wrong". Note that in my book loading a full 3D render pipeline to draw a 2D window like the launcher is also "doing it wrong".

----

Unity does sell source code licences. If they won't fix this rubbish, Squad needs to go buy one and fix it themselves, these endless Unity bugs are crippling KSP.
 

Edited by steve_v
Link to comment
Share on other sites

On 03/05/2016 at 2:59 AM, seevee said:

Try this:


rm ~/.config/unity3d/Squad/Kerbal\ Space\ Program/prefs

 

 

Before doing that, it's worth checking the logs to see if there is an obvious, and easy to fix, problem.

Say having it somehow start thinking that it is running on a 1912X20 monitor, which is easy to fix with your text editor of choice, (insert vi/Emacs holy war here).

Link to comment
Share on other sites

50 minutes ago, Chakat Firepaw said:

Before doing that, it's worth checking the logs to see if there is an obvious, and easy to fix, problem.

Say having it somehow start thinking that it is running on a 1912X20 monitor, which is easy to fix with your text editor of choice, (insert vi/Emacs holy war here).

Can you post the relevant section of the logs? I wasn't able to find anything relating to this issue that wasn't inside the Unity prefs.

Link to comment
Share on other sites

Ok.

 

Update.

Game is now running fine. I have to unlock a bunch of parts but that's another story.

 

After nuking the settings one last time with:

Quote

rm -rf ~/.config/unity3d/

I started the game. It appeared on screen 2.

Using right click on the top border (Or alt-F3).

Selected More Actions-Special Window Settings

Selected Size-Force and my screen 1 resolution 1920,1080

Also selected Minimum size-Force-1920,1080

Then for good measure.

Alt-F3-More Actions-No Border.

 

Now when I start the game it appears windowed too large in screen 2. I follow with Alt-F3-Move To Screen-Screen1.

 

No more crashing, unusable windows and tiny monitor (1024×768)

 

Thank you, thank you, to everyone.

 

 

 

 

Edited by Martian Emigrant
Link to comment
Share on other sites

On 04/05/2016 at 1:19 PM, seevee said:

Can you post the relevant section of the logs? I wasn't able to find anything relating to this issue that wasn't inside the Unity prefs.

Sorry for the delay, I've been too busy digging out a pair of compost heaps and other assorted gardening tasks.

When it comes to the Player.log file in ~/.config/unity3d/Squad/Kerbal Space Program, if it's an out of range graphics setting it will be almost the only thing in there.  Since I've run KSP since having that problem, I don't have the rather short log file with the graphics setting failure any more.

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