Bug with decals

Posted By: 3run

Bug with decals - 07/16/11 18:01

I'm having problems with decals since I've started working with A8.
First I've faced problem with decal shadows, it looks like they have ZNEAR flag set on them grin
Quote:


And this happens with particles as well, they disappear if there is a decal shadow on the background.
Another problem with decal that I've faced, is that they really have ZNEAR flag set on sometimes grin
Quote:
I've made bulletholes here:

And when I walk away from it, decals appear throw the wall:

When I walk closer, they disappear again... and appear as soon as I walk away...
One more problem I've faced is this one:
Quote:



All sprites have proper alpha channel, and it worked flawlessly with A7, so there is nothing wrong with script and sprites as well.
I asked on the forum, no one can fix this, and I'm not the only one who faced this problem.
Some dude told me to read manual... and all of my stuff will work flawlessly, I do my best, but this one still doesn't work...
Posted By: jcl

Re: Bug with decals - 07/18/11 08:10

Please read here about how to use decals properly:

http://manual.3dgamestudio.net/ent_decal.htm

When particles disappear when you see a decal shadow, your particle number is too small. Either limit your particles and decals or increase the particle number.

Z-beating and elements appearing through walls are caused by a wrong clip_near/far range. Use careful level design and don't tamper with the view range settings. Otherwise increase clip_near and reduce clip_far until the problem is fixed.

I think this should be easily fixed by yourself - if not, please post again and we'll help.
Posted By: 3run

Re: Bug with decals - 07/18/11 08:38

Thank you, I've already tried to fix this myself (and not only me I guess):
Thread link
I've played with "clip_near" and "clip_far", but no results..
I've increased number of particles (actually, when I faced problem, I was using too much of them already), same no results...
I can post my script that I use to create decals, if needed, I think I'm using them pretty properly (worked great with A7).
Plus, one more question, why does model disappear if there is a decal shadow under it?
Posted By: jcl

Re: Bug with decals - 07/18/11 09:07

If you can't fix the problem yourself, please contact the support - they'll help fixing the level. Please prepare the level so that all view settings are at default, and the particle number is sufficiently high so that all your decals and particles are visible. Upload or send the level to them and they'll look into it.
Posted By: 3run

Re: Bug with decals - 07/18/11 09:25

OK, thank you.
Posted By: 3run

Re: Bug with decals - 07/18/11 11:51

I've managed to fix the problem, but the result isn't that good...
Here is the demo I've wanted to send to support team:
Download link (298.77 KB)
I found out, that I can fix most of the problems if I rice "clip_near" to number around "5".
But then I face another problem, like this:
Quote:
I would like to know how to avoid this... Do I still need to send anything to support team?
BTW, "clip_near" doesn't fix this problem:
Quote:




Posted By: painkiller

Re: Bug with decals - 07/18/11 13:13

the second problem is because lot of decals are in the same position, thats a common problem that doesn't happend just with decals, try to place models or blocks with their surfaces in the same place
Posted By: 3run

Re: Bug with decals - 07/18/11 13:17

Dude, try the same in A7! Different result.
Posted By: alibaba

Re: Bug with decals - 07/18/11 13:33

The first problem normally gets solved with clip_near, but i think in this case you model is too small, try to scale it up with MED laugh
Posted By: Slin

Re: Bug with decals - 07/18/11 13:58

Shouldn't turning off writing into the depth buffer for the decals solve that last problem?
Posted By: 3run

Re: Bug with decals - 07/19/11 07:30

Slin, how can I do that myself? How to disable depth buffer for decals?

JCL, is there any thing I need to do? Do I still need to contact support team with this?
Posted By: jcl

Re: Bug with decals - 07/19/11 07:35

Slin: z-beating comes from too-small differences in the z values of two objects. The decal doesn't write into the z buffer, it's sufficient that the underground writes into the z buffer.

3run: When you can't get the z beating go away with better clip_near/far settings, then yes, contact Support with your level. It's quite possible that A7 had a different decal z offset, and thus behaved different. However such offsets are changed for a reason. Most likely, the A8 offset is better suited for most levels than the A7 offset.
Posted By: jcl

Re: Bug with decals - 07/19/11 15:24

The support got your level. The final solution for the z beating problem is a new engine variable for setting the distance of the decal to its surface. This will be implemented in the next update. A7 had indeed a different distance, so the problem was not visible in A7.
Posted By: 3run

Re: Bug with decals - 07/19/11 17:32

OK, so in next update this will be fixed, am I right? If so, thank you for support and could you tell me, when nearly next update gonna come?
Posted By: 3run

Re: Bug with decals - 07/20/11 10:03

So?
Posted By: jcl

Re: Bug with decals - 07/20/11 10:52

When it's ready.
Posted By: 3run

Re: Bug with decals - 07/20/11 11:00

Sounds promising, thanks.
© 2024 lite-C Forums