Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 1,643 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Visual pop when walls fade out #154038
09/14/07 09:32
09/14/07 09:32
Joined: Apr 2005
Posts: 95
San Francisco
TheStonerunner Offline OP
Junior Member
TheStonerunner  Offline OP
Junior Member

Joined: Apr 2005
Posts: 95
San Francisco
I'm using a modified version of the smart_walls action. The roof that I'm fading in and out has several pieces, but all are combined on one mesh. When the walls start to go invisible, one piece stays fully visible until everything else is almost as transparent as it will get, and vice versa on reappearing. The code is as follows:

action smart_walls
{
while (1)
{
if (vec_dist (my.x, camera.x) < 220) // play with this value
{
if (my.TRANSLUCENT == OFF)
{

my.TRANSLUCENT = ON;
my.alpha = 100;
while (my.alpha > 20)
{
my.alpha -= 10 * time;
wait(1);
}
}
}
else
{
if (my.TRANSLUCENT == ON)
{
while (my.alpha < 100)
{
my.alpha += 10 * time;
wait(1);
}
my.TRANSLUCENT = OFF;
}
}
wait (1);
}
}

Re: Visual pop when walls fade out [Re: TheStonerunner] #154039
09/14/07 14:26
09/14/07 14:26
Joined: Aug 2003
Posts: 2,011
Bucharest, Romania
George Offline

Expert
George  Offline

Expert

Joined: Aug 2003
Posts: 2,011
Bucharest, Romania
Please give me more information:
1) Where did you get the smart_walls action from?
2) What is the building code supposed to do?

Re: Visual pop when walls fade out [Re: George] #154040
09/17/07 07:30
09/17/07 07:30
Joined: Apr 2005
Posts: 95
San Francisco
TheStonerunner Offline OP
Junior Member
TheStonerunner  Offline OP
Junior Member

Joined: Apr 2005
Posts: 95
San Francisco
I got the Smart walls from an old AUM, I am not sure where, but all it did was turn invisible on and off. I think it's an issue with my video drivers, not the code, because models with an alpha channel have z-fighting issues, the same as in Maya with models there who have an alpha texture in their channel.

Now that that's solved, any idea how to fix the alpha problem?

Thank you George for such an immensely useful newsletter. Between the documentation and AUM I'm able to do anything I can imagine.

Re: Visual pop when walls fade out [Re: TheStonerunner] #154041
09/18/07 08:47
09/18/07 08:47
Joined: Apr 2005
Posts: 95
San Francisco
TheStonerunner Offline OP
Junior Member
TheStonerunner  Offline OP
Junior Member

Joined: Apr 2005
Posts: 95
San Francisco
Ah, figured it out. :-) It was a normals issue. Some of the models were partially flipped (made from pieces and some were also used in a Source level). That seems to confuse A7 for the whole level, since it doesn't know which normals face the same way.

Re: Visual pop when walls fade out [Re: TheStonerunner] #154042
09/18/07 10:36
09/18/07 10:36
Joined: Aug 2003
Posts: 2,011
Bucharest, Romania
George Offline

Expert
George  Offline

Expert

Joined: Aug 2003
Posts: 2,011
Bucharest, Romania
It's good to hear that you've got it to work; I had similar problems years ago but since the models were humans it was easy to find the problem.

Re: Visual pop when walls fade out [Re: George] #154043
09/21/07 04:26
09/21/07 04:26
Joined: Apr 2005
Posts: 95
San Francisco
TheStonerunner Offline OP
Junior Member
TheStonerunner  Offline OP
Junior Member

Joined: Apr 2005
Posts: 95
San Francisco
Yeah, I imagine it's easier with something like that. With this, what tipped me off was that there were other things that worked fine, and one person made the models that were flipping out.

Thank you again for the AUM. That has made my life a lot easier, and kept me from re-inventing the wheel. I'm able to fulfill dreams, both my own and those of others, with what I have learned here.


Moderated by  George 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1