Can you have more then one inventory?

  • #10, by nerdFriday, 15. March 2019, 20:20 5 years ago
    Tomorrow I'm gonna check it out. It could be also the interface image is full screen so "excecute immediate" doesn't work, this is probably the reason.

    Forum Fan

    147 Posts


  • #11, by nerdSaturday, 16. March 2019, 20:04 5 years ago
    The double inventory works. The problem is that no matter what "left click" on the items/portraits won't show the description under them, right now I'm using "right click" but I don't like it it's weird roll

    Forum Fan

    147 Posts

  • #12, by nerdSunday, 17. March 2019, 12:56 5 years ago
    I tried any combination. Any idea? roll

    Forum Fan

    147 Posts

  • #13, by afrlmeSunday, 17. March 2019, 13:34 5 years ago
    why is left clicking not working? have you tried setting the relevant command when you swap characters, or on mouse over of the item?

    Imperator

    7278 Posts

  • #14, by nerdSunday, 17. March 2019, 16:18 5 years ago
    The portraits in the inventory are items and unfortunately they don't have a mouse hover option roll

    Forum Fan

    147 Posts

  • #15, by afrlmeSunday, 17. March 2019, 17:08 5 years ago
    Aye I forgot they don't have a mouse over option - strange that, no? you would think they would have the option just like every other visobj that allows you to create an object area/interaction polygon.

    Having said that, you could use Lua script with a loop to check if the object below the cursor is an item.
    function checkItm()
    
     if game.CurrentObject.IsItem and game.ActiveCommand ~= Interfaces["example"].StandardCommand then
    
       game.CurrentCommand = Interfaces["example"].StandardCommand
    
     end
    
    end
    
    
    
    registerEventHandler("mainLoop", "checkItm")

    replace "example" with the name of the interface. add this script to the script section of the editor as a definition type script. I have no idea whether or not it will work.

    Imperator

    7278 Posts

  • #16, by nerdSunday, 17. March 2019, 17:50 5 years ago
    Thank you! I'll try it out! smile

    Forum Fan

    147 Posts

  • #17, by nerdSunday, 17. March 2019, 17:53 5 years ago
    Just a question how do I add this script as a definition type script? What does it mean?

    Forum Fan

    147 Posts

  • #18, by afrlmeSunday, 17. March 2019, 18:16 5 years ago
    I mean create a script in the script section of the editor. add the script. leave it as the default script type, which just so happens to be "definition".

    There are 3 script types in VS.

    Definition: script will be executed on game launch - mostly used for registering functions, variables, & event handlers/listeners.

    Execution: has to be manually called - mostly used for small scripts that don't require functions or input arguments.

    Execute a script: inline code that can be used the same as "execution" type script - mostly for small scripts or for accessing/updating functions/variables that you have created inside of "definition" type scripts.

    Imperator

    7278 Posts

  • #19, by nerdSunday, 17. March 2019, 18:26 5 years ago
    Thank you for the explanation smile

    Forum Fan

    147 Posts