File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed
Plugins/UnLua/Source/UnLua/Private Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -1001,6 +1001,23 @@ static void GetFieldInternal(lua_State* L)
10011001 lua_pushvalue (L, 2 );
10021002 Type = lua_rawget (L, -2 );
10031003 bCached = Type != LUA_TNIL;
1004+ // check cached property from non-native class
1005+ if (bCached && !Field->OuterClass ->IsNative ())
1006+ {
1007+ auto Ptr = lua_touserdata (L, -1 );
1008+ if (Ptr)
1009+ {
1010+ auto Property = static_cast <TSharedPtr<UnLua::ITypeOps>*>(Ptr);
1011+ if (Property && Property->IsValid ())
1012+ {
1013+ auto PropertyDesc = static_cast <FPropertyDesc*>((*Property).Get ());
1014+ if (!PropertyDesc->IsValid ())
1015+ {
1016+ bCached = false ;
1017+ }
1018+ }
1019+ }
1020+ }
10041021 if (!bCached)
10051022 {
10061023 lua_pop (L, 1 );
You can’t perform that action at this time.
0 commit comments