Holic bot FAQ
How do I setup my skills?
Open options.lua in notepad. You will need to add the skill to a usable skill list using the addSkill() function. The first parameter is the skill itself, and the second is the hotkey of the skill. There should already be a few skills listed as an example (for monk). You should probably remove all of the example entries listed and add your own.
You will need to first know the name of the skill you want to use. You can look this up in database/skills_<yourclass>.lua. So, if you're a priest, open database/skills_priest.lua. Look for the skill you want to use and copy it (ie. SKILL_SHININGSTRIKE1).
Now go back to options.lua, and insert a new line containing the addSkill() function with the skill you want to use (ie. SKILL_SHININGSTRIKE1) and the hotkey (ie. key.VK_1).
What about heals and buffs? How do I set up the bot to use those?
You don't. Just add the skill like demonstrated above, and the bot will automatically know how to use the skill. It's just that easy.
What if I want to use a skill that's not listed?
You will need to add an entry for it in your class's skills file in the database folder. Use one of the other skills as an example. A 'skill' table is created by using the skillInfo() function. A description of the function is as follows:
SKILL_THESKILLNAME1 = skillInfo("The Skill Name 1", cooldown, casttime, mana, requirements, targettype);
'cooldown' should be the cooldown of the skill (in seconds) +2. The +2 is to prevent using it too soon, and is not really required, but strongly suggested. For buffs that last longer than the cooldown, use the duration of the buff instead. For example, a 20 minute buff should have 20*60 as it's cooldown.
'casttime' should be how long the skill takes (in seconds) to cast. If no casttime is given, a value of 1 or 1.5 is suggested. If the casttime is given in the skill's description, it is suggested you had 0.5 to it (to prevent trying to use another skill before finished casting).
'mana' is the amount of mana the skill costs to cast. If no mana is required, use 0.
'requirements' is a flag data that describes what is required to cast the skill. If this is a normal attack, you can use REQUIREMENT_NONE or simply leave this blank (unless the next parameter is needed).
Requirement flags are as listed:
- REQUIREMENT_NONE - No requirement, use only in combat.
- REQUIREMENT_HURT - Only use this skill if you are hurt (recommended for healing skills)
- REQUIREMENT_MANALOW - Only use this skill if you have less than 75% mana
- REQUIREMENT_NOCOMBAT - Only use out of combat (recommended for buffs)
If you need to use more than 1 requirement, you should use bit.OR(requirement1, requirement2, ...) to construct this flag. For example:
-- this skill will only be used when below 75% mana, and out of combat.
SKILL_MYSKILL = skillInfo("My Skill", 20, 1, 35, bit.OR(REQUIREMENT_MANALOW, REQUIREMENT_NOCOMBAT);
'targettype' refers to target requirements. As of right now, this is only needed when a skill requires you to target yourself when in combat (like most heals and buffs). If this is a normal attack skill, just leave this parameter blank. If you must target yourself when you have an enemy selected, use TARGET_SELF for this parameter.
Please, if you are adding new skills, let me know. Go ahead and post them here so I can add that information to the database.
What if there is nothing listed for my class?
You will need to create all the information yourself. Start by adding a new file to the database folder. Follow the naming convention skills_<class>.lua. For example, 'skills_rogue.lua' would be an appropriate name. You should now fill this file with skill information tables using the method above.
The final step is including this new file. Open up skills_base.lua and go to the bottom. You will see several includes. Make sure to add your new file as another include. For example: