Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 11-28-2008, 06:37 PM
Sylaei
Hill Giant
 
Join Date: Jan 2007
Posts: 124
Default Logging quests

I am wanting to log the activities of my quests. Such as char name, items turned in etc. I have tried adding the perl statements to log to a text file. Also tried using a sub. My quest broke in both cases.

What I would like todo, if there isn't already a way to do it, is to place a log sub in the plugins folder and call the log like this:
Code:
  plugin::log($name);
Question 1: Can we add other subs to the plugins folder and get them read by the server?

Question 2: Why didn't this work? or What error is lurking here?
Code:
sub log
{
    open FH, ">> test.log" or die $!;
    print FH @_;
    return 1;
}
Also, the server is running on debian and my permissions are set to allow the quest folder to be writeable by anyone.

Any thoughts or ideas are appreciated.

Thanks,
__________________
Syl

"The significant problems we have cannot be solved at the same level of thinking with which we created them."
Albert Einstein
Reply With Quote
  #2  
Old 11-28-2008, 08:33 PM
Sylaei
Hill Giant
 
Join Date: Jan 2007
Posts: 124
Default

Sorry guys, Just found the mlog/log.ini stuff. I'll look at that but I'm betting it will tell me what I need.

Thanks
__________________
Syl

"The significant problems we have cannot be solved at the same level of thinking with which we created them."
Albert Einstein
Reply With Quote
  #3  
Old 11-28-2008, 08:56 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

It might not work exactly as you want for everything, but I use this alot for tracking turn-ins and kills:

Code:
sub EVENT_DEATH {

$timestamp = localtime(time);

quest::write("bossdeaths.txt","[$timestamp]:$mname was killed by $name the $class.");

}
Or

Code:
sub EVENT_ITEM {

$timestamp = localtime(time);

  if (plugin::check_handin(\%itemcount, 4700 => 1)) {
    quest::say("Thank you, $name, here is your reward!");
    quest::exp(999);
    quest::ding();
    quest::summonitem(1234);
    quest::write("quests.txt","[$timestamp]:$name the $class completed the [insert quest name here] Quest in $zonesn.");
  }

}
They make it very easy to keep track of important things you want to track without feeding through tons of logs.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #4  
Old 11-29-2008, 04:29 AM
Sylaei
Hill Giant
 
Join Date: Jan 2007
Posts: 124
Default

Thanks, Trev.
Thats what I was looking for.
__________________
Syl

"The significant problems we have cannot be solved at the same level of thinking with which we created them."
Albert Einstein
Reply With Quote
Reply

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 06:56 PM.


 

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