View Single Post
04-23-06, 05:57 AM   #22
Iruwen
A Kobold Labourer
Join Date: Apr 2006
Posts: 1
I have a problem which is not directly related to sct but maybe someone can answer my question.

sct has the capability to show when Overpower is available.

I found these lines in sct_event_config.lua:

[8] = {name="Overpower!", search="You attack. (.+) dodges.", r=256/256, g=256/256, b=0/256, iscrit=1, class={"Warrior"}},
[9] = {name="Overpower!", search="Your (.+) was dodged", r=256/256, g=256/256, b=0/256, iscrit=1, class={"Warrior"}},

Flexbar can do the same thing to show the Overpower button when it's usable. It only parsed for "dodges" and "was dodged" respectively though, so I modified their event handlers:

Code:
FBEventHandlers["CHAT_MSG_COMBAT_SELF_MISSES"] =
	function(event)
		if strfind(arg1, "You attack. (.+) dodges.") then
			FB_RaiseEvent("PlayerMiss", "dodge")
		end
	end

FBEventHandlers["CHAT_MSG_SPELL_SELF_DAMAGE"] =
	function(event)
	if strfind(arg1, "Your (.+) was dodged") then
		FB_RaiseEvent("PlayerMiss", "dodge")
	end
end
The problem is that the dodge Event still occurs (and the Overpower button pops up) when it is not actually usable - and sct doesn't show "Overpower". So my question would be if there is another condition that has to be considered in order to make it work correctly.
  Reply With Quote