mirror of
https://github.com/edubart/otclient.git
synced 2025-05-01 10:09:21 +02:00
allow useWith with inventory items
This commit is contained in:
parent
71c706157a
commit
85a121822e
@ -339,6 +339,9 @@ void Game::useWith(const ThingPtr& fromThing, const ThingPtr& toThing)
|
||||
return;
|
||||
|
||||
Position pos = fromThing->getPosition();
|
||||
if(!pos.isValid()) // virtual item
|
||||
pos = Position(0xFFFF, 0, 0); // means that is a item in inventory
|
||||
|
||||
int fromStackpos = getThingStackpos(fromThing);
|
||||
if(fromStackpos == -1)
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user