Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Bots

Development::Bots Forum for bots.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #11  
Old 10-03-2008, 06:59 PM
Angelox
AX Classic Developer
 
Join Date: May 2006
Location: filler
Posts: 2,049
Default

I changed the way the way Feign Dead exploit fix works, In a nutshell I added a few 'if(c->GetFeigned' checks.
in command.cpp
at around line 8558 , I really can't say where it is on the current source you all have but it starts with
Code:
 	if(!strcasecmp(sep->arg[1], "spawn") ){
Code:
And I changed to look as follows;
	if(!strcasecmp(sep->arg[1], "spawn") ){
        if( database.GetBotOwner(atoi(sep->arg[2])) == 0)
        {
            database.SetBotOwner(atoi(sep->arg[2]), c->CharacterID());
		}
	else if(database.GetBotOwner(atoi(sep->arg[2])) != c->CharacterID())
        {
            c->Message(15,"You can't spawn a bot that you don't own.");
			return;
		}
		if(c->IsEngaged())
        {
            c->Message(15, "You can't summon bots while you are engaged.");
			return;
		}
		if(c->GetFeigned()) //Angelox
        {
            c->Message(15, "You can't be feigned!");
			return;
		}
Also at around line 8624 , or where it starts with
Code:
if(!strcasecmp(sep->arg[1], "group") && !strcasecmp(sep->arg[2], "add"))
I made it to look like this;
Code:
	if(!strcasecmp(sep->arg[1], "group") && !strcasecmp(sep->arg[2], "add"))
    {
		if((c->GetTarget() == NULL) || (c->GetTarget() == c) || !c->GetTarget()->IsBot()) //Angelox
        {
            c->Message(15, "You must target a bot!");
			return;
		}
		if(c->IsEngaged()) //Angelox
        {
            c->Message(15, "Not while fighting!");
			return;
		}
		if(c->GetFeigned()) //Angelox
        {
            c->Message(15, "You can't be feigned!");
			return;
		}
		if(c->GetTarget()->IsClient())  //Angelox
        {
			c->Message(15, "You can't invite clients this way.");
			return;
		}
This will not kill Bots, but will not allow you to make (spawn) or add bots while FD.

-=-=-=-=-=-=-=-

Then over here in the trading Dept. I made some changes so your bot will take equipment while under any illusion (wolf form, etc).
traders.cpp, Line 350 or starts with
Code:
		//EQoffline: will give the items to the bots and change the bot stats
I changed the 'GetRace' to 'GetBaseRace'
Code:
		//EQoffline: will give the items to the bots and change the bot stats
		if(inst && with->IsBot() && with->BotOwner == this->CastToMob()) {
			if(inst->IsEquipable(with->GetBaseRace(), with->GetClass())) {  //Angelox fix for Equip Illusioned Bots
				BotCanWear = true;
Which worked but still had some spam threats to 'delete my bot'-
So, over in mob.cpp at around line 2462, or starts with ;
Code:
void Mob::CalcBotStats() {
	this->Say("I'm updating...");
I again changed 'GetRace' to 'GetBaseRace';
Code:
void Mob::CalcBotStats() {
	this->Say("I'm updating...");
	// base stats
	int brace = GetBaseRace(); //Angelox
	int bclass = GetClass();
	int blevel = GetLevel();
And that was the end of that story.

-=-=-=-=-=-=-=-=-=-=-=

Here's a riddle i've been trying to figure out all week;
I want the Bot names to appear as a clean name and not 'Mybot000' in my group window.

in groups.cpp at around line 214 or what starts with
Code:
		//build the template join packet
I change 'GetName' to 'GetCleanName';
like this;
Code:
		//build the template join packet
		EQApplicationPacket* outapp = new EQApplicationPacket(OP_GroupUpdate,sizeof(GroupJoin_Struct));
		GroupJoin_Struct* gj = (GroupJoin_Struct*) outapp->pBuffer;	
		strcpy(gj->membername, newmember->GetCleanName());
And it works, but the bot members in the window appear dulled out as if in another zone and I cant click-target them off that group window.
I guess I'm too stupid for this one, maybe some one can at least tell me where to look.

All those fixes are posted for download at my site if anyone wants to look at it or try it out - I still haven't made a converted version for PEQ, but am planning to.

Last edited by Angelox; 10-04-2008 at 03:01 AM..
 


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 07:33 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