Jump to content
  • 0
Sign in to follow this  
Indomitus

RESOLVED [YLD-14451] Inventory/Equip/Drop error

Question

While trying to create a hat that was scripted to automatically equip itself when picked up, I found a strange glitch.  It does equip, but still remains in the player's hands if it goes into any slot of the hotbar.  It makes it look as if there are 2 of the item.  When it is active in the player's hands, they can press X to drop it.  This removes the one from the player's head, but not the one from their hands.  BUT there is nothing left in the inventory, and pressing X will not drop another hat.  It also does not trigger the "Item Removed From Inventory" event in the hat (or in an Event Listener).  If I manually unequip it and move it into Inventory, then drop it, the script triggers correctly.

It's a strange error.  Maybe the video can explain better:

 

It happens with anything equipped on the body.

Event Listener also does not detect item dropped directly from being equipped on the body.

 

Attaching all logs, and the test scenario shown in the video (with a couple more test items added to it).

output_log.txt

output_log_clean.txt

output_log_game.txt

MY_GAME_NAME(8).zip

Share this post


Link to post
Share on other sites

3 replies to this bug / suggestion

Recommended Posts

  • 0

I had a similar error with the event listener,

When generating an object in the inventory, the event listener should activate when it is released, but it does not.

On the other hand, if the object is picked up from the ground, the script works correctly.

I also experience the error where the object remains in the inventory but can not be used, this happened to me when trying to eliminate the bear traps from the inventory.

 

 

Share this post


Link to post
Share on other sites
  • 0

I've had a similar issue where when using the Equip entity - spawn entity template function, if I had a specific active item it would sometimes not equip... such as a book I want the player to hold.

It would be really inconsistent and sometimes would work and something wouldn't.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×