I would like to select an item in my inventory and place it on my Player character. Usually I put a HotSpot on the item I wish to allow to accept an Inventory item, but not sure how to do it on the dynamic Player itself.
I had the same issue, I tried and it worked but tiny issue. The Inventory Item works fine, right after I click on it. I wanted to drag the inventory item on to my player.
@harshat30: Please read the forum rules regarding the kind of detail you need to give when posting an issue. We need to see what you've done already before help can be given.
I have the same issue (I need to use an inventory item on my player(drag and drop it off on my player)). I followed your steps but not works as expected. I need to drag the item in my player but the item responds immediately after a click.
Harshat30, this may be a little late, but maybe you had an actionlist asset assigned to your item? AFAIK if you do, then the item will always trigger instantly no matter what... you'd had to make the hotspot react to usage instead of the item. i.e.: if what you want is the item to heal you, give you a new item, play audio or animations or anything, you'd have to detect the item used on the hotspot, through the hotspot itself (or custom code), then work from there instead.
Is this for a 2D or 3D game, and are you using Player-switching? If so, there's an Auto-sync Hotspot state? option that will automatically disable the Hotspot on the active Player.
Otherwise, share screenshots of the Player's root and Hotspot object (full Inspectors) at runtime and I'll see if I can spot what's wrong.
Comments
The need for "ActionList assets" is so that the interaction works regardless of which scene you're in. That ought to work, but let us know if not.
Hello! I've been trying to do the same thing, followed Chris' reply, but it didn't work out. Now, on to the details!
For an NPC, works fine, but not for the player. The hotspot isn't recognized. Neither when I hover over the player with the cursor, nor with the item.
I have added the collider and the hotspot component in the player's sprite object.
Can someone help? I'd be happy to provide more details if need be.
Thanks in advance
By the way, the AC version is 1.82.4
Is this for a 2D or 3D game, and are you using Player-switching? If so, there's an Auto-sync Hotspot state? option that will automatically disable the Hotspot on the active Player.
Otherwise, share screenshots of the Player's root and Hotspot object (full Inspectors) at runtime and I'll see if I can spot what's wrong.
I missed this option! Unchecked and it works. Thanks, Chris. (It was a 2D game with player switching)