trevius
05-22-2009, 05:45 AM
I think I have the respawn window structure figured out for SoF at least. I also think I figured out why people get disconnected if they die in the zone they are bound in on SoF clients. I will try to get the disconnect issue fixed tonight and on the SVN, but to get the code to support the respawn window might take longer if I can even figure it out myself. Here is the structure I have for it from Live anyway:
typedef struct {
/*000*/ uint32 bind_number; // Number of this bind in the iteration
/*004*/ uint32 bind_zone_id; // ID of the zone for this bind point or resurect point
/*008*/ float x; // X loc for this bind point
/*012*/ float y; // Y loc for this bind point
/*016*/ float z; // Z loc for this bind point
/*020*/ float heading; // Heading for this bind point
/*024*/ char bind_zone_name[14]; // Or "Bind Location" or "Resurrect"
/*000*/ uint8 validity; // 0 = valid choice, 1 = not a valid choice at this time (resurrection)
} RespawnOptions_Struct;
struct RespawnWindow_Struct {
/*000*/ uint32 unknown000; // Seen 0
/*004*/ uint32 time_remaining; // Total time before respawn in milliseconds
/*008*/ uint32 unknown008; // Seen 0
/*012*/ uint32 total_binds; // Total Bind Point Options? - Seen 2
/*016*/ RespawnOptions_Struct bind_points;
// First bind point is "Bind Location" and the last one is "Ressurect"
};
EDIT:
Nope, I guess I was wrong about why they get disconnected. I thought maybe it was because the zoneplayertobind structure was not being encoded and had changed (it did change on live). But, it looks like we send the death packet and wait for the client to send the zone request. In Titanium, I think it will send that automatically, so we know to zone them. But, in SoF, it looks like the client is waiting for the OP_RespawnWindow packet and we aren't sending that yet. Hopefully, I can figure out what is needed to get that working soon.
typedef struct {
/*000*/ uint32 bind_number; // Number of this bind in the iteration
/*004*/ uint32 bind_zone_id; // ID of the zone for this bind point or resurect point
/*008*/ float x; // X loc for this bind point
/*012*/ float y; // Y loc for this bind point
/*016*/ float z; // Z loc for this bind point
/*020*/ float heading; // Heading for this bind point
/*024*/ char bind_zone_name[14]; // Or "Bind Location" or "Resurrect"
/*000*/ uint8 validity; // 0 = valid choice, 1 = not a valid choice at this time (resurrection)
} RespawnOptions_Struct;
struct RespawnWindow_Struct {
/*000*/ uint32 unknown000; // Seen 0
/*004*/ uint32 time_remaining; // Total time before respawn in milliseconds
/*008*/ uint32 unknown008; // Seen 0
/*012*/ uint32 total_binds; // Total Bind Point Options? - Seen 2
/*016*/ RespawnOptions_Struct bind_points;
// First bind point is "Bind Location" and the last one is "Ressurect"
};
EDIT:
Nope, I guess I was wrong about why they get disconnected. I thought maybe it was because the zoneplayertobind structure was not being encoded and had changed (it did change on live). But, it looks like we send the death packet and wait for the client to send the zone request. In Titanium, I think it will send that automatically, so we know to zone them. But, in SoF, it looks like the client is waiting for the OP_RespawnWindow packet and we aren't sending that yet. Hopefully, I can figure out what is needed to get that working soon.