Jump to content

Erro ao compilar source


CAMBOJA
 Share

Recommended Posts

Boas !

Pessoal me ajudem com esse problema quando implemento o sistema de cheque  na source game dar esse tipo de erro que estar no print !

Alguém poderia me ajudar nesse tópico?

Desde de já fico agradecido! 

tentei primeiro colocar assim igual ao do Tutorial Won System

#ifdef ENABLE_CHEQUE_SYSTEM
            info.dwPriceCheque = it->second;
#endif

Depois mudei as funções  para esse:

#ifdef ENABLE_CHEQUE_SYSTEM
            header.aPriceInfo[idx].dwCheque = it->second;
#endif

de todos os jeitos que coloquei deu erro ao copilar...

Tutorial.png

char.png

char2.png

Link to comment
Share on other sites

error: 'struct TItemPriceInfo' has no member named 'dwCheque'
error: 'const struct SItemPriceInfo' has no member named 'dwCheque'

 

common/tables.h

Procura por:

typedef struct SItemPriceInfo
{
	DWORD	dwVnum;		///< ¾ÆÀÌÅÛ vnum
	DWORD	dwPrice;	///< °¡°Ý
} TItemPriceInfo;

 

Substitui por:

typedef struct SItemPriceInfo
{
	DWORD	dwVnum;		///< ¾ÆÀÌÅÛ vnum
	DWORD	dwPrice;	///< °¡°Ý
	DWORD	dwCheque;	/// ENABLE_CHEQUE_SYSTEM
} TItemPriceInfo;

 


3688: error: duplicate case value
3570: error: previously used here

 

char.cpp

Na linha 3688, existe um case que já foi definido acima na linha 3570:

// exemplo:
	case TLTHINGS: // linha 3570
		ação;
		break;

	case TLTHINGS: // linha 3688
		ação;
		break;

Remove o último case e estará resolvido.

 

 

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...