Thanks Capheus, I'll try the final "elsif" as an "else" instead, just as soon as I can get my global watchers in place again (deleted in my recent code update).
Quote:
I also don't see where it checks for loss of the ring, where I see ("$client->BuffFadeBySpellID();"), or changing their guild membership to the designated guild ("quest::setguild(0,1);"). It isn't checking for anything but for buffs.
|
Technically correct. To clarify, the script is looking for a change in the global flag called "kingdomfaction," which I referred to colloquially (in the language of the story line) as a "loss of the ring." The "ring" is item 13732, which when turned in to the "king" of a different faction changes the faction that receives the kingdom buffs. The kingdom buffs are continuous (they automatically rebuff when the buff fades) so long as that player's faction retains the "kingdomfaction" flag. When a specific kingdom faction becomes the recipient of the "kingdom blessing" buffs, they are also automatically placed into the "ring bearer" guild.
Once that faction is displaced by another faction in the global flag, the first faction
should be removed from the guild and placed in a different guild (that's one of the parts not currently working). Simultaneously, the script
should fade the buff found on any player of the first faction (again, this is one of the parts not currently working). Instead, the buff stays until it fades due to expired buff duration.
Quote:
Player zones in and it checks for item 13732
If player has item 13732 he/she gets aggro from a mob every 20 seconds until they leave the zone.
If they delete/lose item 13732 they still get aggro cause it only checks for the item when they zone in.
This timer repeats every 20 seconds
|
Correct. When a player obtains the ring (item 13732)--either by taking it from the reigning king after defeating him in battle, or by finding it after it becomes "lost"--the script tells the Ringwraiths in each zone to pursue him upon entry into that zone as he attempts to get the ring into the hands of his King. He will get aggro as long as he is alive and retains the ring. If a Wraith finds him, he will kill him (wraiths are very high level). Upon his death, the Ringwraith script nukes the ring from his inventory and sets the new qglobal. Since the player no long has the ring when he zones to his bind point, the Ringwraiths stop pursuing him.
Quote:
If player doesn't have item 13732 when they zone in it checks for the global set by some other npc or script not listed here.
|
Correct; the global is set by another script--either by the Ringwraiths or by the king he turns the ring into.
Quote:
I'd use quest::setglobal("kingdomfaction", 1, 5, "F"); for this one (All zones, All NPC, This player only)
|
Currently the function is quest::setglobal("kingdomfaction", 1, 7, "F"); . I think I must have used this based on a global quest I saw in another example. What would be the outcome of using 7 here instead of 5?
Quote:
Depending on the value of the global it checks for factionlevel and player level
So to make it simple a player will get a different buff depending on the qglobal/faction>850/playerlevel
|
Correct. The more faction a player has toward the reigning kindgom, the greater the blessing.
Quote:
If the player's factionlevel is less than 850 it checks to see if they have the buff depending on qglobal setting
If the player has the buff it debuffs them and changes their guild only if the qglobal was set at 1
|
Correct in its current form. There are three other kingdomfaction global options without the corresponding quest::setguild function. They will eventually be added, but I am waiting till I can get the first one to work correctly. Currently, neither the debuff object nor the setguild function is working.
Quote:
If the player doesn't have the buff it does nothing.
This timer repeats every one second
|
Correct.