|
|
|
 |
 |
 |
 |
|
 |
 |
|
 |
 |
|
 |
|
| Quests::Custom Custom Quests here |

01-12-2011, 03:44 PM
|
 |
Demi-God
|
|
Join Date: Nov 2007
Posts: 2,175
|
|
I would like to add the ability for the buff bot to do a random MGB and have it call out with minute warnings, like 5 minutes, 4, 3, 2, 1 just like a player would do. Players could still pay immediately and get what they want but they would occasionally zone in and be able to get a free MGB.
I am getting stuck on the 5 minute warning. There seems to be no way to pause for 60 seconds or is there ?
|

01-12-2011, 04:21 PM
|
 |
Demi-God
|
|
Join Date: Nov 2007
Posts: 2,175
|
|
Persistence is the key. I think I have it now.
|

02-09-2011, 03:34 AM
|
 |
Demi-God
|
|
Join Date: Oct 2010
Posts: 1,332
|
|
Quote:
Originally Posted by provocating
I would like to add the ability for the buff bot to do a random MGB and have it call out with minute warnings, like 5 minutes, 4, 3, 2, 1 just like a player would do. Players could still pay immediately and get what they want but they would occasionally zone in and be able to get a free MGB.
I am getting stuck on the 5 minute warning. There seems to be no way to pause for 60 seconds or is there ?
|
THIS would be great !!! 
|
 |
|
 |

05-10-2011, 10:55 PM
|
|
Sarnak
|
|
Join Date: Jan 2010
Location: USA
Posts: 51
|
|
I used the same set up, but I can't figure out what is wrong here, can anyone help?
Code:
sub EVENT_SAY{
$client->Message(7, " ");
my $NPCName = $npc->Ram();
if($text=~/Hail/i) {
if ($ulevel <= 10) {
quest::selfcast(5415);
quest::selfcast(5312);
quest::selfcast(5405);
quest::selfcast(5409);
quest::selfcast(5521);
quest::selfcast(5365);
quest::selfcast(278);
quest::selfcast(939);
quest::selfcast(3391);
quest::selfcast(5390);
$client->Message(315, "$NPCName whispers to you, 'Since you are level 10 or lower you get free buffs, $name! Good luck to you.'");
}
if (($ulevel > 10) && ($ulevel < 25)) {
$client->Message(315, "$NPCName whispers to you, 'Hello $name, I will give you buffs in exchange for 100 platinum.'");
}
if (($ulevel >= 25) && ($ulevel < 70)) {
$client->Message(315, "$NPCName whispers to you, 'Hello $name, I will give you buffs in exchange for 500 platinum.'");
}
if ($ulevel >= 70) {
$client->Message(315, "$NPCName whispers to you, 'Hello $name, I will give you buffs in exchange for 1,000 platinum.'");
}
}
}
sub EVENT_ITEM {
$client->Message(7, " ");
my $NPCName = $npc->Ram();
if ($platinum == 1000) {
if ($ulevel >= 70) {
quest::selfcast(5278);
quest::selfcast(5415);
quest::selfcast(5312);
quest::selfcast(5405);
quest::selfcast(5409);
quest::selfcast(5521);
quest::selfcast(5365);
quest::selfcast(278);
quest::selfcast(939);
quest::selfcast(3391);
quest::selfcast(5390);
$client->Message(315, "$NPCName whispers to you, 'Thank you $name!'");
} else {
$client->Message(315, "$NPCName whispers to you, 'Use the correct amount of platinum, $name!'");
quest::givecash($copper,$silver,$gold,$platinum);
}
}
if ($platinum == 500) {
if (($ulevel < 75)&&($ulevel >= 25)) {
quest::selfcast(5278);
quest::selfcast(5415);
quest::selfcast(5312);
quest::selfcast(5405);
quest::selfcast(5409);
quest::selfcast(5521);
quest::selfcast(5365);
quest::selfcast(278);
quest::selfcast(939);
quest::selfcast(3391);
quest::selfcast(5390);
$client->Message(315, "$NPCName whispers to you, 'Thank you $name!'");
} else {
$client->Message(315, "$NPCName whispers to you, 'Use the correct amount of platinum, $name!'");
quest::givecash($copper,$silver,$gold,$platinum);
}
}
if ($platinum == 100) {
if (($ulevel > 10) && ($ulevel < 25)) {
quest::selfcast(5415);
quest::selfcast(5312);
quest::selfcast(5405);
quest::selfcast(5409);
quest::selfcast(5521);
quest::selfcast(5365);
quest::selfcast(278);
quest::selfcast(939);
quest::selfcast(3391);
quest::selfcast(5390);
$client->Message(315, "$NPCName whispers to you, 'Thank you $name!'");
} else {
$client->Message(315, "$NPCName whispers to you, 'Use the correct amount platinum, $name!'");
quest::givecash($copper,$silver,$gold,$platinum);
}
}
if (($platinum < 100) || ($platinum < 500) && ($platinum > 100) || ($platinum < 1000) && ($platinum > 100) && ($platinum > 500) || ($platinum > 1000)) {
$client->Message(315, "$NPCName whispers to you, 'Use the correct amount of platinum, $name!'");
quest::givecash($copper,$silver,$gold,$platinum);
}
}
|
 |
|
 |

05-11-2011, 07:11 AM
|
|
Sarnak
|
|
Join Date: Jun 2006
Location: Tennessee, USA
Posts: 77
|
|
Without any details as to what's causing you the problems...
Try using:
Code:
my $NPCName = $npc->GetCleanName();
instead of:
Code:
my $NPCName = $npc->Ram();
|

05-11-2011, 07:35 AM
|
|
Sarnak
|
|
Join Date: Jan 2010
Location: USA
Posts: 51
|
|
Ok I'll try that, and the problem is when i hail the npc (Ram) just a blank line appears on my chat window.
|

05-11-2011, 07:38 AM
|
|
Sarnak
|
|
Join Date: Jun 2006
Location: Tennessee, USA
Posts: 77
|
|
Quote:
Originally Posted by Durge
Ok I'll try that, and the problem is when i hail the npc (Ram) just a blank line appears on my chat window.
|
If it still appears as a blank line, I would suggest removing everything inside of the if statement, and replacing it with a single output to test that your NPC functions.
example:
Code:
if($text=~/Hail/i) { $client->Message(315, "$NPCName whispers to you, 'Ugh... do I work?'"); }
If it works with the single line statement, in this post, and not with all of the other checks... that simply means you have an error inside of the IF bracket. Remove everything, then add one line at a time. (Remember to change your level, to the desired level that you want to check to make sure that it works.)
Usually, you will get a blank line if none of the IF brackets are triggered.
|
| Thread Tools |
|
|
| Display Modes |
Hybrid Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -4. The time now is 04:48 AM.
|
|
 |
|
 |
|
|
|
 |
|
 |
|
 |