Page 1 of 1

Weird water bug

Posted: Sun Jun 24, 2012 5:02 am
by agentsmith38
Hello,

I've encountered a strange problem with the water, I dunno what it is. I added


Effect("Blur")
{
PC()
{
Enable(1);
Mode(1)
ConstantBlend(0.5)
DownSizeFactor(0.450)
}
}


In my .fx file, and then the problem started showing up. Anyone have any idea why this might be happening and if there's some solution?

Hidden/Spoiler:
Image

Re: Weird water bug

Posted: Sun Jun 24, 2012 11:40 am
by ARCTroopaNate
I've added those lines to many of my maps with water and there are no problems for me. Can you post an error log?

Re: Weird water bug

Posted: Sun Jun 24, 2012 12:11 pm
by willinator
To me that looks like a problem with the tga's that create the look of the water. Try opening each of them in gimp and saving without RLE compression. Also, make sure that you copied every single water tga required by the fx file, as well as all the bump images and .option files.

Re: Weird water bug

Posted: Sun Jun 24, 2012 1:52 pm
by Locutus
What you see there is the bump map.
Seems like your main water texture is missing or in the wrong format, just like willinator says.

Re: Weird water bug

Posted: Sun Jun 24, 2012 2:12 pm
by THEWULFMAN
Well the problem is the water only started acting up after the Blur lines were put in the fx, and the water goes back to normal after the lines are removed.

Re: Weird water bug

Posted: Sun Jun 24, 2012 2:59 pm
by Fiodis
Locutus wrote:What you see there is the bump map.
It looks more like a normal map. Try playing with the blur parameters one by one until you see which individual part, if any, is responsible.

Anyway, from the stock documentation:
Blur
Blur will be off by default now if you want to enable it add it to the .fx file. It would be better if it was not used because it is expensive, not worth the cost and it is better to enable features such as HDR and soft shadows. I’m considering removing it from the game because the HDR effect does similar processing.

Re: Weird water bug

Posted: Sun Jun 24, 2012 3:01 pm
by Marth8880
Hmm, could you post your entire .fx file?

Re: Weird water bug

Posted: Sun Jun 24, 2012 10:48 pm
by agentsmith38
Thanks for the help guys.

Hidden/Spoiler:
Effect("ColorControl")
{
PC()
{
Enable(1);
WorldBrightness(-30);
WorldContrast(0.48);
WorldSaturation(60);
}
}


Effect("Wind")
{
Enable(1);
Velocity(4.0, 3.0);
VelocityRange(2.0);
VelocityChangeRate(1);
}

Effect("Precipitation")
{
Enable(1);
Type("Streaks");
Range(12.5);
Color(216, 220, 228);
VelocityRange(1.0);
ParticleDensityRange(0.0);
CameraCrossVelocityScale(0.2);
CameraAxialVelocityScale(1.0);

GroundEffect("com_sfx_rainsplash");
GroundEffectSpread(8);

PS2()
{
AlphaMinMax(0.8, 1.0);
ParticleSize(0.06);
ParticleDensity(80.0);
Velocity(8.0);
StreakLength(1.7);
GroundEffectsPerSec(7);
}
XBOX()
{
AlphaMinMax(0.2, 0.3);
ParticleSize(0.02);
ParticleDensity(256.0);
Velocity(9.0);
StreakLength(1.0);
GroundEffectsPerSec(15);
}
PC()
{
AlphaMinMax(0.3, 0.45);
ParticleSize(0.02);
ParticleDensity(256.0);
Velocity(10.0);
StreakLength(1.0);
GroundEffectsPerSec(15);
}
}

Effect("Lightning")
{
Enable(1);
Color(160, 160, 160);
SunlightFadeFactor(0.1);
SkyDomeDarkenFactor(0.4);
BrightnessMin(1.0);
FadeTime(0.2);
TimeBetweenFlashesMinMax(60.0, 120.0);
TimeBetweenSubFlashesMinMax(0.01, 0.5);
NumSubFlashesMinMax(2, 5);
HorizonAngleMinMax(30, 60);
SoundCrack("kam_amb_thunder");
SoundSubCrack("kam_amb_thundersub");
}

Effect("WorldShadowMap")
{
Enable(1);
Texture("end_canopy");
LightName("world light");
TextureScale(70.0);
AnimationFrequency(0.1);
AnimationAmplitude0(2.0, 0.0);
AnimationAmplitude1(0.05,-0.1);
}

LightningBolt("skybolt")
{
Texture("lightning");
Width(30.0);
FadeTime(0.5);
BreakDistance(20.0);
TextureSize(30.0);
SpreadFactor(20.0);
MaxBranches(2.0);
BranchFactor(0.5);
BranchSpreadFactor(8);
BranchLength(80.0);
InterpolationSpeed(0.4);
NumChildren(1);
ChildBreakDistance(15.0);
ChildTextureSize(8.0);
ChildWidth(1.0);
ChildSpreadFactor(10.0);
Color(255,255,255,255);
ChildColor(255,255,255,150);
}


Effect("Water")
{

// general parameters
PatchDivisions(3,3);

// ocean parameters
OceanEnable(0);

// water event parameters
WaterRingColor(148, 170, 192,255);
WaterWakeColor(192, 192, 192,255);
WaterSplashColor((192, 192, 192,255);

// PC parameters
PC()
{
Tile(2.0,2.0);
Velocity(0.05,0.05);
LODDecimation(1);
MainTexture("nab2_water.tga");

RefractionColor(90 112, 90, 150);
ReflectionColor(200,200,200,200);
UnderwaterColor(32, 40, 32, 180);
FresnelMinMax(0.2,0.5)

NormalMapTextures("water_normalmap_",16,8.0);
SpecularMaskTextures("water_specularmask_",25, 4);
SpecularMaskTile(2.0,2.0);
SpecularMaskScrollSpeed(0.02,0.02);
}
}

Effect("MotionBlur")
{
Enable(1);
}

Effect("ScopeBlur")
{
Enable(1);
}

Effect(“HDR”)
{
Enable(1)
DownSizeFactor(0.23)
NumBloomPasses(3)
MaxTotalWeight(0.5)
GlowThreshold(0.3)
GlowFactor(1.0)
}



Effect("Blur")
{
PC()
{
Enable(1);
Mode(1)
DownSizeFactor(0.23)
}
}

I can't post the error log, since it's too large... but I did find this:

Message Severity: 3
..\PebbleFL\Common\PblConfig.h(71)
PblConfig: Data 6e6e8d54 expected string
m_auiArgs >= m_uiNumArgs*4 && m_auiArgs < CONFIG_MAX_DATA_ARGS*4

Any ideas what that is? :s

I "fixed" it, but I can't have those two lines together for some reason. It doesn't look as good either :|

ConstantBlend(0.5)
DownSizeFactor(0.450)

Still it shouldn't be like that, I'll continue to check for errors. Thanks again for the help

Re: Weird water bug

Posted: Mon Jun 25, 2012 12:15 am
by AceMastermind
Message Severity: 3
..\PebbleFL\Common\PblConfig.h(71)
PblConfig: Data 6e6e8d54 expected string
m_auiArgs >= m_uiNumArgs*4 && m_auiArgs < CONFIG_MAX_DATA_ARGS*4

forums/viewtopic.php?p=476655#p476655

Effect(HDR)

You're breaking the syntax by wrapping HDR with curly quotes.

Re: Weird water bug

Posted: Tue Jun 26, 2012 1:20 am
by agentsmith38
I managed to fix the bug, I apparently can't have

DownSizeFactor
ConstantBlend

Together, but that's okay, the effect I still get is good.
Hidden/Spoiler:
Image
Thanks again GT!

Re: Weird water bug

Posted: Tue Jun 26, 2012 2:06 am
by AceMastermind
What are your current video settings? When you play the stock Yavin: Temple map with your current video settings do you experience this bug? This is just one example that uses those two parameters together.
yavin1.fx
Hidden/Spoiler:
[code]Effect("Blur")
{
PS2()
{
Enable(1);
MinMaxDepth(0.95,1.0);
}
PC()
{
Enable(1);
Mode(1)
ConstantBlend(0.3)
DownSizeFactor(0.2500)
}
XBOX()
{
Enable(1);
Mode(1)
ConstantBlend(0.45)
DownSizeFactor(0.2500)
}
}
[/code]

Re: Weird water bug

Posted: Tue Jun 26, 2012 3:18 am
by agentsmith38
Huh. My settings are on max. I don't have that water problem on Yavin though. Pretty weird. I'll carefully look through Yavin and my map to see what I'm doing wrong...