Code cleanup.

This commit is contained in:
2023-01-27 17:30:10 +08:00
parent 130896df1f
commit c4b139c7a4
4 changed files with 6 additions and 6 deletions

View File

@@ -49,13 +49,13 @@ namespace Cryville.Crtr {
var ctype = Component;
var comp = (SkinComponent)obj.GetComponent(ctype);
if (comp == null) throw new InvalidOperationException(string.Format(
"Trying to set property {0} but the component is not found",
"Trying to set property \"{0}\" but the component is not found",
IdentifierManager.SharedInstance.Retrieve(Name)
));
SkinProperty result;
if (!comp.Properties.TryGetValue(Name, out result))
throw new InvalidOperationException(string.Format(
"Property {0} not found on component",
"Property \"{0}\" not found on component",
IdentifierManager.SharedInstance.Retrieve(Name)
));
return result;