⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gcaddousters.cpp

📁 dk1游戏的原代码文件,完整.编译系统redhat7.3,mysql 3.23 ,luascript v4.0 support
💻 CPP
字号:
//////////////////////////////////////////////////////////////////////////////// Filename    : GCAddOusters.cpp// Written By  : Reiot// Description : //////////////////////////////////////////////////////////////////////////////#include "GCAddOusters.h"//////////////////////////////////////////////////////////////////////////////// class GCAddOusters member methods//////////////////////////////////////////////////////////////////////////////GCAddOusters::GCAddOusters(){	m_pEffectInfo = NULL;	m_pPetInfo = NULL;}GCAddOusters::GCAddOusters(const PCOustersInfo3& info)	: m_OustersInfo(info){	m_pEffectInfo = NULL;	m_pPetInfo = NULL;}GCAddOusters::~GCAddOusters()	throw(){	__BEGIN_TRY		SAFE_DELETE(m_pEffectInfo);	__END_CATCH}void GCAddOusters::read ( SocketInputStream & iStream ) 	 throw ( ProtocolException , Error ){	__BEGIN_TRY			m_OustersInfo.read( iStream );	m_pEffectInfo = new EffectInfo();	m_pEffectInfo->read( iStream );	m_pPetInfo = new PetInfo();	m_pPetInfo->read( iStream );	if ( m_pPetInfo->getPetType() == PET_NONE ) SAFE_DELETE( m_pPetInfo );	__END_CATCH}		    void GCAddOusters::write ( SocketOutputStream & oStream ) const      throw ( ProtocolException , Error ){	__BEGIN_TRY	PetInfo NullPetInfo;			m_OustersInfo.write( oStream );	m_pEffectInfo->write( oStream );	if ( m_pPetInfo == NULL )		NullPetInfo.write( oStream );	else	{		m_pPetInfo->setSummonInfo(0);		m_pPetInfo->write( oStream );	}	__END_CATCH}void GCAddOusters::execute ( Player * pPlayer ) 	 throw ( ProtocolException , Error ){	__BEGIN_TRY			GCAddOustersHandler::execute( this , pPlayer );			__END_CATCH}PacketSize_t GCAddOusters::getPacketSize() const 	throw(){   	__BEGIN_TRY	return m_OustersInfo.getSize() + m_pEffectInfo->getSize() + ((m_pPetInfo!=NULL)?m_pPetInfo->getSize():szPetType);	__END_CATCH}string GCAddOusters::toString () const       throw (){	__BEGIN_TRY	StringStream msg;	msg << "GCAddOusters("		<< "OustersInfo:" << m_OustersInfo.toString()		<< "EffectInfo:" << m_pEffectInfo->toString()		<< ")";	return msg.toString();	__END_CATCH}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -