Jump to content

Stopmacro condition


  • Please log in to reply
15 replies to this topic

#1 Raits

Raits
  • Junkies
  • Blood Elfclass_name
  • EU-Свежеватель Душ
  • Шквал
  • Posts: 10
  • Talents: Holy
  • RBG: 2474

Posted 15 December 2011 - 11:20 AM

Hi,

I'm wondering if there is a condition I can add to the /stopmacro command for me targetting myself.

Thx,Raits.

#2 hellsong

hellsong
  • Members
  • Orcclass_name
  • US-Illidan
  • Rampage
  • Posts: 119
  • Talents: Arms

Posted 15 December 2011 - 11:43 AM

try /stopmacro [target="yourname"]
where you want the macro to stop if you're targeting yourself, not sure if this works but it's worth a try
I have a really hot girlfriend

#3 Raits

Raits
  • Junkies
  • Blood Elfclass_name
  • EU-Свежеватель Душ
  • Шквал
  • Posts: 10
  • Talents: Holy
  • RBG: 2474

Posted 15 December 2011 - 11:45 AM

I tried everything like this...
/stopmacro [target=player]
/stopmacro [@player]
/stopmacro [target='myname']

etc. not working.

#4 Starcookie

Starcookie
  • Premium Junkies
  • Curse Premium
  • Humanclass_name
  • EU-Naxxramas
  • Sturmangriff / Charge
  • Posts: 2558
  • Talents: Discipline

Posted 15 December 2011 - 11:49 AM

I do not believe there is.

#5 Raits

Raits
  • Junkies
  • Blood Elfclass_name
  • EU-Свежеватель Душ
  • Шквал
  • Posts: 10
  • Talents: Holy
  • RBG: 2474

Posted 15 December 2011 - 11:57 AM

View PostStarcookie, on 15 December 2011 - 11:49 AM, said:

I do not believe there is.
Unfortunately you must be right. Ok then...

This macro:
#showtooltip Holy Shock
/cast Holy Shock
/cast [noharm,help] Righteous Defense
/stopmacro [harm] [noexists]
/cast Righteous Defense

May be there is a way, to make this macro NOT cast Righteous Defense when i targeting myself?

#6 NickyEU

NickyEU
  • Premium Junkies
  • Curse Premium
  • Orcclass_name
  • EU-Kazzak
  • Misery
  • Posts: 1263
  • Talents: Beast Mastery 1/0/0/2/1/0
  • RBG: 576

Posted 15 December 2011 - 12:16 PM

View PostRaits, on 15 December 2011 - 11:57 AM, said:

Unfortunately you must be right. Ok then...

This macro:
#showtooltip Holy Shock
/cast Holy Shock
/cast [noharm,help] Righteous Defense
/stopmacro [harm] [noexists]
/cast Righteous Defense

May be there is a way, to make this macro NOT cast Righteous Defense when i targeting myself?

Try and give me as much information on what you wan't the macro to do and I can try.
// Frozire // Nicky \\ Aphix \\

#7 Raits

Raits
  • Junkies
  • Blood Elfclass_name
  • EU-Свежеватель Душ
  • Шквал
  • Posts: 10
  • Talents: Holy
  • RBG: 2474

Posted 15 December 2011 - 12:26 PM

View PostNickyEU, on 15 December 2011 - 12:16 PM, said:

Try and give me as much information on what you wan't the macro to do and I can try.
Thx anyway.

I want this macro to cast Holy Shock on anyone. And cast Righteous Defense on anyone, but:

  • enemies (noharm,help condition in macro) working
  • no target (noexists condition in macro) working
  • myself < (can't make this work)

Edited by Raits, 15 December 2011 - 12:27 PM.


#8 Savary

Savary
  • Premium Junkies
  • Curse Premium
  • Night Elfclass_name
  • US-Tichondrius
  • Bloodlust
  • Posts: 20
  • Talents: Restoration
  • RBG: 384

Posted 15 December 2011 - 06:38 PM

Just keep the current macro you have then make a self target holy shock.


My holy shock key is 1 and if I want to holy shock myself I use a separate keybind for ALT+1

so just make a separate [target=insertnamehere] macro and you are set.
Posted Image

#9 Gix

Gix
  • Members
  • Undeadclass_name
  • EU-Anub'arak
  • Raserei / Frenzy
  • Posts: 131
  • Talents: Fire

Posted 15 December 2011 - 07:40 PM

Hello,

quite interesting topic :)

View PostRaits, on 15 December 2011 - 11:45 AM, said:

I tried everything like this...
/stopmacro [target=player]
/stopmacro [@player]
/stopmacro [target='myname']

etc. not working.

This is because "target=" etc. aren't conditions but assigns a target for a spell.


View PostSavary, on 15 December 2011 - 06:38 PM, said:

Just keep the current macro you have then make a self target holy shock.


My holy shock key is 1 and if I want to holy shock myself I use a separate keybind for ALT+1

so just make a separate [target=insertnamehere] macro and you are set.

He can't keep his current macro because Holy Shock is not the problem but Righteous Defense. If you target yourself you get those glowing hands under your curser, which is annoying I assume..

I think it's only possible with an addon or a macro with modifier although I'm not an expert with macros.

I would suggest to use a modifier like shift e.g.:
#showtooltip							 
/cast Holy Shock
/cast [mod:shift, help] Righteous Defense  -- you don't need "exists" here because "help" includes it already
So basically it always casts Holy Shock and if you want to use Righteous Defense you have to hold down "shift". And if you are the target, don't hold down shift ;)

so what did I do?
#showtooltip Holy Shock				-- no need for "Holy Shock here cause it's your first spell nevertheless
/cast Holy Shock
/cast [noharm,help] Righteous Defense  -- 1st: noharm and help are the same? 2nd: IF there is a method to use a
									   -- condition for "player" it has to be placed here. If you don't do it
									   -- it will cast Ritghteous Defense all the time because "help"
									   -- addresses you too!
/stopmacro [harm] [noexists]			 
/cast Righteous Defense


#10 Raits

Raits
  • Junkies
  • Blood Elfclass_name
  • EU-Свежеватель Душ
  • Шквал
  • Posts: 10
  • Talents: Holy
  • RBG: 2474

Posted 17 December 2011 - 02:20 PM

View PostGix, on 15 December 2011 - 07:40 PM, said:

Hello,

quite interesting topic :)



This is because "target=" etc. aren't conditions but assigns a target for a spell.

Thx mate. But I'm already using binds on Shift. Actually all my keyboard already full of binds, i can't use macro with modifier )

The main goal of this macro, as you can see, to disable that glitchy cursor, that appears when i cast this macro on myself. It's not really annoying, but when i cast RD on myself, i can't for example stan enemies until i actually cast it...

Edited by Raits, 17 December 2011 - 02:20 PM.


#11 Gix

Gix
  • Members
  • Undeadclass_name
  • EU-Anub'arak
  • Raserei / Frenzy
  • Posts: 131
  • Talents: Fire

Posted 20 December 2011 - 07:06 AM

View PostRaits, on 17 December 2011 - 02:20 PM, said:

Thx mate. But I'm already using binds on Shift. Actually all my keyboard already full of binds, i can't use macro with modifier )

The main goal of this macro, as you can see, to disable that glitchy cursor, that appears when i cast this macro on myself. It's not really annoying, but when i cast RD on myself, i can't for example stan enemies until i actually cast it...

Sorry I don't see any other solution than an addon, if you can't use a modifier. I also tried something like "SpellStopTargeting()" or "ClearCursor()" but it didn't work.

But maybe someone else knows?

Edited by Gix, 20 December 2011 - 07:08 AM.


#12 Pharaun

Pharaun
  • LocationSeattle, WA

Posted 20 December 2011 - 07:59 AM

View PostGix, on 20 December 2011 - 07:06 AM, said:

Sorry I don't see any other solution than an addon, if you can't use a modifier. I also tried something like "SpellStopTargeting()" or "ClearCursor()" but it didn't work.

But maybe someone else knows?
Addons cannot do things that are specifically blocked in macros.
"Who, after all, is today speaking of the destruction of the Armenians?"

-Adolf Hitler, 1939

#13 Gix

Gix
  • Members
  • Undeadclass_name
  • EU-Anub'arak
  • Raserei / Frenzy
  • Posts: 131
  • Talents: Fire

Posted 20 December 2011 - 08:49 AM

View PostPharaun, on 20 December 2011 - 07:59 AM, said:

Addons cannot do things that are specifically blocked in macros.
So in an addon you can't check if the target is the player?

#14 Pharaun

Pharaun
  • LocationSeattle, WA

Posted 20 December 2011 - 08:53 AM

You can check in a macro, but you can't do anything about it.

Finding out if your target is you is easy:

/run if UnitIsUnit("target","player") then print("I am targeting myself") end

Doing anything with it is impossible.
"Who, after all, is today speaking of the destruction of the Armenians?"

-Adolf Hitler, 1939

#15 Gix

Gix
  • Members
  • Undeadclass_name
  • EU-Anub'arak
  • Raserei / Frenzy
  • Posts: 131
  • Talents: Fire

Posted 21 December 2011 - 01:13 AM

View PostPharaun, on 20 December 2011 - 08:53 AM, said:

Doing anything with it is impossible.

Ah thanks Pharaun, I think I got it now:
- You can't use
/stopmacro [condition]
because there is no condition which checks if target=player.

- You can use scripts (or addons) to check whether target=player, but you can't use it because you can't stop your macro with something like
/run if UnitIsUnit("target","player") then StopMacro() end
because "StopMacro()" is a protected function of Blizzard.

Conclusion of this topic:
It's not possible in a macro/addon aside from using a modifier. ;)

Edited by Gix, 21 December 2011 - 01:18 AM.


#16 Raits

Raits
  • Junkies
  • Blood Elfclass_name
  • EU-Свежеватель Душ
  • Шквал
  • Posts: 10
  • Talents: Holy
  • RBG: 2474

Posted 25 December 2011 - 12:38 PM

Thx guys.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

<