OSRS Plugin API
    Preparing search index...

    Class ObjType

    Class representing the base data of an OBJ type.

    Implements

    Index

    Methods

    • The ID of the un-certified and un-placeholdered variant of this Obj.

      Returns number

    • The ID of the certificate variant of this Obj.

      Returns number

    • Returns the description of the specified object, which is the text returned when running the examine op.

      Returns string

      description string for the object. local ironSword = osrs.Engine.Decoders.decodeObjType(osrs.gamevals.objtypes.iron_sword) osrs.print(ironSword:getName(), ": ", ironSword:getDesc())

    • Returns the type of the current entity.

      Returns TypecodeEntityType

      enum designating the type of the current entity.

      local loc = osrs.Engine.Decoders.decodeLocType(osrs.gamevals.loctypes.poh_portal_teak_empty)
      if(loc:getEntityType() == osrs.TypecodeEntityType.LOC) then
      osrs.print("Found type LOC")
      end

      local lesserdemon = osrs.Engine.Decoders.decodeNpcType(osrs.gamevals.npctypes.lesser_demon)
      if(lesserdemon:getEntityType() == osrs.TypecodeEntityType.NPC) then
      osrs.print("Found type NPC")
      end
    • Gets the id of the current datatype. Data types will return their type ID, which will match the id in gamevals.

      Returns number

      id of the current entity.

      local loc = osrs.Engine.Decoders.decodeLocType(osrs.gamevals.loctypes.poh_portal_teak_empty)
      if(loc:getEntityType() == osrs.TypecodeEntityType.LOC) then
      osrs.print("Found type LOC")
      end

      local lesserdemon = osrs.Engine.Decoders.decodeNpcType(osrs.gamevals.npctypes.lesser_demon)
      if(lesserdemon:getEntityType() == osrs.TypecodeEntityType.NPC) then
      osrs.print("Found type NPC")
      end
    • Table of ops that can be performed on this object in the player's inventory

      Returns OpTable

    • The ID of the model this Obj uses.

      Returns number

    • Returns the name of the entity.

      Returns string

      Returns the name of the entity as a string.

      local picked = osrs.Engine.MousePickingHelper.getPickedEntityTypecodes()
      for index, entity in pairs(picked) do
      local var = entity:getEntityTypeData()
      if(var ~= nil) then
      osrs.print(var:getName())
      end
      end
    • Table of available ops that can be performed on this NPC

      Returns OpTable

    • Table representing params stored in the config for this object.

      Returns ObjParamTable

    • The ID of the placeholder variant of this Obj.

      Returns number

    • A value matching ClientOp.WornSlots if equipable. Returns -1 if not equipable.

      Returns number

    • The value of this Obj.

      Returns number

    • The weight of this Obj.

      Returns number

    • True if this Obj is equipable.

      Returns boolean

    • True if this Obj is stackable in inventory.

      Returns boolean

    • True if this Obj is tradeable.

      Returns boolean

    • True if this Obj is two-handed.

      Returns boolean