Spellcast "AND" Question

Eorzea Time
 
 
 
言語: JP EN FR DE
日本語版のFFXIVPRO利用したい場合は、上記の"JP"を設定して、又はjp.ffxivpro.comを直接に利用してもいいです
users online
フォーラム » FFXI » Jobs » Warrior » spellcast "AND" question
spellcast "AND" question
 Lakshmi.Niico
Offline
サーバ: Lakshmi
Game: FFXI
user: Kido
Posts: 31
By Lakshmi.Niico 2012-05-27 22:58:52  
I want to lock heca+1 in my aggressor set, only when blood rage is up, otherwise using phorcys. Obviously my "And" isn't working. Need help
Code
<if Spell="Ukko's Fury" buffactive="Aggressor" "AND" buffactive="Blood Rage">
				<equip when="precast">
                        <hands lock="yes">Hecatomb mittens +1</hands>
                        </equip>
				<action type="castdelay" delay=".2" />
				<action type="Equip" when="Precast" set="Ukko's Agg" />
		</if>
		
		<elseif Spell="Ukko's Fury" buffactive="Aggressor" "AND" notbuffactive="Blood Rage">
				<action type="castdelay" delay=".2" />
				<action type="Equip" when="Precast" set="Ukko's Agg" />
		</elseif>
 Ragnarok.Sekundes
Offline
サーバ: Ragnarok
Game: FFXI
user: Sekundes
Posts: 4189
By Ragnarok.Sekundes 2012-05-27 23:07:36  
I think the issue has to do with having the if spell ukko part since that is a check as well I think you either need another and there or to separate it out and just put the entire text in an if like this:
Code
<if Spell="Ukko's Fury">
	<action type="castdelay" delay=".2" />
	<if buffactive="Aggressor" "AND" buffactive="Blood Rage">
        <equip when="precast">
			<hands lock="yes">Hecatomb mittens +1</hands>
		</equip>
		<action type="Equip" when="Precast" set="Ukko's Agg" />
    </if>
	<elseif buffactive="Aggressor" "AND" notbuffactive="Blood Rage">
			<action type="Equip" when="Precast" set="Ukko's Agg" />
	</elseif>
</if>

You could probably clean up some duplicate lines here since the only difference is the hands. I did move the cast delay before the if so it wouldn't need to be duplicated. You could do the same for the line that gears the ukko's agg set but I wasn't sure how the rest of your sc is set up and I didn't want to mess it up.
 Lakshmi.Niico
Offline
サーバ: Lakshmi
Game: FFXI
user: Kido
Posts: 31
By Lakshmi.Niico 2012-05-27 23:15:42  
That doesn't quite work either. The problem is that sc isn't reading the "AND" correctly. I'm not sure if there's another way to code it so it recognizes both attributes? I tried using buffactive="Agressor|Blood Rage", and then leaving blood rage out of the 2nd /elseif, but it just stops at aggressor on the first one, and doesn't recognize the blood rage

mui confused
 Fenrir.Nightfyre
Offline
サーバ: Fenrir
Game: FFXI
user: Nightfyre
Posts: 11680
By Fenrir.Nightfyre 2012-05-27 23:20:12  
You can't have two of the same rule in a single statement like that. You can bypass that with an advanced rule though, and there just happens to be a buffactive equivalent:
Code
<if advanced='(bool)buffactive("Aggressor") AND (bool)buffactive("Blood Rage")'>


EDIT:

Quote:
I tried using buffactive="Agressor|Blood Rage"
A bar in that context means "or", so yeah, that wouldn't work for your case.
 Ragnarok.Martel
Offline
サーバ: Ragnarok
Game: FFXI
Posts: 2894
By Ragnarok.Martel 2012-05-27 23:27:29  
"And" is the default mode for any set of rules in one if statement. So you shouldn't need that "and" at all.

Not to mention, putting an "AND" like that in a rule crashes my XMLs on load. If you want to set the mode, then you'd do Mode="AND"(or Mode="OR"). But like I said, you shouldn't need to set it to AND, as it's the default.

As for why doesn't work. You can't have duplicate attributes. Meaning you can't have two Buffactives in one IF statement. You can do a buffactive, and a notbuffactive though.

Ehh, I was gonna offer some alternative code, but nightfyre beat me to it, and his is nicer anyway.
 Lakshmi.Niico
Offline
サーバ: Lakshmi
Game: FFXI
user: Kido
Posts: 31
By Lakshmi.Niico 2012-05-27 23:38:30  
Hurray for working xml again! Thanx so much for the help. Very much appreciated.