mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-25 13:41:05 +00:00
Marked DrawPowerup as ui, still compiles and somewhat works :D
This commit is contained in:
parent
afc9050a43
commit
dbc595f886
5 changed files with 12 additions and 12 deletions
|
@ -6750,7 +6750,7 @@ bool FxStructMember::RequestAddress(FCompileContext &ctx, bool *writable)
|
||||||
if (ctx.Function)
|
if (ctx.Function)
|
||||||
{
|
{
|
||||||
outerflags = ctx.Function->Variants[0].Flags;
|
outerflags = ctx.Function->Variants[0].Flags;
|
||||||
if ((outerflags & (VARF_VirtualScope | VARF_Virtual)) && ctx.Class)
|
if (((outerflags & (VARF_VirtualScope | VARF_Virtual)) == (VARF_VirtualScope | VARF_Virtual)) && ctx.Class)
|
||||||
outerflags = FScopeBarrier::FlagsFromSide(FScopeBarrier::SideFromObjectFlags(ctx.Class->ObjectFlags));
|
outerflags = FScopeBarrier::FlagsFromSide(FScopeBarrier::SideFromObjectFlags(ctx.Class->ObjectFlags));
|
||||||
}
|
}
|
||||||
FScopeBarrier scopeBarrier(outerflags, FScopeBarrier::FlagsFromSide(BarrierSide), "<unknown>");
|
FScopeBarrier scopeBarrier(outerflags, FScopeBarrier::FlagsFromSide(BarrierSide), "<unknown>");
|
||||||
|
@ -6794,7 +6794,7 @@ FxExpression *FxStructMember::Resolve(FCompileContext &ctx)
|
||||||
if (ctx.Function)
|
if (ctx.Function)
|
||||||
{
|
{
|
||||||
outerflags = ctx.Function->Variants[0].Flags;
|
outerflags = ctx.Function->Variants[0].Flags;
|
||||||
if ((outerflags & (VARF_VirtualScope | VARF_Virtual)) && ctx.Class)
|
if (((outerflags & (VARF_VirtualScope | VARF_Virtual)) == (VARF_VirtualScope | VARF_Virtual)) && ctx.Class)
|
||||||
outerflags = FScopeBarrier::FlagsFromSide(FScopeBarrier::SideFromObjectFlags(ctx.Class->ObjectFlags));
|
outerflags = FScopeBarrier::FlagsFromSide(FScopeBarrier::SideFromObjectFlags(ctx.Class->ObjectFlags));
|
||||||
}
|
}
|
||||||
FScopeBarrier scopeBarrier(outerflags, membervar->Flags, membervar->SymbolName.GetChars());
|
FScopeBarrier scopeBarrier(outerflags, membervar->Flags, membervar->SymbolName.GetChars());
|
||||||
|
@ -8065,7 +8065,7 @@ isresolved:
|
||||||
if (ctx.Function)
|
if (ctx.Function)
|
||||||
{
|
{
|
||||||
outerflags = ctx.Function->Variants[0].Flags;
|
outerflags = ctx.Function->Variants[0].Flags;
|
||||||
if ((outerflags & (VARF_VirtualScope | VARF_Virtual)) && ctx.Class)
|
if (((outerflags & (VARF_VirtualScope | VARF_Virtual)) == (VARF_VirtualScope | VARF_Virtual)) && ctx.Class)
|
||||||
outerflags = FScopeBarrier::FlagsFromSide(FScopeBarrier::SideFromObjectFlags(ctx.Class->ObjectFlags));
|
outerflags = FScopeBarrier::FlagsFromSide(FScopeBarrier::SideFromObjectFlags(ctx.Class->ObjectFlags));
|
||||||
}
|
}
|
||||||
int innerflags = afd->Variants[0].Flags;
|
int innerflags = afd->Variants[0].Flags;
|
||||||
|
|
|
@ -708,7 +708,7 @@ public:
|
||||||
bool Final = false; // cannot be overridden
|
bool Final = false; // cannot be overridden
|
||||||
bool Unsafe = false; // Contains references to class fields that are unsafe for psp and item state calls.
|
bool Unsafe = false; // Contains references to class fields that are unsafe for psp and item state calls.
|
||||||
bool FuncConst = false; // [ZZ] readonly function
|
bool FuncConst = false; // [ZZ] readonly function
|
||||||
int BarrierSide = -1; // [ZZ] FScopeBarrier::Side
|
int BarrierSide = 0; // [ZZ] FScopeBarrier::Side
|
||||||
BYTE ImplicitArgs = 0; // either 0 for static, 1 for method or 3 for action
|
BYTE ImplicitArgs = 0; // either 0 for static, 1 for method or 3 for action
|
||||||
unsigned VirtualIndex = ~0u;
|
unsigned VirtualIndex = ~0u;
|
||||||
FName Name;
|
FName Name;
|
||||||
|
|
|
@ -1081,8 +1081,8 @@ bool ZCCCompiler::CompileFields(PStruct *type, TArray<ZCC_VarDeclarator *> &Fiel
|
||||||
|
|
||||||
// For structs only allow 'deprecated', for classes exclude function qualifiers.
|
// For structs only allow 'deprecated', for classes exclude function qualifiers.
|
||||||
int notallowed = forstruct?
|
int notallowed = forstruct?
|
||||||
ZCC_Latent | ZCC_Final | ZCC_Action | ZCC_Static | ZCC_FuncConst | ZCC_Abstract | ZCC_Virtual | ZCC_Override | ZCC_Meta | ZCC_Extension :
|
ZCC_Latent | ZCC_Final | ZCC_Action | ZCC_Static | ZCC_FuncConst | ZCC_Abstract | ZCC_Virtual | ZCC_Override | ZCC_Meta | ZCC_Extension | ZCC_VirtualScope :
|
||||||
ZCC_Latent | ZCC_Final | ZCC_Action | ZCC_Static | ZCC_FuncConst | ZCC_Abstract | ZCC_Virtual | ZCC_Override | ZCC_Extension;
|
ZCC_Latent | ZCC_Final | ZCC_Action | ZCC_Static | ZCC_FuncConst | ZCC_Abstract | ZCC_Virtual | ZCC_Override | ZCC_Extension | ZCC_VirtualScope;
|
||||||
|
|
||||||
if (field->Flags & notallowed)
|
if (field->Flags & notallowed)
|
||||||
{
|
{
|
||||||
|
@ -1102,11 +1102,11 @@ bool ZCCCompiler::CompileFields(PStruct *type, TArray<ZCC_VarDeclarator *> &Fiel
|
||||||
if (type->ObjectFlags & OF_Play)
|
if (type->ObjectFlags & OF_Play)
|
||||||
varflags |= VARF_Play;
|
varflags |= VARF_Play;
|
||||||
if (field->Flags & ZCC_UIFlag)
|
if (field->Flags & ZCC_UIFlag)
|
||||||
varflags = (varflags&~VARF_Play) | VARF_UI;
|
varflags = FScopeBarrier::ChangeSideInFlags(varflags, FScopeBarrier::Side_UI);
|
||||||
if (field->Flags & ZCC_Play)
|
if (field->Flags & ZCC_Play)
|
||||||
varflags = (varflags&~VARF_UI) | VARF_Play;
|
varflags = FScopeBarrier::ChangeSideInFlags(varflags, FScopeBarrier::Side_Play);
|
||||||
if (field->Flags & ZCC_ClearScope)
|
if (field->Flags & ZCC_ClearScope)
|
||||||
varflags = (varflags&~(VARF_UI | VARF_Play));
|
varflags = FScopeBarrier::ChangeSideInFlags(varflags, FScopeBarrier::Side_PlainData);
|
||||||
|
|
||||||
if (field->Flags & ZCC_Native)
|
if (field->Flags & ZCC_Native)
|
||||||
{
|
{
|
||||||
|
@ -2128,7 +2128,7 @@ void ZCCCompiler::CompileFunction(ZCC_StructWork *c, ZCC_FuncDeclarator *f, bool
|
||||||
if (c->Type()->ObjectFlags & OF_Play)
|
if (c->Type()->ObjectFlags & OF_Play)
|
||||||
varflags |= VARF_Play;
|
varflags |= VARF_Play;
|
||||||
if (f->Flags & ZCC_FuncConst)
|
if (f->Flags & ZCC_FuncConst)
|
||||||
varflags = (varflags&~(VARF_Play | VARF_UI)); // const implies clearscope. this is checked a bit later to also not have ZCC_Play/ZCC_UIFlag.
|
varflags = FScopeBarrier::ChangeSideInFlags(varflags, FScopeBarrier::Side_PlainData); // const implies clearscope. this is checked a bit later to also not have ZCC_Play/ZCC_UIFlag.
|
||||||
if (f->Flags & ZCC_UIFlag)
|
if (f->Flags & ZCC_UIFlag)
|
||||||
varflags = FScopeBarrier::ChangeSideInFlags(varflags, FScopeBarrier::Side_UI);
|
varflags = FScopeBarrier::ChangeSideInFlags(varflags, FScopeBarrier::Side_UI);
|
||||||
if (f->Flags & ZCC_Play)
|
if (f->Flags & ZCC_Play)
|
||||||
|
|
|
@ -813,7 +813,7 @@ class Inventory : Actor native
|
||||||
//
|
//
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
|
|
||||||
virtual bool DrawPowerup(int x, int y) { return false; }
|
virtual ui bool DrawPowerup(int x, int y) { return false; }
|
||||||
|
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
//
|
//
|
||||||
|
|
|
@ -934,7 +934,7 @@ class PowerFlight : Powerup
|
||||||
+INVENTORY.HUBPOWER
|
+INVENTORY.HUBPOWER
|
||||||
}
|
}
|
||||||
|
|
||||||
bool HitCenterFrame;
|
ui bool HitCenterFrame;
|
||||||
|
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in a new issue