Page 1 of 1

lovepatch - A 9-patch library for LÖVE

Posted: Fri Jun 30, 2023 12:02 pm
by notcl4y
There are already, of course, the 9-patch libraries for LÖVE. But they work different . :o: You had to place in the borders of the image the black pixels and, if I recall correctly, use .9.png file extension. I did not really like this. :P So I decided to make my own 9-patch library that would just let the user choose the width and height in the load() function alongside with the image path argument.

So here it is! :awesome:
https://github.com/notcl4y14/lovepatch
Thanks to darkfrei for helping writing the code.
demo.gif
demo.gif (1.26 MiB) Viewed 3311 times

Re: lovepatch - A 9-patch library for LÖVE

Posted: Fri Jun 30, 2023 6:21 pm
by darkfrei
Nice lib! Actually I've never heard about the 9patch, it was nice to learn something new.

Re: lovepatch - A 9-patch library for LÖVE

Posted: Fri Jun 30, 2023 6:22 pm
by notcl4y
darkfrei wrote: Fri Jun 30, 2023 6:21 pm Nice lib! Actually I've never heard about the 9patch, it was nice to learn something new.
Thanks!

Re: lovepatch - A 9-patch library for LÖVE

Posted: Sat Jul 01, 2023 4:25 pm
by pauljessup
Well that is really cool! Huh. I think I might update my simpleWindows thing to use that, since it already does edges/etc, it just doesn't scale with them/etc.

Re: lovepatch - A 9-patch library for LÖVE

Posted: Sun Jul 02, 2023 8:45 am
by notcl4y
pauljessup wrote: Sat Jul 01, 2023 4:25 pm Well that is really cool! Huh. I think I might update my simpleWindows thing to use that, since it already does edges/etc, it just doesn't scale with them/etc.
Thanks! It's nice to see when someone uses your library!

Sorry if I broke the logic in the sentence!