Open FileEX opened 1 year ago
Hi! Can you provide WTR resource, please?
I sent the resource to you on discord
The flags do work, but they won't work for alphas that are too high in value.
Afaik this is the same bug that happens with the windshields but I'm unsure about that.
So what should be the maximum alpha value for the flag to work properly?
The flags do work, but they won't work for alphas that are too high in value.
Afaik this is the same bug that happens with the windshields but I'm unsure about that.
So what should be the maximum alpha value for the flag to work properly?
No idea tbh. Probably 127 and lower (less than 50%).
So what should be the maximum alpha value for the flag to work properly?
No idea tbh. Probably 127 and lower (less than 50%).
Should be 100(or 140, depends on entity type). But probably better to use flag "no_zbuffer_write" for glass, in that case an alpha doesn't matter. But note that when alpha is less than beforementioned value the usage of flag "draw_last" loses its meaning because alpha testing takes the stage.
100 is better to use in this case.
And yes, this flag can produce unexpected results in some conditions. It's the specifics of GTA:SA transparent objects sorting.
With "no_zbuffer_write" elements are visible through walls
This problem persists no matter what the alpha is set to. No matter if I set alpha to 140, 127, 100 it's still this bug and nothing changes. This bug appear when vehicle is so near to the glass, because when the vehicle/player is so far from the glass then everything looks fine.
With "no_zbuffer_write" elements are visible through walls
Seems like an another bug.
Please, create a test resource and attach to the issue. It would be easier to help with it.
With "no_zbuffer_write" elements are visible through walls
Seems like an another bug.
The "no_zbuffer_write" flag triggers when I get close to the window and the vehicle is not visible, then that vehicle is visible but is rendered later than the window with the "draw_last" flag. Look at this
Flag "draw_last" without flag "no_zbuffer_write" RESULT: So far: So near:
Flag "draw_last" with flag "no_zbuffer_write" RESULT: So far: So near:
Vehicle is rendered with no_zbuffer_write flag when dissapear without this flag
This problem persists no matter what the alpha is set to. No matter if I set alpha to 140, 127, 100 it's still this bug and nothing changes. This bug appear when vehicle is so near to the glass, because when the vehicle/player is so far from the glass then everything looks fine.
This is an important comment about distance. Because it explains the where the bug comes from and how to solve it. I have a possible solution but without a test resource cannot check the correctness of it.
This problem persists no matter what the alpha is set to. No matter if I set alpha to 140, 127, 100 it's still this bug and nothing changes. This bug appear when vehicle is so near to the glass, because when the vehicle/player is so far from the glass then everything looks fine.
This is an important comment about distance. Because it explains the where the bug comes from and how to solve it.
Did you still need a test resource?
Yes, it would be great. I have a possible solution but without a test resource cannot check the correctness of it.
This problem persists no matter what the alpha is set to. No matter if I set alpha to 140, 127, 100 it's still this bug and nothing changes. This bug appear when vehicle is so near to the glass, because when the vehicle/player is so far from the glass then everything looks fine.
This is an important comment about distance. Because it explains the where the bug comes from and how to solve it.
Did you still need a test resource?
Yes, it would be great. I have a possible solution but without a test resource cannot check the correctness of it.
I send a test resource to your discord, cuz this model is private and i can't attach this here
Okay, I just got the test resource. I have already responded in PM, but maybe it would be interested for someone else. This is not a bug actually, just a feature of GTA:SA renderer. The problem is quite common. Glass and other transparent objects must be a separate object. Without it glass isn't able to be sorted the correct way. Moreover, transparent objects must be separated so that a camera wouldn't be able to be positioned within the transparent object's bounding box.
Okay, I just got the test resource. I have already responded in PM, but maybe it would be interested for someone else. This is not a bug actually, just a feature of GTA:SA renderer. The problem is quite common. Glass and other transparent objects must be a separate object. Without it glass isn't able to be sorted the correct way. Moreover, transparent objects must be separated so that a camera wouldn't be able to be positioned within the transparent object's bounding box.
There is still bug with glass. Even with glass as separated object with alpha 100
Okay, I just got the test resource. I have already responded in PM, but maybe it would be interested for someone else. This is not a bug actually, just a feature of GTA:SA renderer. The problem is quite common. Glass and other transparent objects must be a separate object. Without it glass isn't able to be sorted the correct way. Moreover, transparent objects must be separated so that a camera wouldn't be able to be positioned within the transparent object's bounding box.
There is still bug with glass. Even with glass as separated object with alpha 100
Like I said, GTA SA rendering isn't perfect and has limitations. Seems like a glass object is too large to let SA handle it correctly. You cannot create one big object contains all transparent parts of a house. There are some considerations require you to separate all windows(but depends on the windows themselves) into isolated flat(not concave or convex) objects.
Describe the bug
Setting the "DRAW_LAST" flag for the model still doesn't change anything and transparent models still don't show vehicles and other objects behind them.
alphaTranasparent is set to true in the engineReplaceModel function.
I think that flags still doesn't work correctly.
Steps to reproduce
Load the model with transparent materials
Version
Multi Theft Auto v1.6-release-21890
Additional context
No response
Relevant log output
No response
Security Policy