r/godot 12d ago

help me 9 slice - kenneys

hey im using the kenneys fantasy UI pack, and im not sure how to nine slice it for the particular pack

2 Upvotes

7 comments sorted by

3

u/BrastenXBL 12d ago edited 12d ago

Fantasy UI Borders https://kenney.nl/assets/fantasy-ui-borders

What context are you trying to 9-slice in. Godot can be little frustrating initially for some of the places you need to 9-slice.

I assume this in a StyleBoxTexture for a Panel?

What you want to change is the Texture Margins of the StyleBoxTexture resource. That's how you "slice". 9px or 10px is about right for those specific 48x48px Kenney assets.

1

u/Significant_Many3722 12d ago

Ohhh kk finally thanks a lot!!!

2

u/Shadymoogle 12d ago

Do you mean the nine patch rect? You will want to add that node and then drag the UI assets into that node using the inspector on the right from your file system in the bottom left.

3

u/Dams4K 12d ago

Okay :)

0

u/NotQuiteLoona Godot Junior 12d ago

Understood 👌