Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 09-08-2009, 09:14 AM
Sinister
Fire Beetle
 
Join Date: Jul 2004
Posts: 11
Default Spawning a corpse

Hey all,

I hope I have a easy question. Basically what I want to do is spawn a corpse that when hailed depops and gives you a quest item. I know how to do the quest item/depop, but not sure how to spawn a "corpse".

Not sure if this has to be scripted or if there is a DB way to do it. Thanks in advance for your help, and if this is in the wrong forum I apologize.
Reply With Quote
  #2  
Old 09-08-2009, 11:07 AM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

i don't think you can spawn an actual corpse...
but what you could do is spawn npc with a name like "soandso' corpse" and give him laying down animation
Reply With Quote
  #3  
Old 09-08-2009, 11:09 AM
So_1337
Dragon
 
Join Date: May 2006
Location: Cincinnati, OH
Posts: 689
Default

Create the NPC in the database with all the details you want including the race, sex, and size. Be sure to give it the 'ABH' special attack flags, so that it's immune to melee, magic, and won't ever aggro. Make the name in the database as "Soandso's corpse".

Next, write up your quest script for the depop and whatever other conversation you want to happen. Add the following code.

Code:
sub EVENT_SPAWN {
 quest::settimer(1,1);
}

sub EVENT_TIMER {
 if($timer eq "1") {
  $npc->SetAppearance(1);
  quest::stoptimer(1);
 }
}
If you already have code in the EVENT_SPAWN and EVENT_TIMER blocks, make sure to merge the code in rather than maintaining two separate blocks of the same type. This is the same sort of code that currently puts the Sleeper to sleep (laying down), it should give you a corpse well enough.
Reply With Quote
  #4  
Old 09-08-2009, 07:39 PM
Sinister
Fire Beetle
 
Join Date: Jul 2004
Posts: 11
Default

Thanks so much for the help guys, I will give this a try.

Edit: Oh, is there somewhere I can see what each number for the SetAppearance function does or do I just need to play with it?
Reply With Quote
  #5  
Old 09-08-2009, 08:48 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

I don't know if there is a good list of them anywhere, but you can always use this little script I wrote to check each one manually:

Code:
sub EVENT_SAY {

	if ($status > 20)
	{
		if($text =~ /Hail/i)
		{
			quest::say("Just say a number for me to set appearance to.");
		}
		
		if($text >= 0 && $text <=255555555)
		{
			$npc->SetAppearance($text);
			quest::say("Setting appearance to number $text.");
		}
		
	}
  
}
Then, you just say numbers to the NPC and it will set it's appearance to the number you said.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #6  
Old 09-08-2009, 09:19 PM
Sinister
Fire Beetle
 
Join Date: Jul 2004
Posts: 11
Default

Thanks Trev, you are my hero.
Reply With Quote
  #7  
Old 09-08-2009, 09:38 PM
So_1337
Dragon
 
Join Date: May 2006
Location: Cincinnati, OH
Posts: 689
Default

Be sure you have emotes enabled in your EQ configuration or you won't see most of them once you get into the 30s.
Reply With Quote
  #8  
Old 09-08-2009, 09:44 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

Quote:
Originally Posted by So_1337 View Post
Be sure you have emotes enabled in your EQ configuration or you won't see most of them once you get into the 30s.
I think that is for animations (#doanim <number>), not for appearances. As far as I know, appearances don't go high at all and they are mostly just for standing, sitting, laying down, squating and maybe a couple others. But, animations go much higher and I have even seen unique ones about 100+. Though, you don't want to go any animations over 182, because at least for me, that caused my client to crash every time for some reason :P
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #9  
Old 09-08-2009, 09:49 PM
Sinister
Fire Beetle
 
Join Date: Jul 2004
Posts: 11
Default

To test animations do we just need to use SetAnimation instead of SetAppearance?
Reply With Quote
  #10  
Old 09-08-2009, 10:09 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

You can use the command #doanim <number> to test out animations. Or, you can use that quest script and use:

DoAnim(<animnum>)

I had already made a list of animations for some work I was doing in a zone, so I just went and made a new page in the wiki for it here:

http://www.eqemulator.net/wiki/wikka...AnimationsList

That might be useful to you, but I made that list using a Drakkin, so I am not sure how other races might show up with the same animations.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #11  
Old 09-09-2009, 09:00 AM
So_1337
Dragon
 
Join Date: May 2006
Location: Cincinnati, OH
Posts: 689
Default

Bah, you're absolutely right. I was thinking of the animations, not the appearances. I was trying to correct a quest script last week and realized after about an hour that I didn't have emotes on, so there was no hope of getting the NPC to make the right animation.

Great to see that list compiled in the wiki, you're so on the ball at not only figuring things out, but at documenting them well. Great work as always =)
Reply With Quote
Reply

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 08:42 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