PDA

View Full Version : Discipline Trainer.


Zamthos
03-02-2013, 12:11 AM
All right, so this guy is supposed to train your disciplines for level 1-70, he does that part, but he doesn't set your qglobal because I can do it again.

sub EVENT_SAY
{
my $disc = quest::saylink("disciplines", 1);

if($text=~/Hail/i)
{
plugin::Whisper("Hello $name, would you like me to teach you all of your $disc?");
}

if($text=~/Disciplines/i)
{
if(!defined $qglobals{Discs})
{
quest::setglobal("Discs","1","5","F");
quest::traindiscs(70, 1);
}
else
{
plugin::Whisper("You have already trained all your disciplines, I have nothing more to teach you.");
}
}
}

c0ncrete
03-02-2013, 12:14 AM
qglobal = 1?

Zamthos
03-02-2013, 12:24 AM
What do you mean? I don't quite understand what you're trying to say. 0.o

c0ncrete
03-02-2013, 12:26 AM
in the npc_types table of the database. the qglobal field has to have a value of 1 or the npc in question won't have access to read qglobals.

Zamthos
03-02-2013, 12:31 AM
Ah, yeah, missed that, sorry, I don't usually miss the, "duh", stuff like that.

c0ncrete
03-02-2013, 12:34 AM
i did the same thing recently myself.

Zamthos
03-02-2013, 12:52 AM
Hehe, yeah, happens to everyone.