• Hail, we're RedGuides. We want you to play six (yes, 6!) EverQuest characters at once. We have scripts and a friendly community to help, please join our playstyle and say hello! 👋
  • We've added LLM sections to our Terms & Rules and Resource Rules, for everyone's sanity & in-game safety.
    Read more
    a. Do not replace your voice with an LLM. This goes for your posts and your scripts. Drafting and editing with a tool is fine, but don't take you out of what you share.
    b. Do not replace your EQ character's voice with an LLM. We don't want scripts that speak over /ooc, /shout or other public channels. This has been an unwritten rule that's kept casino scripts off the site for decades, but we're now compelled to make it clear: keep automated communication private.

    Why Does RG Review Scripts?
    Nearly every LLM-written Lua script we see is making your character do impossible things, and rarely in a way that's beneficial to you. We've seen heavy server hammering, /target over impossible distances when /nav spawn would passively accomplish the same thing, a spawn search that fires 20+ times per second, and other pointless actions that are likely annoying GMs.

    You are welcome to use LLMs as a tool to structure, draft, and edit your work, but please read critically before hitting /lua run

Checking XTarget mana?

Is there a way to check one of your XTargets for Mana or Health level without targeting them? I have set my MT as XTarget 5 and want to create a shit to heal if below a health %. Looking to do the same with mana, but not as important.

Thanks in advance

PS this is on an emu server. xtargets work on it, but can't find the syntax for health check.

EDIT

Think I figured it out, need to use Spawn.

${Spawn[${Me.XTarget[5].ID}].PctHPs}<100)
 
${Spawn[${Me.XTarget[1]}].CurrentMana}<=50

or

${Spawn[${Me.XTarget[${i}]}].CurrentMana}<=50

Currantmana does not show the number it shows the % for everything but Group.

I wrote some code for a cleric to use QM on anyone in xtarget or in group that is below 50% mana and it works with this.
 
That works, but you can also consider: I forgot the differences between core code atm on whether or not core inherits .Spawn directly. If so you can maybe do ${Me.XTarget[1].Spawn.PctMana} (i forget the breakout for .PctHPs/.PctMana using raw spawn for core code so it might not work) or ${Me.XTarget[1].Spawn.CurrentMana}

It only matters because using the way you are makes it do twice as many checks every time for no particular reason. You can actually just set it to inherit in the core code quite easily as well if maskoi/redbot want to. All that gets added is a line in: pXTargetType->SetInheritance(pSpawnType);
 
${Group.MainTank.CurrentMana} <- This would actually be superior to the xtarget setup that you want to use assuming the main tank is in your group and tagged as Main Tank.

The only way you would need to use xtarget setup is if you were to set up your healer out of group to heal the tank inside another group.
 
Checking XTarget mana?

Users who are viewing this thread

Back
Top
Cart