Quote:
Originally Posted by trevius
Oh sweet lol. I was just making something very basic and wasn't very far along just yet. I figured it could always be expanded on later, but wanted to get something working to start off with. Yours is much more in-depth than what I was doing, so I'll just leave it up to you
The only thing I would add to what you have so far would be a way to despawn them. We should be able to use the ClickObject packet to handle that part. That isn't really too important though, and can always be added in later. Unless your delete option already does that. I like the move option you have. It sounds like a good idea and not hard to do.
|
Per my testing, Delete does do a realtime despawn of the object, as Add does a realtime spawn. This allows object changes to be reflected in realtime by sending a despawn packet and respawn packet after each change. Using "#object delete" instead of attempting to trap ClickObject packets for placeables will prevent having the server do unnecessary processing with every click from every user on every object in the game.
The only caveat is that Doors do not have a Despawn opcode that I could find. They appear to be super-static by design. Unless we just haven't found the Opcode yet (since it's not likely to be found with packet collection from Live servers), I assume at this point that the client expects them to be sent once upon zone-in and never change. This also means that there will not be a Despawn packet for static objects.
The best way I can figure as to how to handle this issue is to spawn static objects and doors as tradeskill objects at first, allowing the user to make any model, location, and rotation changes they want to it, then change them into full-on static door objects when the "#object save" command is used to commit them to the database.
I could also look into utilizing an #object command to temporarily change an already-committed door or static object into a changeable tradeskill object upon the next zone-in, allowing the user to make any changes in-game and then re-commit with "#object save".
Should be entirely doable.