Loading...   


void Client::Handle_OP_DzAddPlayer(const EQApplicationPacket *app) {
	// packet size: 72
	this->Message(15, "Client::Handle_OP_DzAddPlayer() - Client version: %i, packet size: %i", this->ClientVersion, app->size);
	
	if (app->size != sizeof(ExpeditionAddPlayer_Struct)) {
		this->Message(15, "Invalid size for OP_DZAddPlayer: Expected: %i, Got: %i", sizeof(ExpeditionAddPlayer_Struct), app->size);
		LogFile->write(EQEMuLog::Error, "Invalid size for OP_DZAddPlayer: Expected: %i, Got: %i",
			sizeof(ExpeditionAddPlayer_Struct), app->size);
		return;
	}

	ExpeditionAddPlayer_Struct* dzadd = (ExpeditionAddPlayer_Struct*)app->pBuffer;
	this->Message(15, "dzadd->unkown000 = %i", dzadd->unknown000);
	this->Message(15, "dzadd->unknown004 = %i", dzadd->unknown004);
	this->Message(15, "dzadd->player_name = %s", dzadd->player_name);

	Mob *Invitee = entity_list.GetMob(dzadd->player_name);
	if (Invitee == this) {
		//need to check file for string on dzadd self
		Message_StringID(clientMessageError, GROUP_INVITEE_SELF);
		return;
	}
	if (Invitee) {
		if (Invitee->IsClient()) {
			ExpeditionAddPlayer(Invitee->CastToClient());
		}
		else {
			return;
		}

	}
}

Raw Paste Data