Jump to content

Get inventory item as Entity help


Recommended Posts

Posted

Hello all, I am trying to incorporate alching into a script but I can not seem to get it. I am currently using the getMagic().castSpellOnEntity(Spells.NormalSpells.HIGH_LEVEL_ALCHEMY, item); method. 

the "item" is gotten through the inventory like so: Item item = getInventory().getItem("item to alch"); but it says that Item cannot be used as an Entity (even though i looked into the api and it seems like Item extends the Entity class so I thought i would be able to turn an inventory into a useable entity.) 

can anyone guide me in the right direction? should i not use "CastSpellOnEntity" ? thanks :)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...