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

Development::Bots Forum for bots.

Reply
 
Thread Tools Display Modes
  #1  
Old 05-24-2009, 11:13 AM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default Question for Congdar on mage pets.

On my server all of the players pretty well only want the Mage Bots to cast two possible pets (water and air). I played with the code last night and found this.
Code:
	case SpellType_Pet: {
  if (!IsPet() && !GetPetID() && !IsBotCharmer()) {
    if(botClass == MAGICIAN) {
   			     int randpets;
   			     randpets = 2;
	                     }
			     i = MakeRandomInt(i-randpets, i);
			     }
			     AIDoSpellCast(i, tar, mana_cost);
                             return true;
			     }
			     break;
		    }
		}
Sorry I think the spacing from Visual Studio throws it off. This is not the original I modified it some and took out the comments before posting it.

Okay so I can reduce the number of pets case by changing the randpets number but I think it cast the first two, like fire and water pets. Where are these kept, my C++ is very basic. I may be able to do it in the database but not sure where to look.
Reply With Quote
  #2  
Old 05-24-2009, 11:41 AM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

This is the original case statement before I butchered it. Copying from VS and pasting here does not work that well.

Code:
case SpellType_Pet: {
						 //keep mobs from recasting pets when they have them.
						if (!IsPet() && !GetPetID() && !IsBotCharmer()) {
							if(botClass == MAGICIAN) {
								// have the magician bot randomly summon
								// the air, earth, fire or water pet
                                // include monster summoning after they
                                // become level 30 magicians
								int randpets;
								if(botLevel >= 30) {
									randpets = 4;
								}
								else {
									randpets = 3;
								}
								i = MakeRandomInt(i-randpets, i);
							}
							AIDoSpellCast(i, tar, mana_cost);
							return true;
						}
						break;
Reply With Quote
  #3  
Old 05-24-2009, 03:24 PM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

It's currently set to randomly spawn one of the 4 pets before they get monster summoning and then random one of the 5 pets. The code says 3 and 4 cuz it's 0-3 and 0-4. This matches up with the Bot Spell Lists for Mages. Level 2-4 have a little difficulty, but they figure it out pretty quick.

It you want to customize your server for a specific pet, theres a few ways you could go.

No c++ changes.
You could change the pet entries in the sql file so there are four or five water or air pets or a mix of the two types to random from. This would require you to edit the sql file to match those selections.

C++ changes.
You could change the random number to 1 (0-1) and then delete from the sql all the non air and water, and monster summoning pets.

No changes by you.
This sounds like a feature request. I'm thinking if you don't like the pet they summoned randomly, you target your mage bot and type the command #bot magepet [earth|water|air|fire|monster]
__________________
The Realm
Reply With Quote
  #4  
Old 05-24-2009, 04:25 PM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

What I did temporarily was remove the npc_spell entries for the bot earth, MS, fire pets. Then I changed the C++ code to 1 instead of 4.
Reply With Quote
  #5  
Old 05-25-2009, 12:07 AM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

svn r573 - Added new command #bot magepet [earth|water|air|fire|monster] - Select the pet type you want your Mage bot to use.
__________________
The Realm
Reply With Quote
  #6  
Old 05-25-2009, 08:37 AM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

yay !!!

That is awesome.
Reply With Quote
  #7  
Old 05-25-2009, 02:57 PM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

don't forget to put the spells back in. You can just source in the sql from this zip Bot Spell Lists
__________________
The Realm
Reply With Quote
  #8  
Old 05-25-2009, 03:23 PM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

I will, I probably will wait till a few more releases.
Reply With Quote
  #9  
Old 05-25-2009, 03:32 PM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

Also I thought I read a thread a while back about a possibility of using a client newer than Titanium. Any chances of that happening this year ?
Reply With Quote
  #10  
Old 05-26-2009, 10:34 AM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

I think the Secrets of Faydwer client is 98% working.
__________________
The Realm
Reply With Quote
  #11  
Old 05-26-2009, 10:39 AM
Snoopdog
Sarnak
 
Join Date: Sep 2004
Posts: 31
Default

I picked it up from Newegg. I think since they ship free it normally arrives snail-mail. I should have it in a few weeks. I cannot wait though. The Titanium client seems to crash readily on higher resolutions, I pray that the new client is more stable.
Reply With Quote
  #12  
Old 05-26-2009, 10:43 AM
So_1337
Dragon
 
Join Date: May 2006
Location: Cincinnati, OH
Posts: 689
Default

The SoF client has better support for multi-core processors as well.
Reply With Quote
  #13  
Old 05-28-2009, 03:15 PM
Snoopdog
Sarnak
 
Join Date: Sep 2004
Posts: 31
Default

Okay, I just compiled from source today to try the new bot commands.

Here is what it does for me. I am trying these at level 65, since I just dinged.

Monster pet - gives me monster pet.
Air pet - gives me water.
Fire pet - gives me water.
Earth pet - constantly cast fire and ice protection or other random spell until mage runs out of mana, then keeps casting as he gets mana.
Fire pet - did not try.
Reply With Quote
  #14  
Old 05-28-2009, 03:18 PM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

re-source in the bot spells from the link a couple of posts up... I didn't specifically try level 65, but they should be the same 30+
__________________
The Realm
Reply With Quote
  #15  
Old 05-28-2009, 03:35 PM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

Okay I did and restarted the server, trying the Earth Pet he keeps casting fire and ice protection repeatedly.

Ideas ?

I also tried fire and he keeps casting a spell over and over, not sure what it is though.
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 11: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 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3