You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For objects that can be constructed from file paths -- such as ColorSpaces, Sprites and Palettes -- I think it would be helpful to mention and to link to app.fs, specifically this section. This gives readers a heads up for how they can get greater flexibility over error handling, such as when a file path is invalid. I was messing around pcall and xpcall with inconsistent results before remembering app.fs. I'm still using xpcall for palettes loaded from presets (this is in Aseprite v. 1.3beta-6).
Alternatively, a more dramatic revision would be to remove constructors that accept file paths. Loading functions can then be shifted to app.fs, where it is clearer that an error may be raised, nil may be returned and more functionality for error handling can be provided.
Thank you for considering.
Best,
Jeremy
The text was updated successfully, but these errors were encountered:
Hi again,
This is a feature request.
For objects that can be constructed from file paths -- such as ColorSpaces, Sprites and Palettes -- I think it would be helpful to mention and to link to
app.fs
, specifically this section. This gives readers a heads up for how they can get greater flexibility over error handling, such as when a file path is invalid. I was messing around pcall and xpcall with inconsistent results before rememberingapp.fs
. I'm still usingxpcall
for palettes loaded from presets (this is in Aseprite v. 1.3beta-6).Alternatively, a more dramatic revision would be to remove constructors that accept file paths. Loading functions can then be shifted to app.fs, where it is clearer that an error may be raised,
nil
may be returned and more functionality for error handling can be provided.Thank you for considering.
Best,
Jeremy
The text was updated successfully, but these errors were encountered: