Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Feature Requests

Development::Feature Requests Post suggestions/feature requests here.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #6  
Old 07-06-2009, 09:01 PM
Zeice
Sarnak
 
Join Date: Oct 2008
Location: USA
Posts: 92
Default

Yeah, so that definitely didn't work. I figured it out though. Not bad for my first attempt at doing anything with the code. However, as far as keeping it to your own stats I couldn't figure out how to do that. This atleast allows it to only work on clients and pets, which for me is the biggest thing.

SQL:

Code:
INSERT INTO commands VALUES ('mystats', '0', 'Allows player to view pet and client stats, but not npc');
File changes:

Code:
command.h
---------------

ADD

void command_mystats(Client *c, const Seperator *sep);

AFTER

void command_showstats(Client *c, const Seperator *sep);
Code:
command.cpp
----------------

ADD
		command_add("mystats","- Show details about you or your pet",50,command_mystats) ||

AFTER

		command_add("showstats","- Show details about you or your target",50,command_showstats) ||


ADD

void command_mystats(Client *c, const Seperator *sep)
{
	if (c->GetTarget() != 0 )
		if (c->GetTarget()->IsClient())
		c->GetTarget()->ShowStats(c);
	else if (c->GetTarget()->IsPet())
		c->GetTarget()->ShowStats(c);
	else
		c->ShowStats(c);
}


AFTER

void command_showstats(Client *c, const Seperator *sep)
{
	if (c->GetTarget() != 0 )
		c->GetTarget()->ShowStats(c);
	else
		c->ShowStats(c);
}
Reply With Quote
 


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 02:06 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