- Joined
- Jun 7, 2008
- Messages
- 440
I've been trying to remove my items that I have dropped. It ends up being removed from the inventory. But it is not removed from game play. I have no idea whats going wrong. Here's what I have:
I havent posted the intire trigger. This is the only part that i can see that would have the problem.
JASS:
loop
if ( GetItemTypeId(UnitItemInSlot(u, index)) == 'I00L' ) then
call UnitRemoveItemFromSlot(u, index)
call RemoveItem(bj_lastRemovedItem)
set index = 7
else
set index = index + 1
endif
exitwhen index > 6
endloop
if ( GetUnitLevel(u) == 3 ) then
set shape = CreateItem('I01D', x, y)
call UnitAddItem(u, shape)
if (IsPlayerInForce(p, f)) then
call DisplayTextToPlayer(p, 0, 0,"TRIGSTR_1444")
endif
set shape = null
endif