View Single Post
  #15  
Old 01-23-2019, 11:08 AM
pharone1
Sarnak
 
Join Date: May 2005
Posts: 56
Default

I implemented this last night, so it still works in 2019 for anyone concerned.

I initially had trouble getting it to work, but that was just because I am still new to how EQemu works over all. Thanks for the help in Discord Akkadius.

Here are my tips for anyone else wanting to implement this and is very new to EQemu like myself:
  • Create 7 NPCs in your database (1 for effects and 6 for weapons) in the npc_types table
  • I named my weapon NPCs 'weapon'
  • I named my effects NPC 'effect'
  • $effect_npc
  • Change the values for $effect_npc and $mob_# (ex $mob_1) to the npctypeid for the effects and weapon npcs you created
  • Change the instanceversion value to 0 in the script UNLESS you have an instanceversion 1 to zone in to for Overthere

I know all of these things seem super insanely simple to figure out if you have been using EQemu for a while now, but for someone like myself that had never even opened a .pl file before, I was pretty lost lol.

My biggest problem was that I had no idea what an instance version even was little lone how to create and/or access one. In the end, I ended up modifying the script (as stated above) to simply use instanceversion 0 instead, and everything started working.

In the end, I learned a lot about how to modify these pl files, so it was a great exercise.

Also, I was wondering how I could find out if parts of my script were even firing off, and it occurred to me that I can use the $client->Message function to send messages to the player to let me know when certain parts of the script ran. To do this, just add the following to any spot in the script where you would want a message to pop up on the players chat window (for example: to see if the event_spawn was running).

$client->Message(15, "*** Debug *** Entered XYZ part of the code.");

When the script comes across that line, it will say "*** Debug *** Entered XYZ part of the code." in the chat window for the player, so you know your script is running and it got to that part of the script. Makes debugging a bit easier.

This works great, and I have already used it to identify some weapon skins I want to use.

Oh one last thing about the weapon skins. When you click on one of the NPCs holding the weapons, the npc tells you the IDs of the weapons that NPC is wielding. This is the idfileid (I think that's what the field is called in the items table). You need to add the letter IT to the front of that number when you go to add the weapon skin to another weapon. For example, if the id was 12345, the actual skin id is IT12345.

I hope this helps anyone looking to try this out in the future.
Reply With Quote