CheckActorCeilingTexture ignores F_SKY1

Need help running G/Q/ZDoom/ECWolf/Zandronum/3DGE? Did your computer break? Ask here.

Moderator: GZDoom Developers

Guest

CheckActorCeilingTexture ignores F_SKY1

Post by Guest »

script "windsound" ENTER
{
if (CheckActorCeilingTexture(0, "F_SKY1"))
print (s:"You're outside!");
else
print (s:"You're inside!");

delay(1);
restart;
}

Prints "You're inside!" even if I am under the skybox.
And it works fine with another textures, but not with F_SKY1
User avatar
Kappes Buur
 
 
Posts: 4007
Joined: Thu Jul 17, 2003 12:19 am
Location: British Columbia, Canada

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Kappes Buur »

It does work when you include #include "zcommon.acs" at the top,
like so

Code: Select all

#include "zcommon.acs"

script "windsound" ENTER
{
if (CheckActorCeilingTexture ( 0, "F_SKY1") )
print (s:"You're outside!");
else
print (s:"You're inside!");

delay(1);

restart;
} 
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 47976
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Graf Zahl »

What game did you test this on? Hexen and Strife use different names for the sky texture.
Gez
 
 
Posts: 17633
Joined: Fri Jul 06, 2007 3:22 pm

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Gez »

Perhaps a dedicated "CheckActorOutside" function could be useful because the sky flat can be changed and there's also sector type 87.
User avatar
Bilbö Bägginson
Posts: 23
Joined: Mon Nov 30, 2020 11:11 pm
Discord: Bilbö Bägginson#4376
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: nVidia with Vulkan support

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Bilbö Bägginson »

I have like this:

in gameinfo section of ZMapInfo lump:

Code: Select all

skyflatname = "F_SKY1"
in ACS:

Code: Select all

#include "zcommon.acs"

script "windsound" (void)
{
 if (CheckActorCeilingTexture(0, "F_SKY1"))
    print (s:"You're outside!");
 else
    print (s:"You're inside!");

 delay(1);
 restart;
}
User avatar
Bilbö Bägginson
Posts: 23
Joined: Mon Nov 30, 2020 11:11 pm
Discord: Bilbö Bägginson#4376
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: nVidia with Vulkan support

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Bilbö Bägginson »

Gez wrote:Perhaps a dedicated "CheckActorOutside" function could be useful because the sky flat can be changed and there's also sector type 87.
Yeah this is exactly what i`m trying to do but how can I when it ignores "F_SKY1"?
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 47976
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Graf Zahl »

Please post your map. We can guess all we want but we need to see the problem in action to give any further advice.
User avatar
Bilbö Bägginson
Posts: 23
Joined: Mon Nov 30, 2020 11:11 pm
Discord: Bilbö Bägginson#4376
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: nVidia with Vulkan support

Re: CheckActorCeilingTexture ignores F_SKY1

Post by Bilbö Bägginson »

Solved!

while looking through the pk3 have found the cause. There was not "flats" folder with "F_SKY1" flat.
thanks anyway

Return to “Technical Issues”