Adding Partyfinder. Undecleared indentifier.(Fixed)

Status
Not open for further replies.
Joined
May 13, 2011
Messages
1,463
Reaction score
155
Hi ragezoners,

Today i started to put in the party finder system from Pummaa.

But it seems i missed out something and i can't find it.

I am working with 2 sources.
1 that have the partyfinder in it and is compiling fine.
and 1 thats my main source.

Uppon rebuilding the neuz it gives me the following errors

CWndParty Identifier not found
pWndParty Identifier not found.

I have checked every file and copied correctly.

this is the snipper in de DPClient.cpp

#ifdef __PMA_PARTYFINDER
void CDPClient::OnPartyChangeJoin( CAr & ar )
{
BOOL bPartyJoin;
ar >> bPartyJoin;

if( g_Party.GetLeader())
g_Party.GetLeader()->m_bPartyJoin = bPartyJoin;

CWndParty* pWndParty = (CWndParty*)g_WndMng.GetApplet( APP_PARTY );

if( pWndParty )
if( (CWndButton*)pWndParty->GetDlgItem( WIDC_RADIO7 ) )
((CWndButton*)pWndParty->GetDlgItem( WIDC_RADIO7 ))->SetCheck( bPartyJoin );


}
#endif

This is the DPClient.h
#ifdef __PMA_PARTYFINDER
void JoinParty( u_long nPartyId );
void OnRefreshPartyList( CAr & ar );
void SendPartyJoinAllow( int nMode );
void OnPartyChangeJoin( CAr & ar );
#endif

Am i missing something or?

Thanks in advance.


EDIT: Fixed it.
Forgot to include an file.
 
Last edited:
No it was not that one.
It was party.cpp that i needed to include.

You hadn't included your header file in the corresponding .cpp file; how does it work without it being defined?

Code:
#include "party.cpp"

Would virtually do nothing, as header files are suppose to be able to be used by several files; they're just a step up from forward declarations. Though, I'm confused now. If you put;

Code:
#include "party.cpp"

into your header code, it wouldn't do anything.
 
Sorry about that it was #include "WndParty.h"

So without that one in DPClient.cpp i had those errors.
And with it they where gone and its working.

Again sorry for the wrong file i named

No problem, I was just confused. I was like, why are you including another .cpp file into this .cpp file when you can just use headers and pre-created libraries..
 
Status
Not open for further replies.
Back