Jump to content

[1.12.x] Parallax - PBR Terrain and Surface Objects [2.0.2]


Gameslinx
 Share

Recommended Posts

3 minutes ago, RilonMusk said:

Also, I am aware that my tech issues are cluttering up this forum.

Tech issues are basically what this forum is for.  :)

Besides, having your issue and (hopefully) resolution posted and published for all to see is likely to help someone else down the road.

Link to comment
Share on other sites

@Gameslinx

Using version 2.0.3, still getting the Null ref when in orbit around the sun in JNSQ

194532 NullReferenceException: Object reference not set to an instance of an object
194533   at Grass.BodySwitchManager.Update () [0x00124] in <9c0f8064d71048f18e0c652f62c72a2c>:0 

I looked at the code, and I'm going to guess that the problem is in the BodySwitchManager.cs, at this line:

https://github.com/Gameslinx/Tessellation/blob/f1be27526799a7e877268f0f1aade1626803e1e3/BodySwitchManager.cs#L55

which is:

float opacity = FlightGlobals.currentMainBody.pqsController.surfaceMaterial.GetFloat("_PlanetOpacity");

While you did add a test for currentMain Body != null, that really never happens, since the main body is now the Sun, but it probably doesn't have a pqsController.

I can get you a log file if you want, but nothing else is visible.  Once the vessel went from being in orbit around the Sun to being in orbit around Eve, the errors went away.

You may also want to put a test for the scatter.Value being non-null here:

 foreach (KeyValuePair<PQ, QuadData> data in PQSMod_ParallaxScatter.quadList)
{
	foreach (KeyValuePair<Scatter, ScatterCompute> scatter in data.Value.comps)
	{
		scatter.Value.Start();
	}
}

 

Link to comment
Share on other sites

On 9/16/2022 at 6:24 PM, HebaruSan said:

Believe it or not, I've seen multiple cases in the past where "I installed the mods but they're not there" happened because the user installed the mods to one copy of the game and then ran a different copy of the game. I have no way to check whether that's the cause in your case since we haven't seen a log or a screenshot of your GameData or anything else, but it's one possible explanation that's consistent with all the available evidence we do have.

I believe you.  This sounds like a common mistake.

But I have only one copy of the game and that is in the Steam Lib.

If somebody wants to take a look I would be thankfull

 

My GameData Folder

https://imgur.com/a/KjUjNfC

My KSP.log

Filebin | wxnx7uuzq8uajlgl

(Expires in 6 days)

I think it might just be a setup problem in the configuration... as there are no errors or warnings popping up at startup. There are some settings I can't set up in settings screen like "shader quality", it stays at "high". I set it to "ultra", save settings and next time I start up the game they are back to "high"...

 

 

Link to comment
Share on other sites

1 hour ago, Idinyphe said:

There are some settings I can't set up in settings screen like "shader quality", it stays at "high". I set it to "ultra", save settings and next time I start up the game they are back to "high"...

The settings.cfg file in the main folder can sometimes get sort of corrupted by mods.  There is a version of this file you can get from the troubleshooting section of the first post in this thread.  Try that one.

Link to comment
Share on other sites

8 hours ago, linuxgurugamer said:

I looked at the code, and I'm going to guess that the problem is in the BodySwitchManager.cs, at this line:

Yep, thanks for pointing this out. The null check is actually needed because in some cases when you switch to the tracking station, this code will fire a few times before the monobehaviour is deactivated. It's really annoying, and it's a KSP bug. I didn't account for the fact that the Sun, surprisingly, does not have terrain lol. Cheers

8 hours ago, linuxgurugamer said:

You may also want to put a test for the scatter.Value being non-null here:

This is never null. When it is no longer needed it is immediately cleaned up (QuadData.RangeCheck() -> ScatterCompute.Cleanup()), then removed from the list (QuadData.RangeCheck()). If it is ever null, something has gone very wrong.

Thanks for taking a look at this

5 hours ago, Idinyphe said:

I believe you.  This sounds like a common mistake.

But I have only one copy of the game and that is in the Steam Lib.

If somebody wants to take a look I would be thankfull

 

My GameData Folder

https://imgur.com/a/KjUjNfC

My KSP.log

Filebin | wxnx7uuzq8uajlgl

(Expires in 6 days)

I think it might just be a setup problem in the configuration... as there are no errors or warnings popping up at startup. There are some settings I can't set up in settings screen like "shader quality", it stays at "high". I set it to "ultra", save settings and next time I start up the game they are back to "high"...

 

 

Everything is working correctly here. Dumb question, but have you gone and launched a craft? The scatters do not show until you're in the flight scene

Link to comment
Share on other sites

3 hours ago, Gameslinx said:

Everything is working correctly here. Dumb question, but have you gone and launched a craft? The scatters do not show until you're in the flight scene

Thank you for looking into it!

Yes I have. Both with a spaceship and an aircraft. No effect.

 

I am going with the hint JonnyOThan.

6 hours ago, JonnyOThan said:

The settings.cfg file in the main folder can sometimes get sort of corrupted by mods.  There is a version of this file you can get from the troubleshooting section of the first post in this thread.  Try that one.

Thank you I will try this.

 

Link to comment
Share on other sites

Hi, I'm having some problems trying to create a patch to adapt the stock scatters to the resized stock planets of JNSQ.  Since JNSQ has differnt biome names, 

I'm trying to do this through a Module manager patch, and as far as I can tell, the BiomeBlacklist is loading correctly in game when I check the Module Manager Config Cache. But when I load up the game, I get all scatters everywhere. Ignore that they are poking through the runway, I know I have to create a image blacklist file for that.

cZaDP60.jpg

For instance, dry grass shouldn't show up here, since they should be blacklisted in the Lowlands biome. Here's a sample of my config below:

Spoiler
@Kopernicus:NEEDS[JNSQ]:AFTER[ParallaxStock]
{
	@Body[Kerbin]
	{
		@Properties
		{
			%biomeMap = zJNSQ_Parallax_Scatters/Textures/Kerbin_biome_8K.png
			{
				Biome
				{
					name = ColdShores
					displayName = Cold Shores
					value = 1
					color = #22cc99
				}
			}
		}
	}
}

@ParallaxScatters:HAS[#body[Kerbin]]:NEEDS[JNSQ]:AFTER[ParallaxStock]
{
	@Scatter[KerbinDryGrass]
	{
		@Distribution
		{
			!BiomeBlacklist,* {}
			BiomeBlacklist
			{
				name = Welcome Back Island
				name = Lowlands
				name = Midlands
				name = Highlands
				name = Mountains
				name = Shores
				name = Cold Shores
				name = Ice Caps
				name = Arctic Sea
				name = Sub-Arctic Sea
				name = Krenwich Sea
				name = Foremans Sea
				name = Triangulus Sea
				name = Northern Sea
				name = Eastern Sea
				name = Western Sea
				name = Great Lake
				name = Inland Water
			}
		}
	}
}

 

Does Parallax Ignore Module manager patches? Any help would be appreciated, I've been tearing my hair out wondering why this isn't working.

Edited by Coldrifting
Link to comment
Share on other sites

12 minutes ago, Coldrifting said:

Does Parallax Ignore Module manager patches?

I think this might actually be the case, at least for the global settings.  But also make sure that the cfg appears as you expect it to in the modulemanager.configcache.  You might want %BiomeBlackList instead of adding a new block.

 

yeah, I'm pretty sure this code might be running before modulemanager actually has a chance to update the cfgs: https://github.com/Gameslinx/Tessellation/blob/f1be27526799a7e877268f0f1aade1626803e1e3/Loader.cs#L390

Edited by JonnyOThan
Link to comment
Share on other sites

2 minutes ago, JonnyOThan said:

I think this might actually be the case, at least for the global settings.  But also make sure that the cfg appears as you expect it to in the modulemanager.configcache.  You might want %BiomeBlackList instead of adding a new block.

I've tried both methods, neither seems to work. In either case I do see the correct biomeblocklist in the configcache file.

Link to comment
Share on other sites

42 minutes ago, Coldrifting said:

Does Parallax Ignore Module manager patches? Any help would be appreciated, I've been tearing my hair out wondering why this isn't working.

Looks like it reads it's config only once at startup before MM fires

Link to comment
Share on other sites

Just installed the mod manually, and I get stuck on an infinite loading screen whenever I try to load my saves. I followed all the installation instructions, validated my files through Steam, and tried reinstalling KSP, Kopernicus, and this mod, and I'm still getting stuck on the loading screen. Here's my log: https://drive.google.com/file/d/1hlXc6qO9BaDOGYtlAncX6nxmPiwW_AmU/view?usp=sharing. Any help would be greatly appreciated.

 

Edit: Found the problem. Had to delete the "Configs" folder in the "Parallax_StockTextures" folder due to me using KSRSS.

Edited by JebTheDestroyer
Link to comment
Share on other sites

6 minutes ago, JebTheDestroyer said:

Just installed the mod manually, and I get stuck on an infinite loading screen whenever I try to load my saves. I followed all the installation instructions, validated my files through Steam, and tried reinstalling KSP, Kopernicus, and this mod, and I'm still getting stuck on the loading screen. Here's my log: https://drive.google.com/file/d/1hlXc6qO9BaDOGYtlAncX6nxmPiwW_AmU/view?usp=sharing. Any help would be greatly appreciated.

You're trying to use it with KSRSS, which doesn't really work out of the box.

Link to comment
Share on other sites

23 minutes ago, JebTheDestroyer said:

Forgot to mention that, but the KSRSS Reborn beta actually has configs for Parallax that Gameslinx helped with.

Quote

hey @ballisticfox | GU co-dev are people supposed to install parallax stock textures for ksrss reborn?

ballisticfox | GU co-dev — Today at 2:34 PM

Yes but annoyingly they have to remove a couple configs for it work properly

He didn't elaborate which ones though.

Link to comment
Share on other sites

On 9/18/2022 at 9:58 AM, Gameslinx said:

Method #1 is for Kerbal Konstruct bases to use a MapDecal with 'removeScatter' set to true. Nothing except grass/foliage will generate on it.

This method does not seem to work. When I deploy a n new Map Decal with options remove scatter option  the scatter briefly disappears on save and then immediately reapplies itself. 

On 9/18/2022 at 9:58 AM, Gameslinx said:

Method #2 is to use the blockMap.png, where colouring an area in white will have the same effect as above

I've looked through the wiki but couldn't find a config example of how method #2 might be used. Could you post an example of how it could be applied? 

Link to comment
Share on other sites

On 9/18/2022 at 2:27 PM, RilonMusk said:

@Gameslinx

Here are the improved links!

https://photos.app.goo.gl/brAZpYETeSRYdxFN6

https://photos.app.goo.gl/JMRZmmq2oa3KUB4t7

Also, I am aware that my tech issues are cluttering up this forum. You dont have to if you dont want to, but it would be much easier if we could talk on discord. I am Entropy #2566

OMG!

What would we all do if someone didnt have an issue?  :)

You're fine, we all learn something when one of us has an issue my friend.

Link to comment
Share on other sites

On 9/18/2022 at 2:27 PM, RilonMusk said:

@Gameslinx

Here are the improved links!

https://photos.app.goo.gl/brAZpYETeSRYdxFN6

https://photos.app.goo.gl/JMRZmmq2oa3KUB4t7

Also, I am aware that my tech issues are cluttering up this forum. You dont have to if you dont want to, but it would be much easier if we could talk on discord. I am Entropy #2566

You're missing ModuleManager.

Link to comment
Share on other sites

11 hours ago, Gameslinx said:

Yep, thanks for pointing this out. The null check is actually needed because in some cases when you switch to the tracking station, this code will fire a few times before the monobehaviour is deactivated. It's really annoying, and it's a KSP bug. I didn't account for the fact that the Sun, surprisingly, does not have terrain lol. Cheers

Re. the check for null, yeah, I've run into that in other places as well.

When do you expect to get a release out?   No rush, just want to know what to expect.

Thx

Edited by linuxgurugamer
Link to comment
Share on other sites

6 hours ago, Caerfinon said:

looked through the wiki but couldn't find a config example of how method #2 might be used. Could you post an example of how it could be applied?

There’s no config. You need to create a new blockmap.png with additional custom block outs 

Link to comment
Share on other sites

57 minutes ago, Nightside said:

You need to create a new blockmap.png with additional custom block outs 

So the white areas need to be positioned over where the locations on the planet are and no scatter.  Got it.  Thanks.   

Link to comment
Share on other sites

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.

 Share

×
×
  • Create New...