Skip to content

Variables

Lady-Binary edited this page Jun 12, 2021 · 8 revisions

Variables

The following variables are available in your EasyLOU LUA scripts.
Variables are not in alphabetic order. Rather, they are (somewhat) grouped by functionality.

Character Info

BACKPACKID: The ObjectID of the player's backpack, to be used with FindItem() etc.

CHARBUFFS: Array of buffs/debuffs curently applied to the player.

CHARDIR: The direction the player is facing.

CHARGHOST: True if the player is dead.

CHARID: The ObjectID of the player.

CHARNAME: The player's name.

CHARPOSX: The x coordinate of the current location of the player.

CHARPOSY: The y coordinate of the current location of the player.

CHARPOSZ: The z coordinate of the current location of the player.

CHARSTATUS: Contains G if player is in combat mode. Contains A if the player is frozen (i.e. casting).

CHARWEIGHT: The total weight of the player's backpack.

CHESTID: The ObjectID of the object equipped on the chest slot.

CHESTNAME: The Name of the object equipped on the chest slot.

HEADID: The ObjectID of the object equipped on the head slot.

HEADNAME: The Name of the object equipped on the head slot.

LEGSID: The ObjectID of the object equipped on the legs slot.

LEGSNAME: The Name of the object equipped on the legs slot.

LEFTHANDID: The ObjectID of the object equipped on the left hand slot.

LEFTHANDNAME: The Name of the object equipped on the left hand slot.

RIGHTHANDID: The ObjectID of the object equipped on the right hand slot.

RIGHTHANDNAME: The Name of the object equipped on the right hand slot.

Status Bar

STR: The player's str stat.

HEALTH: The player's hit points.

INT: The player's int stat.

MANA: The player's mana points.

AGI: The player's agility stat.

ATTACKSPEED: The player's attack speed. Not used?

STAMINA: The player's stamina.

DEFENSE: The player's defense. Not used?

VITALITY: The player's vitality. Not used?

PRESTIGEXPMAX: The player's prestige. Not used?

STEALTH: The player's stealth. Not used?

Last Action

COBJECTID: The current ObjectID.

LOBJECTID: The last ObjectID.

Find

FINDBUTTON: Array of all the buttons found by the FindButton() command. For each button, the following variables will be populated:
FINDBUTTON[i].NAME: Name of the button, to be used with ClickButton(). FINDBUTTON[i].TEXT: Text of the button, if any text is present.

FINDITEM: Array of all the items found by the FindItem() command. For each item, the following variables will be populated:
FINDITEM[i].DISTANCE: Distance of the item from the player.
FINDITEM[i].CNTID: ContainerID of the item.
FINDITEM[i].ID: ObjectID of the item.
FINDITEM[i].NAME: DisplayName of the item.
FINDITEM[i].X: X coordinate of the item.
FINDITEM[i].Y: Y coordinate of the item.
FINDITEM[i].Z: Z coordinate of the item.

FINDLABEL: Array of all the labels found by the FindLabel() command. For each label, the following variables will be populated:
FINDLABEL[i].NAME: Name of the label, to be used with ClickButton() if the label is clickable. FINDLABEL[i].TEXT: Text of the label, if any text is present.

FINDMOBILE: Array of all the mobiles found by the FindMobile() command. For each mobile, the following variables will be populated:
FINDMOBILE[i].DISTANCE: Distance of the mobile from the player.
FINDMOBILE[i].HP: HP of the mobile. FINDMOBILE[i].ID: ObjectID of the mobile.
FINDMOBILE[i].NAME: DisplayName of the mobile.
FINDMOBILE[i].TYPE: Type of the mobile (e.g. Friendly, etc)
FINDMOBILE[i].X: X coordinate of the mobile.
FINDMOBILE[i].Y: Y coordinate of the mobile.
FINDMOBILE[i].Z: Z coordinate of the mobile.

FINDPANEL: Array of all the panels found by the FindPanel() command. For each panel, the following variables will be populated:
FINDPANEL[i].ID: Id of the panel, to be used with ClickButton(), FindLabel(), etc..

FINDPERMANENT: Array of all the permanent objects found by the FindPermanent() command. For each permanent object, the following variables will be populated:
FINDPERMANENT[i].COLOR: Color of the permanent object.
FINDPERMANENT[i].DISTANCE: Distance of the permanent object from the player.
FINDPERMANENT[i].ID: ObjectID of the permanent object.
FINDPERMANENT[i].NAME: DisplayName of the permanent object.
FINDPERMANENT[i].STONESTATE: If the permanent object is a stone, state of the stone.
FINDPERMANENT[i].TEXTURE: Texture of the permanent object.
FINDPERMANENT[i].TREESTATE: If the permanent object is a tree, state of the tree.
FINDPERMANENT[i].X: X coordinate of the permanent object.
FINDPERMANENT[i].Y: Y coordinate of the permanent object.
FINDPERMANENT[i].Z: Z coordinate of the permanent object.

MONSTERSID: Array of ObjectID of the monsters in the nearby.

MONSTERSNAME: Array of Names of the monsters in the nearby.

MONSTERSHP: Array of HPs of the monsters in the nearby.

MONSTERSDIST: Array of distances of the monsters in the nearby.

Client Info

CLIVER: Client version.

CLIID: Client ID (i.e. process number).

CLIXRES: Client X resolution.

CLIYRES: Client Y resolution.

FULLSCREEN: If true, Client is in full screen mode.

CLIGAMESTATE: Login, Loading or Game.

LOUVER: Injected LoU.dll version.

SERVER: Server address.

TARGETFRAMERATE: Unity related. The target frame rate.

VSYNCCOUNT: Unity related. The number of VSyncs that should pass between each frame.

MAINCAMERAMASK: Unity related. The current main camera mask. If 0, no rendering will happen (i.e. huge performance savings). If -1, all layers will be rendered.

Miscellaneous

TARGETTYPE: The current target type. Can be None, Attack, ServerLoc, ServerAnyObj, or ServerDynObj.

TARGETLOADING: True when the target is still loading (e.g. while casting spells), false otherwise.

CLICKWINDOWX: The X screen coordinate of the last mouse click on the Client window. 0 is at the far left.

CLICKWINDOWY: The Y screen coordinate of the last mouse click on the Client window3. 0 is at the far bottom.

CLICKWINDOWZ: Not really used.

CLICKWORLDX: The X world coordinate of the last mouse click on the Client window. 0 is at the far left.

CLICKWORLDY: The Y world coordinate of the last mouse click on the Client window. 0 is at the far left.

CLICKWORLDZ: The Z world coordinate of the last mouse click on the Client window. 0 is at the far left.

MONSTERSNEARBY: If true, there are monsters in the nearby.

RANDOM: A random number generated by the client.

TIME: World time in seconds.

SCANJOURNALTIME: The timestamp of the last processed message.

SCANJOURNALMESSAGE: The last processed message.

COMMANDID: Last EasyUO command processed.

MOUSEWINDOWX: Current mouse X window position.

MOUSEWINDOWY: Current mouse Y window position.

MOUSEWINDOWZ: Current mouse Z window position.

MOUSEWORLDX: Current mouse X world position.

MOUSEWORLDY: Current mouse Y world position.

MOUSEWORLDZ: Current mouse Z world position.

MOUSEOVERUINAME: Name of the UI element at the current mouse position.

MOUSEOVERUIX: X coordinate of the UI element at the current mouse position.

MOUSEOVERUIY: Y coordinate of the UI element at the current mouse position.

CLICKPERID: ObjectID of the permanent object last clicked. Useful for Trees and Rocks.

CLICKOBJID: ObjectID of the object last clicked. Useful for pretty much any item.

CLICKOBJNAME: Name of the object last clicked. Useful for pretty much any item. Alternative approach.

CLICKOBJCNTID: ObjectID of the container of the object last clicked. Useful for pretty much any item.

MOUSEOVERPERID: ObjectID of the permanent object at the current mouse position. Useful for trees and rocks.

MOUSEOVERNAME: Name of the object at the current mouse position.

MOUSEOVEROBJID: ObjectID of the object at the current mouse position.

MOUSEOVEROBJNAME: Name of the object at the current mouse position. Alternative approach.

MOUSEOVEROBJCNTID: ObjectID of the container of the object at the current mouse position.