How to detect I dropped item into the "world space"

Post » Sat Jun 21, 2014 9:33 pm

So, when doing this:

Event OnContainerChanged(ObjectReference akNewContainer, ObjectReference akOldContainer)
if (akNewContainer as actor)
; do nothing
else
Debug.Messagebox("Item was dropped into the world!")
endif
EndEvent
I do not want to see the message if the player puts the item into a container or anything but the "world" space.
How would I check that the item was dropped into the world?
Do I only need to do this: if (akNewContainer as actor) || (akNewContainer as ObjectReference)
User avatar
Kim Kay
 
Posts: 3427
Joined: Fri Oct 13, 2006 10:45 am

Post » Sun Jun 22, 2014 10:10 am

You can check if (akNewContainer == none) which will only be true when the item is either dropped into the world or consumed via crafting.

User avatar
Jarrett Willis
 
Posts: 3409
Joined: Thu Jul 19, 2007 6:01 pm

Post » Sun Jun 22, 2014 5:44 am

Thanks! :thumbsup:

User avatar
Quick Draw
 
Posts: 3423
Joined: Sun Sep 30, 2007 4:56 am


Return to V - Skyrim