Page 103 of 160

Re: Griff's normalmapped ship remakes

Posted: Mon Jul 09, 2012 9:41 pm
by Griff
I've made a few small cosmetic changes to the alloys and wreckage oxp
1. trimmed down the number of wreckage objects from 10 to the 6 best ones
2. fixed a role mistake in the shipdata.plist which meant that only one type of scoopable alloy model was being spawned
3. added a random spin & scale effect in the 'wreckage' vertex shader
4. modified the alloy & wreckage fragment shaders to add in a new animated 'burning' glow map. There's a quicktime .mov of the shader running in rendermonkey here
https://www.box.com/s/0e92bff9fda65f2525f0
The glow texture is scrolled over the surface with an distance offset taken from a swirly greyscale image in one of the alpha channels, makes for a passable rippling flame effect, although (with a different colour pallette) it probably looks more like the bubbles in a pint of guinness swirling around as it's being poured)

Re: Griff's normalmapped ship remakes

Posted: Mon Jul 09, 2012 10:42 pm
by NorthenderPNE
Wow Griff, you never cease to amaze me. Awesome!!!!! :wink:

Re: Griff's normalmapped ship remakes

Posted: Wed Jul 11, 2012 2:15 am
by JazHaz
Griff wrote:
I've made a few small cosmetic changes to the alloys and wreckage oxp
There's a little typo in the Readme - the second date seems to be out of order...:
Griff 09 July 2012
09 July 2012 - changed wreckage object. Added random spin and scale to wreckage in vertex shader
21 July - Fixed broken distance check in script, added new random velocity script setting to the spark cloud.
25 June - Added Thargoid's fix for 'player ship not exisiting' log error in the distance check part of the "griff_spawn_wreckage.js" script and the missing AI's folder
19 June - Added definitions for default Alloys & wreckage models into this oxp's shipdata-overrides.plist to stop them spawning in-game and fixed missing wreckage textures
18 June: Added a distance check to the spawn scripts - junk & debris only gets spawned if the explosion happens near the player - Massive thanks to Svengali & Thargoid on the Oolite forum for the idea and the extra script work!

Re: Griff's normalmapped ship remakes

Posted: Wed Jul 11, 2012 9:16 am
by NorthenderPNE
JazHaz wrote:
There's a little typo in the Readme - the second date seems to be out of order...:
Griff 09 July 2012
09 July 2012 - changed wreckage object. Added random spin and scale to wreckage in vertex shader
Griff 21 July 2011 <== Deleted line.
21 July - Fixed broken distance check in script, added new random velocity script setting to the spark cloud.
25 June - Added Thargoid's fix for 'player ship not exisiting' log error in the distance check part of the "griff_spawn_wreckage.js" script and the missing AI's folder
19 June - Added definitions for default Alloys & wreckage models into this oxp's shipdata-overrides.plist to stop them spawning in-game and fixed missing wreckage textures
18 June: Added a distance check to the spawn scripts - junk & debris only gets spawned if the explosion happens near the player - Massive thanks to Svengali & Thargoid on the Oolite forum for the idea and the extra script work!
It's from 2011 JazHaz, Griff just removed the line stating that. Just checked the old Readme. :wink:

Re: Griff's normalmapped ship remakes

Posted: Sun Jul 22, 2012 8:45 pm
by Griff
I've made a few changes to the standalone Anaconda oxp - added a spec intensity map, some more lines and greeblies on the hull and made some changes to the shaders so they use the light calculating functions from Oolite's default shaders
Image
Hopefully it's all working, had some weird problems with the decals fading away when the ship went into shadow! bit weird :lol: took hours to fix, turned out i'd got my texture names mixed up and the decal mix was combining the wrong maps

Re: Griff's normalmapped ship remakes

Posted: Sun Jul 22, 2012 9:43 pm
by Gimi
Brilliant work as always Griff. Give us a word when it's incorporated into the all in one, would you please.

Thanks.

Re: Griff's normalmapped ship remakes

Posted: Sun Jul 22, 2012 9:58 pm
by Cody
Yeah... nice work, Griff. I'll install that, suppress the shipset version (hopefully), and go looking for one.
<re-calibrates his joystick for the umpteenth time>

Re: Griff's normalmapped ship remakes

Posted: Sun Jul 22, 2012 10:49 pm
by Cody
Hmm... either I've done something wrong (possible, but I don't think so), or the new Anaconda (npc) is flashing on and off like a Belisha beacon.

No errors in the log - can anyone confirm this?

Re: Griff's normalmapped ship remakes

Posted: Mon Jul 23, 2012 7:20 am
by DGill
El Viejo wrote:
Hmm... either I've done something wrong (possible, but I don't think so), or the new Anaconda (npc) is flashing on and off like a Belisha beacon.

No errors in the log - can anyone confirm this?
Works OK for me - very nice Griff

Re: Griff's normalmapped ship remakes

Posted: Mon Jul 23, 2012 7:30 am
by Griff
El Viejo wrote:
Hmm... either I've done something wrong (possible, but I don't think so), or the new Anaconda (npc) is flashing on and off like a Belisha beacon.
No errors in the log - can anyone confirm this?
I saw this during testing - there's still some shipdata.plist references to the old version of the anaconda in your game somewhere - the little orange blinking lights texture got shifted into a new texture map, if you have an anaconda looking for this texture in the wrong place it won't find it and the whole hull blinks on/off instead of in just a few small spots
the NPC anacondas need these shader definitions:-
Edit: oops, just noticed a bug, line 211 in shipdata.plist 'PaintColor' should be uPaintColor I'll fix it in the oxp and in the code snippet below

Code: Select all

	shaders = 
		{ 
            "griff_anaconda_diffuse.png" = 
			{ 
                vertex_shader = "griff_normalmap_ships.vertex"; 
                fragment_shader = "griff_anaconda_b_channel_decals.fragment"; 
                textures = 
						(
							"griff_anaconda_diffuse.png", 
							"griff_anaconda_normal.png",
							"griff_anaconda_hull_effects.png",
							{name = "griff_decals_set1.png"; repeat_s = "yes";}
						);
				uniforms =
						{
						uDiffuseMap = { type = texture; value = 0; };
						uNormalMap = { type = texture; value = 1; };
						uEffectsMap = { type = texture; value = 2; };
						uDecalMap = { type = texture; value = 3; };	
						uTime = "timeElapsedSinceSpawn";
						uNearlyDead = "throwingSparks";	
						uIsHostile = "hasHostileTarget";						
						uHullHeatLevel = "hullHeatLevel";
						uPaintColor = {type = "randomUnitVector"; scale = 0.25;};
						uDecalColor =  {type = "randomUnitVector"; scale = 0.5;};
						uDecalSelect = "entityPersonality";	
						}; 	
			}; 
		};
some of the uniform names have changed and the third texture in the list ("griff_anaconda_hull_effects.png") is a new one - was called something like "griff_anaconda_eng_gun_effects" or something like that.
I've updated the oxp and started numbering it, i have a feeling it may whizz up the version numbers like my other oxps do :lol:

Re: Griff's normalmapped ship remakes

Posted: Fri Jul 27, 2012 10:53 am
by Tichy
I noticed that my log is full of these errors and warnings, generated by the alloys and wreckage oxp. However, in game, everything looks fine.

Code: Select all

00:38:20.363 [shader.load.fullModeFailed]: ----- WARNING: Could not build shader griff_spark.vertex/griff_wreckage.fragment in full complexity mode, trying simple mode.
00:38:20.372 [shader.load.fallbackSuccess]: Simple mode fallback successful.
  00:38:20.381 [shader.link.failure]: ***** ERROR: GLSL shader program linking failed for griff_spark.vertex/griff_wreckage.fragment:
>>>>> GLSL log:
error: fragment shader varying scrollvTexCoord not written by vertex shader

Re: Griff's normalmapped ship remakes

Posted: Fri Jul 27, 2012 11:27 am
by Griff
ah, sorry about that - this looks like either a bug in one of the shaders or i've forgotten to update which shader is used where in the shipdata.plist and there's an object using the wrong combination of vertex and fragment shader - i'll have a look at it this evening and post up a fix :D

Re: Griff's normalmapped ship remakes

Posted: Fri Jul 27, 2012 12:04 pm
by Tichy
Thank you! :D
I was worried that it might be a fault of my video card or driver.

Re: Griff's normalmapped ship remakes

Posted: Fri Jul 27, 2012 6:30 pm
by Griff
I think this is fixed now in the version of the oxp i've just uploaded to box, i'd changed one of the fragment shaders in the last update to add a scrolling heat effect to it and forgotten that this shader was shared by a few other objects in the oxp, which as you noticed in the logs, got a bit confused by all these new references to scrolling texture co-ordinates and new fangled whatnot that they weren't expecting

Re: Griff's normalmapped ship remakes

Posted: Fri Jul 27, 2012 7:54 pm
by Tichy
Yes! Thanks :)