Custom Auto Use

Custom Auto Use

Adds additional options to talent auto-use
Allows for extended auto-use of items and talents.
YOU CAN NOW RIGHT CLICK ITEMS in the hotkey bar!!!!!
A modification of xetaxheb's work.

Custom Auto Use forum discussion thread
Custom Auto Use on Steam's Workshop
See addon usage in the character's vault.
Your rating: None Average: 4.5 (2 votes)
Name Module Version Required Released File
Alchemist Support 1.3.1 2015-08-11 08:52
Added custom range option 1.2.2 2014-06-30 05:26
Custom Auto-Use 1.2.2 2014-06-27 09:58

Best Mod Ever, but have one question, and one request:

    • oops, wrong thread; how do I delete**

New update

Just wanted to give a heads up, i've thrown a bit more effort at this over here for the new year

Any chance of this one being

Any chance of this one being updated?

this is fantastic!

this is fantastic!

I really like this addon. I

I really like this addon.

I have 1 request. A flag that can be ticked that it should / should not use it while resting. (or if the position of the player hasn't changed since the last use)

Other than that... It needs to be implemented into the main game.

Hotbar Error

Every time I'll try to move talents on hotbar by mouse, or rightclick on empty space in hotbar, ToME drops lua error. Talent also often dissapears from hotbar when moved, so I need to use m menu to modify or move them.

Error for rightclick in empty space:

Lua Error: /mod/class/uiset/Minimalist.lua:1955: attempt to index local 'hk' (a nil value)
At [C]:-1 __index
At /mod/class/uiset/Minimalist.lua:1955 on_click
At ... custom_auto_use/superload/engine/HotkeysIconsDisplay.lua:50 onMouse
At /mod/class/uiset/Minimalist.lua:1942 fct
At /engine/Mouse.lua:56

Error for moving talent to other place on hotbar:

...custom_auto_use/superload/engine/HotkeysIconsDisplay.lua:56 attempt to index nil value
At [C]:-1 __index
At ...custom_auto_use/superload/engine/HotkeysIconsDisplay.lua:56 onMouse
At /engine/Mouse.lua:76

I use ToME 1.3.1 with ZOmnibus addon pack.


omg you sir rock! going now!

I Think Its Broke......

After 1.3.0 update unless i change hud UI to classic I get 100% load with a flashing freeze in game, really loved this add-on..sad to see it go.....

Yeah, i definitely found the

Yeah, i definitely found the extra options useful. If health is above/below a certain value, if nothing's going on, toggle on/off for abilities. I hope to see this updated and fixed soon.

Golem (and other secondary characters) glitch

I'm relatively certain that this addon, though one of my favorites, is the cause of a particular "infinite lua error" throw. When I have an item set to auto-use, switching to a secondary character, such as the alchemists golem, or the slave brawler in the hidden compound, infinite lua errors occur until the main character can be selected again (which doesn't happen with the slave brawler dude).

Since alchemist is my favorite class, I'm saddened that I can't take manual control of my golem with auto-use items on. If you can fix this, I'd be very appreciative. :) Thanks!

Feel free, though I've just

Feel free, though I've just finished the deadline that was preventing me from playing much/working on my version! Haha. I was gonna work on updating this tomorrow; but you've already done it better! I am not familiar enough with the ui code to do it this way, though I see the gist of how it works.

Honestly I'd like to recode

Honestly I'd like to recode the whole auto use system into 'turn this on, turn this off' instead of 'choose one of these' but I don't know how much access there is to do that. The menu as-is is horrible for the 2^x options there would be (life>50, life<50, elites, range, sight, adj, effect, phys, mag, men, vis/novis, novis/vis is already 4096, though obviously some of those would be irrational), and I don't have the experience with tome to do it properly right now :<

customizing options

Yeah i started to add the UI to be able to make any combination of effects possible (Press Alt-Shift-O then click on one of your skills. It is not currently actually hooked up but you see the gist). THE UI is there, but in practice it is much more difficult. The reason is that its difficult is related to trying to tell if the user intends the combination to be an AND or and OR and what grouping to apply. For example... these have wildly different effects:
(Physical detriment OR Mental detriment AND enemy is visible)
(Physical detriment AND Mental detriment OR enemy is visible)
(Physical detriment OR (Mental detriment AND enemy is visible))
(Physical detriment OR Mental detriment OR enemy is visible)
((Physical detriment OR Mental detriment) AND enemy is visible)
(Physical detriment AND Mental detriment AND enemy is visible)

So order and grouping matter. It would almost require an entire additional sudo language to make it work.
In the mean time it may be sensible to pick the to most requested and make a quick UI for it. I already have the select within multiple ranges written up so for example:
if Z between X% and Y%
if enemy visible and within X to Y tiles

I may just stick the whole thing up on github so people can see whats going on.

too much clutter or too advanced to use? decisions

Yup yup, honestly it would be very straightfoward and easy to make all options available through [turn this on, turn this off] combined with [preset list of options] but again there would be 2^x entries in the list or 2^(x-1) or some other huge number.


In order from your example, though obviously this isn't realistic having an enormous list to scroll:

[physical and visible] [mental and visible]
[physical and mental] [visible]
[physical][mental and visible]
[same as first, makes no sense otherwise, unless the first means physical xor mental]
[physical and mental and visible]

Each set of brackets requiring a check and if any return yes it triggers,
requiring at least 7 entries in the list for this example alone.
Putting aside the cpu of checking all the things for all the enemies for all the stuff every turn which would be necessary anytime something's not short circuited by [on cooldown],
you'd have to go through xxxx entries in a switch case lua equivalent, probably most easily done using bitwise or such, but really without a better interface for interacting with all this it's seeming less viable; even if we were to get to that point where the user's essentially using scripting... at that point they're basically coding AI.

I am not of a mind where 'auto use plays the game for you' (in a negative light) but maybe it would be better to stick to often used examples rather than obscure ones. How often does auto use really need to trigger above half health while under a mental detriment and no elite enemies within 2 to 8 tiles? (plus more than one enemy selector will generally be redundant, life <>50 conflict, and 'while resting' is really just a +1 instead of part of 2^x)

One thing to keep in mind is somehow short circuiting the 'vim within' or 'vim above' or what ever (and related energy bars) to not make entries in the list if they don't have the bar.
Items don't use bars and you have the bar permanantly as long as you have an ability associated with it right? I think. Or perma after getting it once. Either way.

Short circuiting stealth/invis related entries might be more complicated, since you'd have to check for each ability that grants it individually, and once modded classes enter the picture that would screw that up. So no removing there, probably.

'available' would probably need to reset all the other selected options to off, both as ease of reset and since it's implied when anything else is selected.

Edit: A nice extra addition would be 'Activated'/'Deactivated' at the top so one didn't have to recheck all the boxes but could temporarily turn on/off a skill specifically.
'if not activated then auto-use = 0 end'


Anyway, I probably won't work on this ui-version unless you put it up on github or something, and while I might update mine with some options it seems it might be redundant at this point, except for having a short term release goal of 'more options'; which I'm not opposed to doing.
I have used mine (and newly yours =P) in characters I've played when I had time to since releasing mine a few weeks ago, and felt a few lacking combinations.