Go Back   EQEmulator Home > EQEmulator Forums > Support > Support::General Support

Support::General Support Post all topics here having to do with errors while trying to connect to an EQEMu server but not about the setup/running of the Server itself.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #5  
Old 07-15-2016, 04:40 PM
DanCanDo's Avatar
DanCanDo
Discordant
 
Join Date: May 2016
Location: Above Hell
Posts: 400
Default

This is the script I have on my buff bot. It checks for a group and levels, then
cast the appropriate spells.(setting NPC level to 70 helps with buff timer).

Code:
sub EVENT_SAY {
  if (($text=~/hail/i) && ($ulevel<46)) {
    quest::say("Hello $name, If you or your group need [Temp] or [Spirit] to run with, please gather near. I can also give you [Clarity] to help you on your journeys as well. When you reach 46 I can give you KEI and at 47 Virtue");
  }
  if (($text=~/hail/i) && ($ulevel>46)) {
    quest::say("Hello $name, If you or your group need [Virtue] or [KEI] or [Spirit] to run with, please gather near.");
  }
  if (($text=~/hail/i) && ($ulevel==46)) {
    quest::say("Hello $name, If you or your group need [Temp] or [KEI] or [Spirit] to run with, please gather near.");
  }
  elsif (($text=~/temp/i) && ($ulevel<47)) {
    my $Group = $client->GetGroup();
    if ($Group) {
      my $Valid = 1;
      for ($count = 0; $count < $Group->GroupCount(); $count++) {
        if ($Group->GetMember($count)->GetLevel() < 1) {
          $Valid = 0;
         }
      }
      if ($Valid == 1) {
        quest::say("Incoming Group Temp for $name.");
        $Group->CastGroupSpell($npc, 4053);
      }
      else {
        quest::say("Sorry $name. You are not at the appropriate level for that.");
      }
    }
    else {
      quest::say("Incoming Temp for $name");
	  my $GetPlayerID = $client->GetID();
	  $npc->CastSpell(3692, $GetPlayerID );
    }
  }
  elsif (($text=~/virtue/i) && ($ulevel>46)) {
    my $Group = $client->GetGroup();
    if ($Group) {
      my $Valid = 1;
      for ($count = 0; $count < $Group->GroupCount(); $count++) {
        if ($Group->GetMember($count)->GetLevel() > 65) {
          $Valid = 0;
         }
      }
      if ($Valid == 1) {
        quest::say("Incoming Group Virtue for $name.");
        $Group->CastGroupSpell($npc, 3479);
      }
      else {
        quest::say("Sorry $name. You are not at the appropriate level for that.");
      }
    }
    else {
      quest::say("Incoming Virtue for $name");
	  my $GetPlayerID = $client->GetID();
	  $npc->CastSpell(3467, $GetPlayerID );
    }
  }
  elsif (($text=~/clarity/i) && ($ulevel<66)) {
    quest::say("Incoming Clarity for $name");
	  my $GetPlayerID = $client->GetID();
	  $npc->CastSpell(174, $GetPlayerID );
  }
  elsif (($text=~/kei/i) && ($ulevel>45)) {
    quest::say("Incoming KEI for $name");
	  my $GetPlayerID = $client->GetID();
	  quest::selfcast(2570);
  }
  elsif (($text=~/spirit/i) && ($ulevel<66)) {
    my $Group = $client->GetGroup();
    if ($Group) {
      my $Valid = 1;
      for ($count = 0; $count < $Group->GroupCount(); $count++) {
        if ($Group->GetMember($count)->GetLevel() > 65) {
          $Valid = 0;
         }
      }
      if ($Valid == 1) {
        quest::say("Incoming Spirit of Bih'Li for $name.");
        $Group->CastGroupSpell($npc, 2524);
      }
      else {
        quest::say("Sorry $name. You are not at the appropriate level for that.");
      }
    }
    else {
      quest::say("Incoming SoW for $name");
	  my $GetPlayerID = $client->GetID();
	  $npc->CastSpell(278, $GetPlayerID );
    }
  }
}
Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 05:34 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3