SMN XML How To Get An Idle Set And Perp Set?

Eorzea Time
 
 
 
Language: JP EN FR DE
Version 3.1
New Items
users online
Forum » Windower » Spellcast Scripting » Summoner » SMN XML How to get an Idle set and Perp set?
SMN XML How to get an Idle set and Perp set?
 Sylph.Dasanuffadat
Offline
Server: Sylph
Game: FFXI
Posts: 259
By Sylph.Dasanuffadat 2013-12-15 03:23:51
Link | Quote | Reply
 
I'm still new to this whole XML stuff but have been trying to get it down. I'm trying to get it so if I'm idle without a pet I will change into my "Idle" gear. If I'm idle with a pet I want to idle in my "Perp" gear. If I'm idle with Carbuncle/Diabolos out I want to idle in my "Perp" gear with their respective items.

With what I've written it doesn't seem to be working. After an action with my pet out I switch to "Perp" gear which is great. After an action without a pet out I switch to "Idle" gear which is also great. But when I have no pet out and summon a pet I switch to "Idle" gear which is bad. If I summon Carbuncle/Diabolos their gear is never switched to what I want it to which is also bad.

This is what I have so far:

Any help would be appreciated!

Edit: I seem to have gotten it working with this but is there any way to make it a little more simplified? I'd like to avoid variables if possible, they usually end up confusing me.
 Sylph.Dasanuffadat
Offline
Server: Sylph
Game: FFXI
Posts: 259
By Sylph.Dasanuffadat 2013-12-19 14:50:24
Link | Quote | Reply
 
Okay new issue with my perp set... Attempting to learn variables and can't find anything on why this won't work:

This is just an excerpt of the relevant parts of course. If the pet matches the day element or not its always equipping the Caller's Bracers and Evoker's Spats. No matter what I can't get my variable gear to equip the base gear (same issue on my DNC script actually).

Anyone know why?

Edit: Was trying it again and now that the day has changed in game it's not equipping the Caller's Bracer's/Evoker's Spats at all and only defaulting to my perp gear.
 Fenrir.Motenten
VIP
Offline
Server: Fenrir
Game: FFXI
user: Motenten
Posts: 764
By Fenrir.Motenten 2013-12-19 15:04:44
Link | Quote | Reply
 
<else PetIsValid="True"> is not a valid statement. The structure is:
Code
<if [condition]>
</if>
<elseif [condition]>
  -- may have multiples of these additional checks
</elseif>
<else>
  -- only run if all other tests have failed
</else>


Since your conditional is boolean (PetIsValid is either true or false, and can be nothing else), and you already tested one of the conditions with the <if [condition]>, you only need the <else> portion after that.

You also don't need the advanced check for pet element. You can use:

<if DayElement="%PetElement">

Also, if you're modifying your variable values for perp hand and legs, that needs to be done before the <equip> rules that might make use of them. as such, your dayelement check needs to go before your idle check.

Also, you don't have anything in place to change the vars back to their original if the dayelement does -not- match. Add that in with an <else> after the dayelement condition check.
 Sylph.Dasanuffadat
Offline
Server: Sylph
Game: FFXI
Posts: 259
By Sylph.Dasanuffadat 2013-12-19 16:14:22
Link | Quote | Reply
 
Fenrir.Motenten said: »
<else PetIsValid="True"> is not a valid statement. The structure is:
Code
<if [condition]>
</if>
<elseif [condition]>
  -- may have multiples of these additional checks
</elseif>
<else>
  -- only run if all other tests have failed
</else>


Since your conditional is boolean (PetIsValid is either true or false, and can be nothing else), and you already tested one of the conditions with the <if [condition]>, you only need the <else> portion after that.

You also don't need the advanced check for pet element. You can use:

<if DayElement="%PetElement">

Also, if you're modifying your variable values for perp hand and legs, that needs to be done before the <equip> rules that might make use of them. as such, your dayelement check needs to go before your idle check.

Also, you don't have anything in place to change the vars back to their original if the dayelement does -not- match. Add that in with an <else> after the dayelement condition check.

Ah, I see. That does make it a lot neater. Perp and Idle sets look better and still work so hurray on that. However I still can't seem to get the variables to work. I'm not sure of the command to fill in for the <else> after my dayelement <if>s. Also it won't even fill in the proper gear to begin with for some reason.

Edit: I guess all I needed to add was a "clear='true'" to my variables opening tag because I tried it on a whim and now it works almost perfectly. Perp gear still goes on as if pet has no element but after a command like assault, /heal, cure it equips what I want it to. So yay for that at least.
 Fenrir.Motenten
VIP
Offline
Server: Fenrir
Game: FFXI
user: Motenten
Posts: 764
By Fenrir.Motenten 2013-12-19 20:45:54
Link | Quote | Reply
 
Quote:
However I still can't seem to get the variables to work. I'm not sure of the command to fill in for the <else> after my dayelement <if>s.

Change:
Code
    <if advanced='"%petelement"="%dayelement"'>
        <var cmd="set PerpHand Caller's Bracers +1" />
        <var cmd="set PerpLegs Evoker's Spats" />
    </if>


to:
Code
    <if DayElement="%petelement">
        <var cmd="set PerpHand Caller's Bracers +1" />
        <var cmd="set PerpLegs Evoker's Spats" />
    </if>
    <else>
        <var cmd="set PerpHand Nashira Gages" />
        <var cmd="set PerpLegs Augur's Brais" />
    </else>


And put that -before- your equip commands.
 Cerberus.Vivik
Offline
Server: Cerberus
Game: FFXI
user: Detroit
Posts: 54
By Cerberus.Vivik 2013-12-19 21:48:00
Link | Quote | Reply
 
Here is the smn spellcast I use on my alt. Credit to the creators are in the comments of the spellcast. This will allow you to have three different idle sets. No pet, pet, and avatars favor. Maybe something you can build on.