View Full Version : [SOLVED] Finding the Correct Packet Event

08-13-2015, 09:09 PM
Hello I am trying to find a work around for equiping and unequiping items as far as the event. I know there is RegisterPlayerEvent() for on equip and not one for unequip at this time. So I know there is obviously a packet being sent to the server to signify that change. What I can't seem to find is how to go about finding that packet or what one it would be. I have looked over the opcodes and still no dice.

What I am trying to overall accomplish is a player equips an item. This triggers a script that gives them a buff. If the player unequips that item the script would remove the buff.

I also should mention that it's more then likely that I am using the RegisterPacketEvent( entry, event, function ) wrong. Here is an example of that I have tried to do as for testing.

function test()


RegisterPacketEvent( 914, 7, test )[/COLOR]

-- what I believe to be the entry packet is CMSG_TIME_SYNC_RESP

Anyway if anyone could please shed some light on how to use this and how to get the correct packet I would greatly appreciate it.

P.S. I am using Mangos 3.3.5a latest Development 21

08-14-2015, 04:58 PM
Have you tried using the RegisterItemEvent?

Also this might help

08-14-2015, 05:10 PM
Why do you need a script for the buff thing?
Instead of some workaround I would use the database functionality that allows you to add a spell on equip.

08-14-2015, 07:30 PM
I have checked out both of those event that you posted and the IsEquiped works just fine. However there is not an event that supports Unequip at this time from my understanding. As far as why I need a script isn't necessarily going to be a buff, it could be anything. My problem is I only want something active if that item is currently equiped. My problem is keeping a constant check on that possibility. For example I can check almost everything but it being unquiped.