Hello,
Im creating a local multiplayer game based on real time battles.
I would like to use ORK inventory menu screen and add a custom item selector to navigate because i want to call a game event or script on the item selected and pass it as selected data.
Is this can be done?
Regards
  • Hm, I don't think it's possible to pass an item selected in an inventory menu to an event or script ... at least not without custom scripting.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Im thinking in creating a custom selector to retrieve the item from the slot in the inventory menu screen and call an script.
    Does the UI of the screen uses unity event system to move between slots?
    Can i identify the item if i select the slot?
    Is there an unique identifier of the item inside the inventory?
    Thanks for.your help GIL.
  • edited July 2017
    No, ORK uses a custom UI system internally to support both legacy and new UI systems.

    You could get the currently selected item when using item previews (Menus > Menu Settings > Status Preview Settings):
    if(ORK.GUI.PreviewShortcut != null)
    {
    ItemShortcut item = (ItemShortcut)ORK.GUI.PreviewShortcut.Shortcut;
    }


    Otherwise there's currently no easy way to get the selected item from the inventory menu screen - you'd have to change that in the code.
    Post edited by gamingislove on
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.