River Of Flame

River Of Flame

All map release threads should be posted here

Moderator: Moderators

Post Reply
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

River Of Flame

Post by raaar »

River Of Flame!

(version v4)

In-game screenshot
Image


minimap
Image



A 14x12 map good for 1v1 to 4v4.

SPRINGFILES LINK

--- special rules

- units and features that fall to the lava are forced to float and burn for about 300 HP/s
(they can be rescued by air transports on various games)
- projectiles that fall to the lava are destroyed


--- credits

- uses ambient sound player made by Klon and The Yak (Audionautics, e__ - Lava SFX from freesound.org)
- uses map edge extension mask widget made by Pako
- rock meshes/skins based on the ones by LathanStanley from map "tangerine"
Attachments
screenshot
screenshot
minimap
minimap
Last edited by raaar on 02 Aug 2022, 19:47, edited 6 times in total.
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

2019/04/07 ------------------ NOTES v1.1 ----------------------

- fixed errors that show up when playing the burn sounds when units fall to lava
- made lava burn sounds quieter and fade with distance
- made the ambient lava sound quieter
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

2019/08/13 ------------------ NOTES v1.2 ----------------------

- added tall hills covering the geothermal spots on NW and SW
- improved textures, namely added dirt/ash layer over the bridges
- override the LOS brightness levels to make fog-of-war less dark
- don't run redundant map edge extension widget on Metal Factions or ZK
- modified the lava flow and reduced how much it extends beyond the playable map area (it wasn't visible anyway)
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10450
Joined: 24 Jan 2006, 21:12

Re: River Of Flame

Post by PicassoCT »

In layva_layer.lua replace this lines

Code: Select all

function gadget:DrawWorldPreUnit ()  
	-- lava planes

	drawPlane(":a:LuaRules\\Images\\lavacolor6.png",15,7,30,0.001,{1.0,1.0,1.0,1.0},"alpha") 
	drawPlane(":a:LuaRules\\Images\\lavacolor6.png",20,10.8,28,0.0021,{1.0,1.0,1.0,0.6},"alpha") 
	
	-- fog planes
	drawPlane(":a:LuaRules\\Images\\lavafog.png",23,1.9,13.9,0.0043,{1.0,1.0,1.0,0.30},"alpha_add" ) 
	drawPlane(":a:LuaRules\\Images\\lavafog.png",26,1.3,9.2,0.003,{1.0,1.0,0.1,0.25}, "add") 
end


function drawPlane (texture,y,scaleFactor,periodS,growFactor,rgba, mode)
	local t = spGetGameSeconds()
	
	gl.PushAttrib(GL.ALL_ATTRIB_BITS)
	gl.Blending( mode )--alpha_add
	gl.DepthTest(true)
	gl.DepthMask(true)	
	
	periodFactor = sin(2*pi*t/periodS)
	glowPeriodFactor = sin(2*pi*t/(periodS*1.3))
	scaleFactor = scaleFactor * (1+ periodFactor * growFactor)
	gl.Texture(0,texture)-- Texture file	
	gl.Texture(1,texture)-- Texture file	
	gl.Color(rgba[1]*(0.9+0.1*glowPeriodFactor),rgba[2]*(0.8+0.2*glowPeriodFactor),rgba[3]*(0.7+0.3*glowPeriodFactor),rgba[4]*(0.9+0.1*glowPeriodFactor))
	
	gl.BeginEnd(GL.QUADS,drawPlaneVertexes,y,scaleFactor,periodFactor)
	gl.Texture(false)
	gl.DepthMask(false)
	gl.DepthTest(false)	
	gl.PopAttrib()
	gl.Blending(false)
end
to get this:

Image

PS: You need a more lit lava texture for full effect
Attachments
screen00024.jpg
(361.04 KiB) Not downloaded yet
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

Thanks for the feedback. The lava is a bit dark indeed, although your example makes it too bright.

I could just increase the brightness of the textures involved, though.

I have an issue with textured translucent planes : they obscure the units and at least some CEG below instead of letting them show through (but not other planes or the ground itself), do you know of a way around that?

That would let me draw a set of faint texture planes to "fake" glow, fog etc. above the heights where units and projectiles interact.
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

2019/08/18 ------------------ NOTES v2 ----------------------

- made the lava much brighter and more intense
- modified the lava sound to be less cracky and bubbly and more rocky and fade out with distance



(Thanks to Picasso for the suggestion)
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10450
Joined: 24 Jan 2006, 21:12

Re: River Of Flame

Post by PicassoCT »

Im not done yet.. i have a diffrent problem entirely.

I applied the melty shadder to the map crucible using the map shadding framework.

http://goo.gl/WzQdeE

and this

Code: Select all

   fNormal = normalize(normalMatrix * normal);
produces totally diffrent result from this:

Code: Select all

fNormal = normalize(gl_NormalMatrix * gl_Normal.xyz);
in Spring. Any reason for your glsl-standard treason spring?
ivand
Posts: 310
Joined: 27 Jun 2007, 17:05

Re: River Of Flame

Post by ivand »

You can post your widget/gadget and shader code, so it's easier to understand what you are trying to do
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10450
Joined: 24 Jan 2006, 21:12

Re: River Of Flame

Post by PicassoCT »

So the idea is basically to port the code in the shader snippet to spring for a map.
vertexsource:

Code: Select all


        uniform ivec2 texSquare;
        varying vec2 texCoors;

        varying vec4 colorChange;
		varying vec3 fNormal;
		
        uniform float time;
        uniform float points[30];
        uniform int pointSize;
		
		float totalTime= 1.0;
		float PI_HALF= 3.14159/2.0;
		float PI =3.14159;
		float changeRate = 0.0;


        void main(void) {		
				fNormal = normalize(gl_NormalMatrix  * gl_Normal.xyz);
						
				float sigNum = 1.0;
				float relTime = abs(mod(time/totalTime,totalTime));
			//	melting process - a inverse cosinus rising 
				float meltSpeed=abs(cos(relTime/(PI*2.0)));
				float molten = abs(1.0-cos((time/totalTime)*PI_HALF));
				
			//	percentage we scale the vector out or inwards
				float percentage= (sqrt(abs(gl_Normal.y)/(abs(gl_Normal.x)+abs(gl_Normal.z) +0.01)))/50.0; // /50
				
				
				sigNum=(fNormal.y <= 0.0)  ? -1.41  : 1.0;
			  
			 // computate the total melting and end it at max where the molten metall gets hadr
			 // keep Constant Change
			  //changeRate= relTime < 0.5*totalTime? mix(0.0,percentage*sigNum*molten,relTime/0.5*(totalTime)):percentage*sigNum*molten;
			  
				
				//move the position along the gl_Normal and transform it
				vec3 newPosition = gl_Vertex.xyz + fNormal * changeRate;
				gl_Position = gl_ModelViewProjectionMatrix * vec4( newPosition, 1.0  );
        }
		


fragmentsource:

Code: Select all

uniform float time;
varying vec3 fNormal;


vec3 hit= vec3(1.0,0.8,0.3 );
vec3 glowing= vec3(0.9,0.3,0.1);
vec3 cooldown= vec3(0.4,0.1,0.05);
vec3 wreck=vec3(0.185,0.155,0.155);


vec3 currColor;
float averageShadow;

float PI=3.14159;
float totalTime=6.0;
float percenTage=0.0;
vec3 emptyVec = vec3(0.0,0.0,0.0);

vec3 clampAfter(vec3 x, float Time, float TimeLimit)
{
    return (Time < TimeLimit ? x :emptyVec);
}

vec3 openEnded(vec3 x, float Time, float TimeLimit, vec3 deFault)
{
  return Time < TimeLimit ? x :deFault;
}


            void main(void) {
				 
					percenTage= (mod((time),totalTime))/totalTime*PI;


					averageShadow=(fNormal.x * fNormal.x + fNormal.y * fNormal.y + fNormal.z + fNormal.z)/3.25;

					currColor=(

					 (percenTage < 0.5 * PI ?  hit * cos(percenTage) * 2.0 :emptyVec)
					+ (percenTage < PI ? glowing * sin(percenTage) * 2.5 :emptyVec)
					+ (percenTage < PI * 2.0 ? cooldown*sin(PI + percenTage)*2.0 :emptyVec)
					+openEnded(wreck * abs(sin(PI+percenTage)),PI + percenTage,PI*2.0,abs(wreck*0.3))
					);

					  gl_FragColor = vec4(currColor*(1.0 - averageShadow), 1);

            }
            
What i want is for the whole map, to turn orange hot and then slowly cool back down- and repeat that in pulses..

Please click the link to see the shader snippet to get a idea where im headed..
http://goo.gl/WzQdeE
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10450
Joined: 24 Jan 2006, 21:12

Re: River Of Flame

Post by PicassoCT »

Image
Attachments
screen00026.jpg
(269.51 KiB) Not downloaded yet
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

looks nice!

- what's the impact on fps (how many you get with and without that effect enabled)
- what's the aspect of it over the normal map textures (not dark)
- is it hard to make it so the gadget can update the effect parameters (intensity, colors, altitude, etc.) dinamically
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

2021/11/06 ------------------ NOTES v3 ----------------------

- slightly reduced the altitude of the plateaus
- made cliffs a bit more jagged and natural and added detail textures
- improved metal spot textures
- metal spot yield was slightly increased for regular spots and reduced for golden spots
- replaced one of the regular spots on NW and SE starting positions with a golden spot
raaar
Metal Factions Developer
Posts: 1094
Joined: 20 Feb 2010, 12:17

Re: River Of Flame

Post by raaar »

2022/07/30 ------------------ NOTES v4.1 ----------------------

- fixed lua errors when a unit fell on lava for players that started with the ambient player widget disabled


2022/07/22 ------------------ NOTES v4 ----------------------

- lua resource spot marking stamps textures in the ground instead of relying on feature decals
(because people often have the ground decals disabled)

- removed unsupported map options
Post Reply

Return to “Map Releases”