Updating OXPs can be timeintensive and after taking a look in some older OXPs I've decided to write a WYSIWYG tool to speed up that process. It works directly in the game and materials settings can be applied easily. It is meant for OXPers and has no general use for playing Oolite. The handling should be easy (see readme), so just throw a few textures in and have some fun or simply play with the included example.
The tool writes the settings to Latest.log in a way Oolites parser expects them, so simply copy this to your shipdata.plist. Default values are not logged.
Will this make the process of adding shaders easier for us old guys who are seriously falling behind?
Yes and no.
Yes - the materials entries in shipdata are there to pass settings to Oolites own shader, created by Ahruman. The tool hooks in here and gives you the possibility to create the entries without the need to restart Oolite for every small tweak or with heavy usage of the console. You don't even have to be familiar with materials, because it displays your changes directly. So just play a little bit around and you'll get a feeling for the different settings and their effect very soon.
And no, because it doesn't do anything with/for custom shaders.
The whole thing started when I looked in some older OXPs. Pretty often they don't have later implemeted stuff (materials, custom_views), but creating these entries eats a lot time and needs a lot of testruns/finetuning. It was meant for my personal use only to speed up the updating orgy I've had in mind, but in the end it got better than expected, so I released it as helper.
This is going to save me a lot of time in future projects down the road.
Take an idea from one person and twist or modify it in a different way as a return suggestion so another person can see a part of it that can apply to the oxp they are working on.
Oh, and impressive stuff! Wouldn't do a ship OXP without it!
PS: And I actually thought the first major use of ship.setMaterials() was going to be an OXP that switched ships textures between damaged & undamaged while in battle...
Oh well, what do I know...
PS: And I actually thought the first major use of ship.setMaterials() was going to be an OXP that switched ships textures between damaged & undamaged while in battle...
Oh well, what do I know... :P
I also did a trial of that, and it doesn't look so good (as damage just appears at a certain level, and then disappears again as energy levels are restored). A nicer effect can be had with a shader that mixes two textures together gradually, but of course requires a suitable machine set-up.
One option could be that you just check if a suitable damage level is reached, then keep the damaged texture until out of scanner range for more than 10 seconds/docked somewhere - that could give the repair drones time to add spit & polish to the scuffed ship...