RhenaudTheLukark / CreateYourFrisk

Rhenaud The Lukark's Unitale fork
GNU General Public License v3.0
132 stars 56 forks source link

Add default xml loading for sprite #101

Closed deonix37 closed 2 years ago

deonix37 commented 2 years ago

If someone needs to modify a default speech bubble, they have to duplicate the sprite and the corresponding xml file. This commit makes sure the default xml file is loaded in case if one is not provided (if no changes in file are needed), and also warns the user if the xml file for a speech bubble wasn't found anywhere. Also, isBubble here is unused

public static Sprite FromFile(string fullPath, string pathSuffix = "Sprites/", bool isBubble = false) {
RhenaudTheLukark commented 2 years ago

Modifying a font xml file means you absolutely need to also modify the font sprite, so I don't see any case where one might be modified and not the other.