Originally Posted by Tanoh
One bit of annoyance with this feature. Most noticed on other figts than Moroes though. If a player already have a raid icon he or she will not get the skull but will keep their raid icon. I wish there was some way to tell BW to replace it, and turn back to whatever the person had before once the effect has ended.
|
Telling BW to replace it would be easy enough: replace
function plugin:BigWigs_SetRaidIcon(player)
if not player or not self.db.profile.place then return end
if not GetRaidTargetIndex(player) then
SetIcon(player, self.db.profile.icon or 8)
lastplayer = player
end
end
with
function plugin:BigWigs_SetRaidIcon(player)
if not player or not self.db.profile.place then return end
SetIcon(player, self.db.profile.icon or 8)
lastplayer = player
end
in RaidIcon.lua in the Plugins folder, though you'd need everyone who's promoted in the raid to make the change (to make sure that the person who actually gets to set the icons has the change in their file, not sure how BW assigns priority).
Telling it to put the icon back afterwards is a little more difficult. If you're content with it putting the icon back only when the next person gets the 'bomb' (i.e., if this person was the last to get the bomb, he would never get his original icon back), you could do something along the lines of (dry-coded, so don't expect it to actually work...)
function plugin:BigWigs_SetRaidIcon(player)
if not player or not self.db.profile.place then return end
if lastplayer and lasticon then
SetIcon(lastplayer, lasticon)
lasticon = nil
end
if GetRaidTargetIndex(player) and not (GetRaidTargetIndex(player) = (self.db.profile.icon or 8)) then
lasticon = GetRaidTargetIndex(player)
end
SetIcon(player, self.db.profile.icon or 8)
lastplayer = player
end
You'll want to add a line, "local lasticon = nil", to the top of the file, under the declaration of lastplayer, and you may want to add "lasticon = nil" under "lastplayer = nil" to RemoveRaidIcon, to cover some bases, but the code has the idea of what you're looking to accomplish.