• 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

Question - Code to Check HP/Buffs on Group Members

darkeros

Member
First of all, is there a code that checks a group member's HP like ${Target.PctHPs} does? If so, what do you change target to?

If the answer to the above is in the positive, is there a code to check the buffs of another person (with the intent to check the buffs of the groupmate and if X buff isn't on the list, then cast it)?
 
Rich (BB code):
			/if (${Group.Member[${i}].PctHPs} < 65) {
				/delay .5s
				/varset targetId ${Group.Member[${i}].ID}
				/goto :heal

Rich (BB code):
:heal 
|/echo Healing
	/if (${Me.CurrentMana}<${Spell["Superior Heal"].Mana}) {
		/return
	}
	/target id ${targetId}
	/cast 2
|/echo Return
/goto :loop


That should pretty much set you up for checking the group as a whole.
 
First of all, is there a code that checks a group member's HP like ${Target.PctHPs} does? If so, what do you change target to?

If the answer to the above is in the positive, is there a code to check the buffs of another person (with the intent to check the buffs of the groupmate and if X buff isn't on the list, then cast it)?

1) While you wont get the value of their HP like when you use ${Me.CurrentHPs}. ${Group.Member[#].PctHPs} will show you the % (0-100) but not the value (like 46385).

2) ${Group.Member[#].Buff[Insert Buff Here]} <- Note that this only works if the group leader has Inspect Buffs AA I think.
 
2) ${Group.Member[#].Buff[Insert Buff Here]} <- Note that this only works if the group leader has Inspect Buffs AA I think.

Have you tested this? I thought I had tried every combination of spawn/groupmember to check buffs. The only way I was ever able to check buffs on other players, was to actually target the player and then you can pull the info from the Target window. If this works I'll be happily making some changes to my buff code lol

Here is an example of what I've used in the past in case the above doesn't work.
Keep in mind this is from memory and I can't verify that it works as I am at work currently.
You may need to change ${sBuff${b}} to ${sBuff}${b} I can't remember.

Rich (BB code):
Sub Buff
/declare g        int      local
/declare b        int      local
/declare sBuff1 string local Clarity
/declare sBuff2 string local Brilliance
/declare BuffC  int      local 2

/for g 1 to ${Group}
/if (!${Group.Member[${g}].ID}) /goto :NextG
/target ID ${Group.Member[${g}].ID}
/delay 8
/for b 1 to ${BuffC}
/if (!${Target.Buff[${sBuff${b}}]}.ID} && ${Me.SpellReady[${sBuff${b}}]}) {
 /casting "${sBuff${b}}"
 /delays 1s ${Me.Casting.ID}
 /delays 25s ${Me.SpellReady[${sBuff${b}}]}
}
/next b
:NextG
/next g

/return

This example is assuming everyone is alive and within range of the buffer. You can add checks for HP, mana, distance, combat state, etc. It also has no way to compensate for people who have buffs blocked, higher level buffs that can't be overridden, etc... so you can run into problems where your buff toon will constantly recast the buff. I also personally use a 2-5min timer so that my toons don't constantly cycle targets.
 
Question - Code to Check HP/Buffs on Group Members

Users who are viewing this thread

Back
Top
Cart