Author Topic: Swamp Water Material  (Read 10558 times)

Offline ToastGhost

  • Experienced Traveler
  • **
  • Posts: 221
  • Floof-O-Meter: 23
    • View Profile
Swamp Water Material
« on: August 22, 2011, 07:40:44 pm »
So I made this for one of my maps, and decided I might as well distribute it publicly.  So here you guys are.  A swampy water material.  It's not the best, but hey.



Download: http://www.mediafire.com/?p551hq7z7b2bpzm


Directions
  • 1.) After following the directions in the ReadMe, open the map-maker and go to the objects tab.
  • 2.) At the bottom there is a water segment.
  • 3.) In the blank box, type "SwampWater."
  • 4.) Click "New Water" and re-size to your liking.

Offline KissAndStab

  • Finest Floof
  • ***
  • Posts: 625
  • Floof-O-Meter: 34
  • Y'all know you want him ^.
    • View Profile
Re: Swamp Water Material
« Reply #1 on: August 22, 2011, 08:32:03 pm »
Amazing, I'm so downloading. ; D

Offline ToastGhost

  • Experienced Traveler
  • **
  • Posts: 221
  • Floof-O-Meter: 23
    • View Profile
Re: Swamp Water Material
« Reply #2 on: August 23, 2011, 12:44:29 am »
Thank you!  I'm glad you like it.

Maplesong

  • Guest
Re: Swamp Water Material
« Reply #3 on: August 24, 2011, 06:27:50 pm »
How do you make water? I have some idea's but don't have a clue how to do it XD

Offline Myla

  • Curious Wanderer
  • *
  • Posts: 22
  • Floof-O-Meter: 5
  • Sparkle dawg... And proud of it. B\
    • View Profile
Re: Swamp Water Material
« Reply #4 on: August 24, 2011, 08:19:13 pm »
O_O wooow

Offline ToastGhost

  • Experienced Traveler
  • **
  • Posts: 221
  • Floof-O-Meter: 23
    • View Profile
Re: Swamp Water Material
« Reply #5 on: August 25, 2011, 03:02:11 am »
How do you make water? I have some idea's but don't have a clue how to do it XD

First you have to have the texture/s you want to use.  You can use up to two textures.  Make sure they are PNG files, and saved in the Textures folder.  Then find the Water material file in the Materials folder.  Copy it, then name it whatever you want.  Open it in word pad.  It should look like this:
Code: [Select]
vertex_program WaterVP cg
{
source water.cg
entry_point water_VP
profiles vs_1_1 arbvp1
}

fragment_program WaterFP cg
{
source water.cg
entry_point water_FP
profiles ps_2_0 arbfp1
}

fragment_program UnderWaterFP cg
{
source water.cg
entry_point underwater_FP
profiles ps_2_0 arbfp1
}

material WaterMat
{
technique
{
pass
{
lighting off
cull_hardware none
cull_software none
scene_blend alpha_blend
depth_write off

texture_unit
{
texture waterTex1.png
scale 0.4 0.4
scroll_anim -0.05 -0.05
}
texture_unit
{
texture waterTex2.png
scale 0.5 0.5
scroll_anim -0.08 0.1
}
}
}
}
material OceanMat
{
technique
{
pass
{
lighting off
cull_hardware none
cull_software none
scene_blend alpha_blend
depth_write off

texture_unit
{
texture waterTex1.png
scale 0.5 0.5
scroll_anim -0.03 -0.05
rotate 90
}
texture_unit
{
texture waterTex2.png
scale 0.4 0.4
scroll_anim -0.05 0.01
rotate 90
}
}
}
}
material WaterReflectMat
{
technique
{
pass
{
//depth_write off
scene_blend alpha_blend
vertex_program_ref WaterVP
{
param_named_auto worldViewProjMatrix worldviewproj_matrix
param_named_auto timeVal time 0.05
param_named scroll float 2
param_named scale float 1
param_named noise float 1
}
fragment_program_ref WaterFP
{
param_named colourTint float3 0.25 0.27 0.28
param_named noiseScale float 0.04
}
texture_unit
{
texture waves2.dds
filtering linear linear none
}
}

}
}
material UnderWaterMat
{
technique
{
pass
{
cull_hardware none
cull_software none
vertex_program_ref WaterVP
{
param_named_auto worldViewProjMatrix worldviewproj_matrix
param_named_auto timeVal time 0.05
param_named scroll float 2
param_named scale float 1
param_named noise float 1
}
fragment_program_ref UnderWaterFP
{
param_named colourTint float3 0.95 0.97 0.98
param_named noiseScale float 0.04
}
texture_unit
{
texture waves2.dds
filtering linear linear none
}
}

}
}

You can delete everything except this:

Code: [Select]
material WaterMat
{
technique
{
pass
{
lighting off
cull_hardware none
cull_software none
scene_blend alpha_blend
depth_write off

texture_unit
{
texture waterTex1.png
scale 0.4 0.4
scroll_anim -0.05 -0.05
}
texture_unit
{
texture waterTex2.png
scale 0.5 0.5
scroll_anim -0.08 0.1
}
}
}
}

Rename WaterMat to what you want, and replace both waterTex1.png and waterTex2.png with your own texture/s.

And that's it!  Just follow the directions in the first post to get it on a map, and enjoy your new water material.

O_O wooow

Thank you!

Offline Diet Coke

  • Experienced Traveler
  • **
  • Posts: 123
  • Country: 00
  • Floof-O-Meter: 0
  • I'M OBSESSED WITH DRAGONS NOW!
    • View Profile
Re: Swamp Water Material
« Reply #6 on: September 03, 2011, 06:25:11 pm »
... It doesn't work for me... :(
Help my Pokemon please! I love you forever!!!!

Offline ToastGhost

  • Experienced Traveler
  • **
  • Posts: 221
  • Floof-O-Meter: 23
    • View Profile
Re: Swamp Water Material
« Reply #7 on: September 03, 2011, 06:32:17 pm »
... It doesn't work for me... :(
How does it not work?  Does it show up white?  Does it crash the game?  Does it just say "cannot be found?"

Offline Diet Coke

  • Experienced Traveler
  • **
  • Posts: 123
  • Country: 00
  • Floof-O-Meter: 0
  • I'M OBSESSED WITH DRAGONS NOW!
    • View Profile
Re: Swamp Water Material
« Reply #8 on: September 03, 2011, 09:41:55 pm »
It shows up white.
Help my Pokemon please! I love you forever!!!!

Offline ToastGhost

  • Experienced Traveler
  • **
  • Posts: 221
  • Floof-O-Meter: 23
    • View Profile
Re: Swamp Water Material
« Reply #9 on: September 03, 2011, 09:57:24 pm »
Ah.  Are both of the water textures in your textures folder?  If so, are you typing "SwampWater" exactly?  Any other variation, including "swampwater" or "Swampwater" will cause it to show up white.