Remove space particles

General discussion for players of Oolite.

Moderators: winston, another_commander

TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Remove space particles

Post by TureModder »

Hello everyone.
I recently managed to emulate Oolite on android using Winlator, but unfortunately I have a problem that makes the game unplayable.
Although the rendering works well at 90% unfortunately I have the problem of the particles that are in space.

To make you understand, they are those white circles that simulate the movement of the shuttle when it is not in Hyper Speed ​​or with the fuel ignectors active (in fact they are not visible when these two modes enter).
They flicker and are huge on the screen making the game unplayable.

I was wondering if you could give me a hand or some advice on how to remove them. I don't know if I can edit a file or install an expansion. In my opinion this game is very well played in portable mode and it's a shame to have to give up just because of this problem.

If I can solve it then I will create a little guide and share the control schemes that I am slowly studying to make it a perfect game on an android handheld.
User avatar
Cholmondely
Archivist
Archivist
Posts: 5642
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Remove space particles

Post by Cholmondely »

Some call this "space dandruff".

Keeper was exercised by this - see his KeeperSky oxp


I presume that the relevant bits of his oxp are based on the planetinfo.plist
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 4887
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Remove space particles

Post by phkb »

The file you want to tinker with is called oolite-dust.vertex, which is in the Resources/Shaders folder.
The line you want to play with is line 73 which by default looks like this:

Code: Select all

	float alpha = clamp(OODUST_SCALE_MAX - distance * OODUST_SCALE_FACTOR, 0.0, 1.0);
In KeeperSky, the line becomes this:

Code: Select all

	float alpha = clamp(OODUST_SCALE_MAX - distance * OODUST_SCALE_FACTOR, 0.0, 0.3);
So, I suspect reducing that last value even more would make the dust practically invisible.
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6775
Joined: Wed Feb 28, 2007 7:54 am

Re: Remove space particles

Post by another_commander »

@TureModder please try this:

Download the oolite-particle-dust.png file from https://drive.google.com/file/d/1IF2Z4_ ... sp=sharing

Then replace the file of the same name in oolite.app/Resources/Textures with this file (keep a backup copy of the original first if you want).

Finally, hold down Shift and start Oolite. Let us know if this fixes it for you.

For context, I just realized that the default oolite-particle-dust.png in Resources/Textures is a 24-bit RGB image, while it really should be 8-bit grayscale. The file I am asking you to replace it with has the correct format, so hopefully this should work for you and you get to keep your dust particles too.
TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Re: Remove space particles

Post by TureModder »

another_commander wrote: Tue Mar 25, 2025 12:29 pm
@TureModder please try this:

Download the oolite-particle-dust.png file from https://drive.google.com/file/d/1IF2Z4_ ... sp=sharing

Then replace the file of the same name in oolite.app/Resources/Textures with this file (keep a backup copy of the original first if you want).

Finally, hold down Shift and start Oolite. Let us know if this fixes it for you.

For context, I just realized that the default oolite-particle-dust.png in Resources/Textures is a 24-bit RGB image, while it really should be 8-bit grayscale. The file I am asking you to replace it with has the correct format, so hopefully this should work for you and you get to keep your dust particles too.
I tried this but nothing change. mayabe i have to erase some cache file first?
TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Re: Remove space particles

Post by TureModder »

phkb wrote: Tue Mar 25, 2025 10:59 am
The file you want to tinker with is called oolite-dust.vertex, which is in the Resources/Shaders folder.
The line you want to play with is line 73 which by default looks like this:

Code: Select all

	float alpha = clamp(OODUST_SCALE_MAX - distance * OODUST_SCALE_FACTOR, 0.0, 1.0);
In KeeperSky, the line becomes this:

Code: Select all

	float alpha = clamp(OODUST_SCALE_MAX - distance * OODUST_SCALE_FACTOR, 0.0, 0.3);
So, I suspect reducing that last value even more would make the dust practically invisible.
i try this. i put the second value to 0.0 and nothing changed
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6775
Joined: Wed Feb 28, 2007 7:54 am

Re: Remove space particles

Post by another_commander »

TureModder wrote: Tue Mar 25, 2025 2:50 pm
I tried this but nothing change. mayabe i have to erase some cache file first?
Yes, you should erase the cache file in oolite.app/GNUstep/Library/Caches/org.aegidian.oolite/

This is what starting the game with shift held down should have done.
TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Re: Remove space particles

Post by TureModder »

another_commander wrote: Tue Mar 25, 2025 3:04 pm
TureModder wrote: Tue Mar 25, 2025 2:50 pm
I tried this but nothing change. mayabe i have to erase some cache file first?
Yes, you should erase the cache file in oolite.app/GNUstep/Library/Caches/org.aegidian.oolite/

This is what starting the game with shift held down should have done.
I did that, but unfortunately it didn't work.
TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Re: Remove space particles

Post by TureModder »

I noticed that there are systems (like Zadies) that do not have this dust. Is it not possible to indicate to the game that no system has the dust?
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6775
Joined: Wed Feb 28, 2007 7:54 am

Re: Remove space particles

Post by another_commander »

OK, here is another way to stop the game from rendering dust. You will need the Test Release variant of the game though, this won't work with the standard deployment versions.

Create a folder named Config inside your AddOns folder, then paste the following in and save it as script.js:

Code: Select all

"use strict";

this.startUpComplete = function()
{
	console.debugFlags = 0x00000200;
}
This will completely bypass any attempt at rendering dust. Hope that does it.
TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Re: Remove space particles

Post by TureModder »

another_commander wrote: Tue Mar 25, 2025 3:42 pm
OK, here is another way to stop the game from rendering dust. You will need the Test Release variant of the game though, this won't work with the standard deployment versions.

Create a folder named Config inside your AddOns folder, then paste the following in and save it as script.js:

Code: Select all

"use strict";

this.startUpComplete = function()
{
	console.debugFlags = 0x00000200;
}
This will completely bypass any attempt at rendering dust. Hope that does it.
Ok, where i found the test release?
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6775
Joined: Wed Feb 28, 2007 7:54 am

Re: Remove space particles

Post by another_commander »

For 1.90: https://github.com/OoliteProject/oolite ... elease.exe
When you run this, you will have to specify the location of your 1.90 game install, then let it do the upgrade to test release.

If you prefer the latest 1.91 pre-release, just download the file https://github.com/OoliteProject/oolite ... n-test.exe
Install it and you are good to go.
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6775
Joined: Wed Feb 28, 2007 7:54 am

Re: Remove space particles

Post by another_commander »

BTW, do you have a log file from any of these runs you are trying? There is one more way that could work to stop rendering dust. But I need to see a log file.
TureModder
Competent
Competent
Posts: 32
Joined: Sat Sep 28, 2024 7:04 pm

Re: Remove space particles

Post by TureModder »

another_commander wrote: Tue Mar 25, 2025 3:42 pm
OK, here is another way to stop the game from rendering dust. You will need the Test Release variant of the game though, this won't work with the standard deployment versions.

Create a folder named Config inside your AddOns folder, then paste the following in and save it as script.js:

Code: Select all

"use strict";

this.startUpComplete = function()
{
	console.debugFlags = 0x00000200;
}
This will completely bypass any attempt at rendering dust. Hope that does it.

YES! This actually work! also other small graphical flickerings that were there before are now gone.
Thank you very much.

Just out of curiosity how does this script work? I would have expected to see a flag set to false or something like that
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6775
Joined: Wed Feb 28, 2007 7:54 am

Re: Remove space particles

Post by another_commander »

TureModder wrote: Tue Mar 25, 2025 5:47 pm
Just out of curiosity how does this script work? I would have expected to see a flag set to false or something like that
Great that it worked, enjoy the game on Winlator!

As to how the script works, well this is what happens:

The Test Release version of Oolite utilizes a few debug flags that can be activated via script or debug console to test stuff. The flags are

Code: Select all

DEBUG_LINKED_LISTS			= 0x00000001,
//	UNUSED					= 0x00000002,
	DEBUG_COLLISIONS			= 0x00000004,
	DEBUG_DOCKING			= 0x00000008,
	DEBUG_OCTREE_LOGGING		= 0x00000010,
//	UNUSED					= 0x00000020,
	DEBUG_BOUNDING_BOXES		= 0x00000040,
	DEBUG_OCTREE_DRAW		= 0x00000080,
	DEBUG_DRAW_NORMALS		= 0x00000100,
	DEBUG_NO_DUST			= 0x00000200,
	DEBUG_NO_SHADER_FALLBACK	= 0x00000400,
	DEBUG_SHADER_VALIDATION	= 0x00000800
To use the flags, you adjust the internal console.debugFlags JS object by setting it to the value you want. You can try changing the 0x00000200 code to any of the other ones if you feel like experimenting, but as you can see 0x00000200 is used to turn dust off. You can also combine flags with the "|" (binary OR) operator, like console.debugFlags = 0x00000200 | 0x00000100; if you so wish. In this example you would activate both DEBUG_NO_DUST and DEBUG_DRAW_NORMALS. All we do then with the script is just ensure that the flags are set to what we want as soon as the "startUpComplete" event triggers, which is normally at the end of loading a game file.

And that's basically it. Truth is it could be made much, much more straightforward by just adding a standard switch, like a command line option (i,e. oolite -nodust) or something, but you wouldn't be able to use that unless you downloaded the latest pre-release binary. Actually, we can consider adding that switch, it should simplify things a lot.
Post Reply