gg.easy.airship 0.1.2181 → 0.1.2182
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -760,7 +760,7 @@ public partial class LuauCore : MonoBehaviour {
|
|
|
760
760
|
try {
|
|
761
761
|
ret = GetProperty(context, thread, instanceId, classNamePtr, classNameSize, propertyName, propertyNameLength, propertyNameAtom);
|
|
762
762
|
} catch (Exception e) {
|
|
763
|
-
ret = LuauError(thread, e.Message);
|
|
763
|
+
ret = LuauError(thread, $"{e.GetType()}: {e.Message}");
|
|
764
764
|
}
|
|
765
765
|
|
|
766
766
|
return ret;
|
|
@@ -789,8 +789,17 @@ public partial class LuauCore : MonoBehaviour {
|
|
|
789
789
|
// Get PropertyInfo from cache if possible -- otherwise put it in cache
|
|
790
790
|
PropertyGetReflectionCache? cacheData;
|
|
791
791
|
if (!(cacheData = LuauCore.GetPropertyCacheValue(classType, propName)).HasValue) {
|
|
792
|
-
|
|
793
|
-
|
|
792
|
+
PropertyInfo propertyInfo = null;
|
|
793
|
+
try {
|
|
794
|
+
propertyInfo = classType.GetProperty(propName,
|
|
795
|
+
BindingFlags.Public | BindingFlags.Static | BindingFlags.FlattenHierarchy);
|
|
796
|
+
} catch (AmbiguousMatchException) {
|
|
797
|
+
// If we get an ambiguous match we should use the type declared explicitly in this static class
|
|
798
|
+
// (rather than whatever inherited static is causing the ambiguity)
|
|
799
|
+
propertyInfo = classType.GetProperty(propName,
|
|
800
|
+
BindingFlags.Public | BindingFlags.Static | BindingFlags.DeclaredOnly);
|
|
801
|
+
}
|
|
802
|
+
|
|
794
803
|
cacheData = LuauCore.SetPropertyCacheValue(classType, propName, propertyInfo);
|
|
795
804
|
}
|
|
796
805
|
|