Overlay flip/mirroring flags do not work on non-Weapon

Is there something that doesn't work right in the latest GZDoom? Post about it here.

Moderator: Developers

Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.

If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Overlay flip/mirroring flags do not work on non-Weapon

Postby Nash » Sat Jul 14, 2018 2:27 am

Run example file, "give test". The fist sprite is not mirrored as expected.

This problem doesn't happen if the overlay is ran from a Weapon.

Problem also persists if the overlay is ran from PlayerPawn. But example file only demonstrates problem from CustomInventory context.

Wiki page suggests overlays can be ran from PlayerPawns and CustomInventory. https://zdoom.org/wiki/A_Overlay

Code: Select allExpand view

class Test 
: CustomInventory
{
    Default
    
{
        Inventory.MaxAmount 1;
        +INVENTORY.UNDROPPABLE
        
+INVENTORY.UNTOSSABLE
        
+INVENTORY.AUTOACTIVATE
    
}

    action void DoStuff(void)
    {
        Console.Printf("blah");
    }

    States
    
{
    Use:
        TNT1 A 0
        
{
            A_Overlay(666, "DoStuff");
            A_OverlayFlags(666, PSPF_FLIP | PSPF_MIRROR, true); // doesn't work
        }
        Fail;
    Pickup:
        TNT1 A 0
        
{
            return true;
        }
        Stop;
    DoStuff:
        PUNG A 1 DoStuff();
        Loop;
    }
}
 


UPDATE:

Seems like almost nothing works. Alpha, renderstyle, nothing.

Code: Select allExpand view

            A_Overlay
(666"DoStuff");
            
A_OverlayFlags(666PSPF_FLIP PSPF_MIRROR PSPF_ALPHA PSPF_RENDERSTYLEtrue);

            
// none of these work
            
A_OverlayRenderStyle(666STYLE_Translucent);
            
A_OverlayAlpha(6660.5);

            
// this works though
            
A_OverlayOffset(666, -50);
Attachments
test.pk3
(462 Bytes) Downloaded 2 times
User avatar
Nash
Nash Muhandes
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia

Re: Overlay flip/mirroring flags do not work on non-Weapon

Postby Major Cooke » Sat Jul 14, 2018 4:54 pm

Does this work on other renderers too? I.e. anything beside OpenGL? That's the only one in the code where I could find that has it specifically set to weapons.
User avatar
Major Cooke
Slaughterer of Sewers
 
Joined: 28 Jan 2007
Discord: Major Cooke#0846

Re: Overlay flip/mirroring flags do not work on non-Weapon

Postby Nash » Sat Jul 14, 2018 11:40 pm

Nope, the different renderers make no difference. Sprite is still unflipped despite being told to flip.
User avatar
Nash
Nash Muhandes
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia


Return to Bugs

Who is online

Users browsing this forum: No registered users and 0 guests