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 01-16-2012, 07:30 AM
dr00dguy
Fire Beetle
 
Join Date: Feb 2011
Posts: 8
Default quest function question

Is there a quest function to toggle an npc's bodytype?

I have an npc I want to be bodytype 11 (untargettable) until it receives a signal from another npc, then become targettable.

looked thought the quest intro and cheat sheet and did not see anything.

thanks
Reply With Quote
  #2  
Old 01-16-2012, 09:21 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,490
Default

Your best bet would be to create two NPCs and just spawn the targetable one and depop the original.
Reply With Quote
  #3  
Old 01-16-2012, 02:57 PM
dr00dguy
Fire Beetle
 
Join Date: Feb 2011
Posts: 8
Default

was trying to keep away from doing that. but I guess if its the only way I'll give it a go. Thanks
Reply With Quote
  #4  
Old 01-16-2012, 03:30 PM
Tabasco's Avatar
Tabasco
Discordant
 
Join Date: Sep 2009
Posts: 270
Default

I use $npc->SetBodyType();
It doesn't appear to be in the wiki, but it is in perl_mob.cpp.
Reply With Quote
  #5  
Old 01-16-2012, 04:55 PM
dr00dguy
Fire Beetle
 
Join Date: Feb 2011
Posts: 8
Default

That worked perfectly for what I needed. Thanks Tabasco
Reply With Quote
  #6  
Old 01-17-2012, 03:14 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

I added SetBodyType(type, overwrite_orig=false) to the wiki. I don't believe that is able to toggle whether an NPC is targetable in realtime. I think you would have to set the overwrite_orig field to true and repop the NPC to toggle that, but I haven't messed with that function yet really.

To toggle an NPC from targetable to untargetable, you can use SetTargetable(targetable=true), which is in the wiki already. I am not sure if we have the opcodes for all clients yet for that command. You might need to check it on Titanium to make sure it works before making too much use of it.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
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 10:12 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