Go Back   EQEmulator Home > EQEmulator Forums > Archives > Archive::Development > Archive::Development

Archive::Development Archive area for Development's posts that were moved here after an inactivity period of 90 days.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #6  
Old 07-02-2004, 01:01 PM
Draupner
Hill Giant
 
Join Date: Jul 2004
Location: In my basement
Posts: 131
Default

Set NPC Run Speed
Usage: #npcrun

command.cpp Line 258
Code:
command_add("npcrun","[run] [help] - Sets Run/Walk speed for an NPC",100,command_npcrun) ||  //Draupner: Set npc run speed
command.cpp Line 2653
Code:
void command_npcrun(Client *c, const Seperator *sep) //Draupner: Set npc speed
{
	if ( strcasecmp( sep->arg[1], "help" ) == 0 )
	{
		c->Message(0, "Walk/Run Speed Chart:  ");
		c->Message(4, "     (.7) Normal Walk Speed");
		c->Message(4, "     (1.05) 9k Mount");
		c->Message(4, "     (1.25) Normal Run Speed");
		c->Message(4, "     (1.375) Run 1");
		c->Message(4, "     (1.50) Run 2");
		c->Message(4, "     (1.625) Run 3");
		c->Message(4, "     (1.9375) Spirit of Wolf");
		c->Message(4, "     (2.675) 100k Mount");
		c->Message(4, "     (3.2) Max Bard Speed");
	}
	else if((sep->arg[1][0] == 0 || strcasecmp(sep->arg[1],"*")==0) || ((c->GetTarget()==0) || (c->GetTarget()->IsClient())))
	{
		c->Message(0, "Usage: #npcrun [run] [help]");
	}
	else
	{
		char errbuf[MYSQL_ERRMSG_SIZE];
		char *query = 0;
		c->Message(15,"NPCID %u now runs at %i",c->GetTarget()->CastToNPC()->GetNPCTypeID(),atoi(sep->argplus[1]));
		if (database.RunQuery(query, MakeAnyLenString(&query, "update npc_types set runspeed=%i where id=%i",atoi(sep->argplus[1]),c->GetTarget()->CastToNPC()->GetNPCTypeID()), errbuf))
			safe_delete_array(query);
	}

}
command.h Line 112
Code:
void command_npcrun(Client *c, const Seperator *sep); //Draupner: Npc Run Speed
AC will be done before I go to bed will try working on rest tomarrow.
Reply With Quote
 

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 01:57 AM.


 

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