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 02-20-2013, 04:29 PM
Dhrystone
Sarnak
 
Join Date: Feb 2013
Posts: 31
Default Implementing a leaderboard popup

Hi again all,

The mission is to have a hotkey button that players can press that will display a pop-up of the current 10 highest level characters on the server, without, if possible, any code changes.

How would I best go about doing that? No need for precise details, just a little help in finding the right direction to approach it.

My thoughts are an AA ability that would lead to a quest perl script that would do the popup.

Is that feasible? Is there an easier way?

Thanks
Dhry
Reply With Quote
  #2  
Old 02-20-2013, 07:46 PM
c0ncrete's Avatar
c0ncrete
Dragon
 
Join Date: Dec 2009
Posts: 719
Default

1) have lore masters for your world that are scripted via global_npc to query the character table via the DBI::mysql module. possibly enforcing limits to successive requests for updated info per client or account via qglobals to keep numb-skulls from hammering your database just because they can.

2) single qglobal with serialized info regarding the top 10 characters with characterid and max level being stored. check and update as required each time EVENT_LEVEL_UP is triggered in global_player script. could also use 10 separate qglobals and just check them all via looping through an array, i suppose. would have more room for data in each to deal with things like multiple entries (ties).

i'm probably only going to come up with more convoluted suggestions from this point... :|
__________________
I muck about @ The Forge.
say(rand 99>49?'try '.('0x'.join '',map{unpack 'H*',chr rand 256}1..2):'incoherent nonsense')while our $Noport=1;
Reply With Quote
  #3  
Old 02-21-2013, 04:20 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

For leaderboard stuff, I like using DBI and just make your own custom tables for tracking the data. Though, for something that simple, qglobals would probably work fine if you did it right.

As far as having a hotkey, I am sure you could do it via a custom AA, but that would also require a custom dbstr_us.txt file if you want the correct hotkey name and such to show up for them.

Alternatively, you could just add an EVENT_SAY to your global_player.pl script in the templates folder and use it to parse # commands. I haven't messed with it much, but quest parsing # commands was recently added by Akkadius and really opens up some cool options like that. Then, players could create their own hotkey to do something like "/say #leaderboard" and you would handle your popup menu from the EVENT_SAY.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #4  
Old 02-21-2013, 11:20 AM
Dhrystone
Sarnak
 
Join Date: Feb 2013
Posts: 31
Default

I definitely like the idea of using a # command for it. That's why I asked here -- I'd have never known that was an option and would have gone to a lot of trouble to make a weaker implementation. You guys are awesome.
Reply With Quote
  #5  
Old 04-16-2013, 03:36 AM
thepoetwarrior
Discordant
 
Join Date: Aug 2007
Posts: 307
Default

Sorry if this derails or hijacks the topic, but what would be some other good leaderboard topics or stats to put in?

HP Regen, Mana Regen, other stuff? What would be code to obtain those stats too?
Reply With Quote
Reply


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 09:14 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 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3