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
Copy file name to clipboardExpand all lines: docs/developers/bindings-api.mdx
+61-1Lines changed: 61 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ _Learn how to register new controller bindings._
12
12
13
13
Controlify allows users to configure different buttons on their controllers to actions in-game. You may want your own mod's actions to be able to be invoked from the controller too.
14
14
15
-
To register a controller binding, use the `ControllerBindingsApi.get()` method:
15
+
To register a controller binding, use the `ControlifyBindApi.get()` method:
16
16
17
17
```java
18
18
privateInputBindingSupplier actionBinding;
@@ -89,3 +89,63 @@ There are more properties available inside of `InputBinding` which you can look
89
89
There is nothing special about rendering glyphs for controller bindings, as Controlify utilises custom fonts.
90
90
91
91
This means you can use the glyphs within localised text, or just render it with `graphics.drawString(myBinding.inputGlyph(), x, y, -1);`
92
+
93
+
## Registering Custom Radial Icons
94
+
95
+
When registering a radial menu candidate, you must provide an icon to render it in the GUI.
96
+
You can use `RadialIcons.getEffect(...)` or `RadialIcons.getItem(...)` (for example, `RadialIcons.getItem(Items.REDSTONE)`).
97
+
98
+
However, **do not reference modded items directly** (e.g., `RadialIcons.getItem(ModItems.CUSTOM.get())`),
99
+
as item registration is deferred — meaning those items are not yet registered at this stage.
100
+
101
+
What you can do instead, is to reference the texture image file in the bundled resource-pack of your mod,
0 commit comments