So I am trying to figure out how this system works in 5065 and I feel like I am missing something.
From what I understand, anytime you use a guild statue scroll, guild teleporter scroll or any kind of furniture voucher. The server sends packet 2031 to the client with the action (offset 12) to add (value 5). Followed by the sub action (offset 14) with the value depending on the item. 8 for GC, 9 for Statue, 25/26 for Furniture.
This brings up either the statue window or places an npc on the mouse for you to place at the location of your choice.
After rotating or whatever you desire, you click on OK and then the client sends the server packet 2030 to request the NPC.
This is all fine and good so far, but receiving this packet 2030 is where I am struggling.
The packet coming back, as far as I can tell, has no value to distinguish the type of NPC it is. I don't know if its a guild statue, guild teleporter or a piece of furniture.
This is where I appear to be missing something as I feel there should be some kind of type value to tell me what specific code I need to execute.
Statues require packet 1014 to be visible.
GCs and Furniture require NPC packets but are also handled somewhat differently.
My only thinking is that I can use the map ID to sort through what exactly is being used. Guild Map, House Maps and then everything else is placing a GC.
But if there is a 'correct' way of doing it, I would much prefer to go that route.
Anyone have any ideas or can point me in the right direction?
From what I understand, anytime you use a guild statue scroll, guild teleporter scroll or any kind of furniture voucher. The server sends packet 2031 to the client with the action (offset 12) to add (value 5). Followed by the sub action (offset 14) with the value depending on the item. 8 for GC, 9 for Statue, 25/26 for Furniture.
This brings up either the statue window or places an npc on the mouse for you to place at the location of your choice.
After rotating or whatever you desire, you click on OK and then the client sends the server packet 2030 to request the NPC.
This is all fine and good so far, but receiving this packet 2030 is where I am struggling.
The packet coming back, as far as I can tell, has no value to distinguish the type of NPC it is. I don't know if its a guild statue, guild teleporter or a piece of furniture.
This is where I appear to be missing something as I feel there should be some kind of type value to tell me what specific code I need to execute.
Statues require packet 1014 to be visible.
GCs and Furniture require NPC packets but are also handled somewhat differently.
My only thinking is that I can use the map ID to sort through what exactly is being used. Guild Map, House Maps and then everything else is placing a GC.
But if there is a 'correct' way of doing it, I would much prefer to go that route.
Anyone have any ideas or can point me in the right direction?