Log in

View Full Version : Is my #makepet command broken or is it just me?


candlesaccount
12-21-2006, 10:55 AM
everytime i try to make a pet for my character i get the same response...
no data found for pet ##
i target a creature and do #npcstats on it to get the bodytype number but i havent gotten anything to work. I've tried making pets that appear in the zone i'm in and still nothing. I've tried targetting my character and using the command, still nada. What am I doing wrong? every number i put in gives me the same result.

John Adams
12-21-2006, 04:29 PM
You can only #makepet out of anything that is already defined as a pet. Meaning, you cannot just say "Hey, I want a level 70 Orc Pawn as a mate". Look first at the table: pets (I think that's the ID it's looking for). See how it's laid out, and what it's asking for. Then insert a record into npc_types for the end-result you are looking for, and use that npcid in your pets table.

I had to do this for Monster Summoning for level 70, since there were no level 70 pets that I am aware of. Once I did this, I could #makepet [id] and get what I wanted, or cast a new Monster Summoning V spell (or something along those lines) and get a random mob of that higher level.

Honestly, I cannot remember all the details, but I hope this sets you on the right path. Sorry. If you still have trouble, I'll see if I can write a howto for the Wiki (right now, my MySQL server is down, so I cannot check immediately).

candlesaccount
12-21-2006, 05:11 PM
ok that gives me somewhere to start. i just gotta find what pets there are, but i'm pretty sure i tried making a skeleton once and it wouldnt work either. once a pet IS made can i not just change it into some other bodytype? Like turning it into a human and having a henchmen?

John Adams
12-27-2006, 06:38 AM
Sorry for the delayed response. Just got back from my holiday. Let me try and demonstrate what I did to make a level 70 Monster Summoning pet (since I believe previously, they only went up to 60).

First, I created a new NPC with the stats I wanted (all test data, I didn't really tweak it properly):
INSERT INTO `npc_types` (`id`, `name`, `lastname`, `level`, `race`, `class`, `bodytype`, `hp`, `gender`, `texture`, `helmtexture`, `size`, `hp_regen_rate`, `mana_regen_rate`, `loottable_id`, `merchant_id`, `npc_spells_id`, `npc_faction_id`, `mindmg`, `maxdmg`, `npcspecialattks`, `aggroradius`, `face`, `luclin_hairstyle`, `luclin_haircolor`, `luclin_eyecolor`, `luclin_eyecolor2`, `luclin_beardcolor`, `luclin_beard`, `d_meele_texture1`, `d_meele_texture2`, `runspeed`, `MR`, `CR`, `DR`, `FR`, `PR`, `see_invis`, `qglobal`, `see_invis_undead`, `AC`, `npc_aggro`, `spawn_limit`, `attack_speed`, `findable`, `STR`, `STA`, `DEX`, `AGI`, `_INT`, `WIS`, `CHA`) VALUES (639, 'MonsterSum5', NULL, 70, 0, 1, 24, 4200, 2, 0, 0, 9, 90, 0, 0, 0, 163, 0, 200, 680, '', 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 2, 305, 305, 305, 305, 305, 0, 0, 1, 1200, 0, 0, 0, 0, 305, 305, 305, 305, 305, 305, 305);
Note: I forced 'id' 639 because in the stock database it appears pets are below 1000, and ended at 638.

Then I went to table: pets, and inserted this record at the end:
INSERT INTO `pets` (`type`, `npcID`, `temp`) VALUES ('MonsterSum5', 639, 0);
This gave me my path from Pets to NPC_types so when I used #makepet [type], the right NPC showed up.

Finally, in game I can now type #makepet MonsterSum5 and get Gebobtik to show up and give me my much needed support. Things to note, the body type of the NPC you are trying to spawn needs to be in the zone_chr.txt file, or in the global_chr.txt so the pet doesn't show up as a human model with bad hair. Also, you might need to mess with Gender once in a while. I am finding many inconsistencies with how things appear simply because they are not #gender 2 or something.

As for adding a pet-summoning spell or effect, that is not something I have tried yet. Messing with spells data scares me. Good luck, and I hope this helps a little.

candlesaccount
12-28-2006, 07:00 AM
what if i wanted the summoned pet to be the same level of the person making him? would i need to go into the #makepet command and set something up like...
level=player level

John Adams
12-28-2006, 08:51 AM
Not sure, really... because I do recall that at least at lower levels, sometimes you'd summon a pet that was white to you (same level), sometimes he'd be blue, other times yellow. So that implied some sort of randomness to it. My understanding of the Pets table vs npc_types table, you get what you get, that's it. I should investigate the actual code to see if there is any randomness added after fetching the base data.

But to answer you, I think you'd have to make 1 pet record for each level you wish to summon. I was hoping someone more knowledgable than me would step in by now. :D

Aerewen
12-28-2006, 10:16 AM
actually just check out the spell list on alla, pretty sure that has a list of the level of pet for each spell.

John Adams
12-28-2006, 03:32 PM
I think he's wanting a pet per level. Allah's should show what's currently in the table: npc_types, id's 1-999 (1000 starts Qeynos NPCs). All the pets for all the legit levels are in ther now, too. But if you want more, gotta make them yourself. :)

Shadow-Wolf
12-29-2006, 07:04 PM
Are you guys sure about this? last time I was running my emu server(a long while back) the #makepet command allowed you to make pets based on what information you gave the command.

John Adams
12-29-2006, 07:29 PM
Good question. I am not sure of anything, 100%. I just go by what I read on the forums or in game, or what I interpret the C++ code to say.

This is from command.cpp:
command_add("makepet","[level] [class] [race] [texture] - Make a pet",50,command_makepet)

Which makes your statement correct. But, when you type #makepet in game with no params, the Usage says:
c->Message(0, "Usage: #makepet pet_type_name (will not survive across zones)");
And I can say with confidence, lately, if I do not enter the exact name from npc_types table for the pet, linked to the Pets table, I get told cannot find a pet of that type. Not really sure what's up with that.

candlesaccount
12-29-2006, 08:58 PM
i haven't abandoned this post or idea just been busy at work (gotta love the holidays)

Cripp
12-31-2006, 06:13 AM
try #makepet MonsterSum5

maybe this works... would test myself but i havent really logged on my own server the past week..

John Adams
12-31-2006, 06:30 AM
Yes Cripp, that does work, if you have a matching Pet name in the Pets and NPC_Types tables. I think the problem is, the #makepet command shows 2 different syntaxes.

Typing just #makepet alone says to do it the way you suggest (and the way that works), #makepet [creature_type].
You say, '#makepet'
Usage: #makepet pet_type_name (will not survive across zones)

Typing #help makepet shows a much different syntax, and does not work any longer.
You say, '#help makepet'
Available EQEMu commands:
#makepet [level] [class] [race] [texture] - Make a pet
1 command listed.
You say, '#makepet 50 1 73 1'
Unable to find data for pet 50
Following this second syntax, I believe the 1st parameter is trying to be compared to something in the Pets/npc_types tables, and failing the lookup. The rest of this old syntax is ignored, apparently.


PS: I actually had to create MonsterSum5 myself to get a level 70 pet to show up. I think they stopped at MonsterSum4 in PEQ, which is a level 60 pet.

candlesaccount
01-01-2007, 09:22 PM
I was looking at your sql command line John and was wondering a few things... I noticed the merchant id is blank on your pet. if i wanted my pet to be a little more useful, say like a pet that's also a bank or a general supplies seller, setting this number would do that aye? will the pet use any weapons, items, or armor given to it? And most importantly, i'm a stranger to mysql and was wondering. if i enter a pet line similar to yours is it locked into my database? Will adding a similar but modified version of the first one added overwrite it or copy it? or would it need to be deleted first? And finally, in the variable 'level' is there not a variable that can be set that checks the target's level? So basically my gm would target a player and use #makepet "name" and the pet would then be the same level as the target.