draw_wave bug?

Moderators: GSH, VSMIT, Red Devil, Commando

Post Reply
APCs r Evil
Sabre
Posts: 299
Joined: Sat Feb 19, 2011 4:13 am

draw_wave bug?

Post by APCs r Evil »

I'm using draw_wave to render a flat ring and while it works just fine for that, I am having trouble with the texture.

Image

The wave section nearest the Scout is showing vsmoke.tga the way you would expect, but the rest of the ring appears to be using a different texture altogether. At first I thought the ring was horribly stretching the texture but you can see that the light and dark sections don't match up.

Below are the exact settings used to take that screenie. I don't know if this is a bug or just something I messed up, so feedback would be helpful. :D

[Ring]
simulateBase = "sim_smoke"
lifeTime = 20.2
renderBase = "draw_wave"
textureName = "vsmoke.tga"
textureBlend = "one one modulate"
startColor = "255 255 63 255"
finishColor = "255 127 30 0"
startRadius = 6.0
finishRadius = 20
animateTime = 20.2
waveAngle = 3.14159
waveDepth = 0.5
waveSegments = 32
"It is not only his right, but his duty...to find the verdict according to his own best understanding, judgment and conscience, though in direct opposition to the direction of the court." - John Adams
User avatar
S.cavA.rmyG.en
Sabre
Posts: 296
Joined: Fri Mar 04, 2011 3:15 am
Location: ISDF Junk Yard
Contact:

Re: draw_wave bug?

Post by S.cavA.rmyG.en »

try this

Code: Select all

[Ring]
simulateBase = "sim_smoke"
lifeTime = 20.2
renderBase = "draw_wave"
textureName = "vsmoke.tga"
textureBlend = "one one modulate"
startColor = "255 255 63 255"
finishColor = "255 127 30 0"
startRadius = 6.0
finishRadius = 20
animateTime = 20.2
waveAngle = 3.15159 //test this
waveDepth = 0.5
waveSegments = 37 //and this
if those don't fix/do any thing then its probly a bug.
4 THINGS TO REMEMBER:
1.Professionals are predictable,amateurs are dangerous
2.If you can't remember, the Big Gun is always aimed at you.
3.If it's stupid but works, it's not stupid,it's crazy.
4.Anything you do can get you killed,even if it's nothing
User avatar
Nielk1
Flying Mauler
Posts: 2991
Joined: Fri Feb 18, 2011 10:35 pm
Contact:

Re: draw_wave bug?

Post by Nielk1 »

That is the last pixel on either side of the image repeating over and over. Might be a bug, to fiddle around. Normally the textures used are more single gradients than anything more complex, but I think FE pulled off a pattern OK.
APCs r Evil
Sabre
Posts: 299
Joined: Sat Feb 19, 2011 4:13 am

Re: draw_wave bug?

Post by APCs r Evil »

S.cavA.rmyG.en wrote:3.15159 //test this
waveSegments = 37 //and this
No dice. 3.15 created a small overlap area that was more opaque than the rest of the ring. Adding more waveSegments seemed to get rid of that overlap area but not spread the texture throughout the ring.
Nielk1 wrote:That is the last pixel on either side of the image repeating over and over.
Sure enough. Tried using lightflare.tga and the only the lightflare was visible in that small section, no visible ring

Looks like the texture is only applied to the first wave segment, and I also noticed that the wave I posted doesn't slowly fade over time, so its finishColor alpha is never used, only the startColor alpha. Although for some reason the finishColor colors are used...
"It is not only his right, but his duty...to find the verdict according to his own best understanding, judgment and conscience, though in direct opposition to the direction of the court." - John Adams
User avatar
TheJamsh
Bull Dog
Posts: 689
Joined: Sat Feb 19, 2011 5:49 pm

Re: draw_wave bug?

Post by TheJamsh »

You could use a draw_geom effect if you want a workaround for the meantime. unfortunately draw_geom, draw_sphere and draw_wave are still pretty buggy in multi-world and I don't think that's likely to change soon.
Developer @ Stormtide
viewtopic.php?f=4&t=2350#p40547 << My UE4 Battlezone Project

ModDB - Battlezone II Unofficial Expansion Pack
User avatar
MrTwosheds
Recycler
Posts: 3059
Joined: Sat Feb 19, 2011 8:37 am
Location: Outer Space
Contact:

Re: draw_wave bug?

Post by MrTwosheds »

I think it was only ever intended to draw a simple gradient texture, its not like its a properly UV mapped object.
waveAngle = 3.14159 = Pi, increasing this will cause the overlap. Use drawgeom if you want something more complicated.
The Silence continues. The War Of Lies has no end.
User avatar
Red Devil
Recycler
Posts: 4398
Joined: Fri Feb 18, 2011 5:10 pm
Location: High in the Rocky Mountains

Re: draw_wave bug?

Post by Red Devil »

rounding error, perhaps? tried using more digits? 3.14159265359
If given the truth, the people can be depended upon to meet any national crisis. The great point is to bring them the real facts - and beer.
Abraham Lincoln

Battlestrat, FE, G66, In The Shadows, Starfleet, Uler, & ZTV

Lifetime member of JBS and NRA
User avatar
Nielk1
Flying Mauler
Posts: 2991
Joined: Fri Feb 18, 2011 10:35 pm
Contact:

Re: draw_wave bug?

Post by Nielk1 »

I wouldn't be surprised if the UV code is bad. Turns out that the code on the little circular gauge was bad for a long time and no one ever knew because it wasn't noticeable till an actual image texture was applied.
User avatar
TheJamsh
Bull Dog
Posts: 689
Joined: Sat Feb 19, 2011 5:49 pm

Re: draw_wave bug?

Post by TheJamsh »

Going back to my previous post, a draw_geom would probably be less expensive am I right? Less polygons to draw? (I'm guessing that draw_wave just uses a bunch of polies generated by the engine?)
Developer @ Stormtide
viewtopic.php?f=4&t=2350#p40547 << My UE4 Battlezone Project

ModDB - Battlezone II Unofficial Expansion Pack
User avatar
Nielk1
Flying Mauler
Posts: 2991
Joined: Fri Feb 18, 2011 10:35 pm
Contact:

Re: draw_wave bug?

Post by Nielk1 »

bugs should still be fixed... This should be tested in beta and then fixed if actually broken.
User avatar
MrTwosheds
Recycler
Posts: 3059
Joined: Sat Feb 19, 2011 8:37 am
Location: Outer Space
Contact:

Re: draw_wave bug?

Post by MrTwosheds »

Well I can't ever recall seeing anyone produce a full detail textured ring with it. Some evidence that it was ever different?
The Silence continues. The War Of Lies has no end.
User avatar
Nielk1
Flying Mauler
Posts: 2991
Joined: Fri Feb 18, 2011 10:35 pm
Contact:

Re: draw_wave bug?

Post by Nielk1 »

MrTwosheds wrote:Well I can't ever recall seeing anyone produce a full detail textured ring with it. Some evidence that it was ever different?
If that's true then we definitely have an issue to have fixed. I thought FE had some, but I don't recall.

I had a case where I put a texture on a circular gauge and found that when it had a certain value range the UV was all wrong on the element. I think it was Ken who fixed the gauge issue. This is probably just a case of similar issues.
User avatar
Red Devil
Recycler
Posts: 4398
Joined: Fri Feb 18, 2011 5:10 pm
Location: High in the Rocky Mountains

Re: draw_wave bug?

Post by Red Devil »

FE uses some expanding rings on water to simulate raindrops or some bubbles rising from the depths.
If given the truth, the people can be depended upon to meet any national crisis. The great point is to bring them the real facts - and beer.
Abraham Lincoln

Battlestrat, FE, G66, In The Shadows, Starfleet, Uler, & ZTV

Lifetime member of JBS and NRA
User avatar
MrTwosheds
Recycler
Posts: 3059
Joined: Sat Feb 19, 2011 8:37 am
Location: Outer Space
Contact:

Re: draw_wave bug?

Post by MrTwosheds »

Rings would be done with a simple gradient, where the image across the texture is the same anyway, so it wouldn't matter. I don't think it ever did draw a whole texture all the way round.
The Silence continues. The War Of Lies has no end.
User avatar
Nielk1
Flying Mauler
Posts: 2991
Joined: Fri Feb 18, 2011 10:35 pm
Contact:

Re: draw_wave bug?

Post by Nielk1 »

Even if it didn't, it should.
Post Reply