Forum rules - please read before posting.

Inventory slide issue.

edited May 2015 in Technical Q&A
I want my inventory to be partly visible and slide it onmouse hover/enter.

I'm using AC inventory with pan from bottom. But it has 2 problems:

 One is the problem with the container it is too big. It uses too much screen space and I have some objects which needs to be interracted with mouse. So as  soon as I hover on the gameobject the inventory slides up.

How can I position the inventory further down out of the screen so only Inventory sign is visible and I still can use the space around if the inventory is idle?
image

Comments

  • edited May 2015
    I've tried to use a new menu button at the bottom and unlock the inventory when the mouse hovers on the new menu button. And then added to the Inventory menu properties Action list When turned off to Hide menu element inventory  and then straight after it Lock menu inventory. But as you can see it doesn't slide back down wards but simply disappears. If I add Engine pause between, with 0.2 time to let the inventory slide back it causes the inventory slide up and down partly twitching and jerking, if you hover in and out quickly on the new menu button.

    And it's a kind of ugly way, then instead just position the inventory box out of the screen partly visible as I described in the previous post.

    So how to go about it?
  • Try creating three separate menus:

    1) The lone "Inventory" button that is on display when the inventory bar is off (and positioned on the bottom of the screen).  Make this appear type During Gameplay.
    2) An invisible menu that covers the same area as 1), appear type On Mouse Over, with Ignore Cursor clicks checked.
    3) The full inventory bar + the "Inventory" button above it, appear type On Mouse Over, but locked on start

    What you'll want to do is unlock Menu 3) on as part of your ActionList when turn on for Menu 2).  If menu 1) is arranged above 3) in the stacking order, it'll be displayed behind it.  When you leave Menu 3), lock it again with ActionList when turn off.
  • edited May 2015
    Yes Chris that is what I did.

    But as I mentioned when I lock the inventory back again with ActionList when turn off  with first Hide menu element ( so it could nicely slide back down) and then goes Lock menu. It won't slide back nicely but simply disappears, since there is no wait till finished option there to wait till it Hide menu element is completed. And if I try to put Engine pause game with 0.2 sec wait, between these two to let it slide before it is locked, it causes some weird bugs as the menu sliding up and down after, or sliding with jerks up and down very fast. Due to this Engine pause game.
    image
    thanks for your help btw.
  • I'm afraid that with your talk of menu names without context, it's confusing to understand what you're doing, exactly.  But my method doesn't involve hiding or showing any elements: I'm referring to splitting the top button into a separate menu, when it's in the "down"  position.

    Your first Action has no text in the "Element to hide" field, so it's not going to do anything, but be aware: hiding/showing individual elements is an instant effect, there is no transition to wait for.
  • edited May 2015
    Yea, disregard that Hide menu element thing. Just bare with me :)

    It all works except the last steps.

    When we exit-mouse the inventory bar, it doesn't slide down, it disappears because we made it locked.
    There is no option to wait till the bar completed sliding back down and then lock it. Since when we lock it it is invisible and out of the screen since it is locked :)

    ____________________________________


    1. Made inventory, called Inventory, set it Start game locked off.
    2. Made a small menu at the bottom called UnlockInventory. So we could hover it and make the Inventory unlock and slide up.
    3. Made an ActionList "ActionUnLockInventory" and assigned it to UnlockInventory as Actionlist when turn on. Inside that ActionList "ActionUnLockInventory" I put Menu change state Unlock menu Inventory.

    ( So now it could slide up when I hover on that small UnlockInventory menu at the bottom, cause Inventory is now unlocked )

    4. Made an ActionList  "ActionLockInventory" and assigned it to Inventory as Actionlist when turn off. Inside that ActionList "ActionLockInventory" I put Menu change state Lock menu Inventory.

     So now when our mouse leaves Inventory it is locked and the space around can be used. But it doesn't slide down it simply dispappears, it doesn't wait for slide back.

    There it is, I hope this explains the problem.
    Thanks for taking your time on this one.
  • edited May 2015
    Ok, I think I solved this issue with the sliding Inventory down and not disapearing by adding Engine Pause with 0.2 sec to ActionList  "ActionLockInventory" and ActionList Kill  "ActionLockInventory"  to
    ActionList "ActionUnLockInventory".
     
    So now the Inventory slides back down and then gets locked and the space around is usable with out any twitching since I added that ActionList Kill that kills the pause if a player hovers on and off too fast.

    Still kind of ugly way though, instead of simply reposition the inventory slightly outside of the screen.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.