メインコンテンツまでスキップ

UI Item Trigger

UI Item Trigger

Binds items to views, so a view can be opened from the hand rather than from a key. Keys are deliberately absent: opening one's own inventory is resolved client-side and never reaches the server, so that key cannot be captured however the server is written.

フィールド

フィールド型デフォルト説明
bindingsList<UiItemBinding>emptyBindings from a material name to the viewId it opens on right-click
UiItemBinding(2)
フィールド型デフォルト説明
materialString—Material name, for instance COMPASS
viewIdString—viewId of the ui_view entry this item opens

How to use it​

Each binding maps a material (for example COMPASS) to a viewId opened on right-click while holding it in the main hand. An item can open only one view: if two bindings claim the same material the log lists both views and only the last declared one opens. Inventory keys cannot be bound, because opening one's own inventory never reaches the server.