View Single Post
  #3  
Old 03-12-2017, 03:09 PM
ZombieSoul's Avatar
ZombieSoul
Sarnak
 
Join Date: Jan 2017
Posts: 31
Default

Before I had a bot enchanter I had something similar to this to work around the group buff issue.
Code:
sub EVENT_SAY {

	if($text=~/hail/i) {
		quest::say("Hail, $name.I can help you [clear] your mind.");
	}

	if($text=~/clear/i) {
		my $Group = $client->GetGroup();
		
 		if($ulevel >= 46) {
			if($Group) {
				#Koadic's Endless Intellect 2570
				$Group->CastGroupSpell($npc, 2570);
			}
			else {
				#Clairvoyance 5513
				$npc->CastSpell(5513, $userid);
			}
			quest::say("May your mind be clear, $name");
		}
		else {
			if($Group) {
				#Boon of the Clear Mind 1694
				$Group->CastGroupSpell($npc, 1694);
			}
			else {
				#Clarity 174
				$npc->CastSpell(174, $userid);
			}
			quest::say("May your mind be clear, $name");
		}
	}
}
I think npcs should be able to cast any spells including group spells as they were intended, so I may make a personal edit on my server.

Last edited by ZombieSoul; 03-12-2017 at 03:16 PM.. Reason: Tried to fix formatting
Reply With Quote