- use a separate variable pointing to the current level for the UI code.
UI always runs on the primary level, so this does not need the ability to operate on multiple levels. Additionally, this can later be set to null when running play code so that scope violations result in an abort.
This commit is contained in:
parent
ba114f6f23
commit
4e052f2857
21 changed files with 107 additions and 103 deletions
|
|
@ -1369,11 +1369,15 @@ bool ZCCCompiler::CompileFields(PContainerType *type, TArray<ZCC_VarDeclarator *
|
|||
{
|
||||
Error(field, "Cannot add field %s to %s. %s has native children which means it size may not change", FName(name->Name).GetChars(), type->TypeName.GetChars(), type->TypeName.GetChars());
|
||||
}
|
||||
else
|
||||
else if (type != nullptr)
|
||||
{
|
||||
auto f = type->AddField(name->Name, thisfieldtype, varflags);
|
||||
if (field->Flags & (ZCC_Version | ZCC_Deprecated)) f->mVersion = field->Version;
|
||||
}
|
||||
else
|
||||
{
|
||||
Error(field, "Cannot declare non-native global variables. Tried to declare %s", FName(name->Name).GetChars());
|
||||
}
|
||||
}
|
||||
name = static_cast<ZCC_VarName*>(name->SiblingNext);
|
||||
} while (name != field->Names);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue