Thanks for all the help Tony, it is now working fine and i will try to put in the graple hook once i have made some changes Vbitz
Tony Sergi wrote: > No it was my fault. In basegrenade_shared.h I was making changes purely for > the SDK because I didn't want the scratch SDK to have grenades as > basecombatcharacter. But HL2MP needs it for the tripmines, and singleplayer > needs it for the barnacles. > > If you change the declaration in game\shared\basegrenade_shared.h to this > (it's kind of messy because of the #ifdefs) it'll work. > > //Tony; Compromise! in episodic single player, inherit CBaseCombatCharacter > for the barnacle interaction, otherwise this will never get called. > class CBaseGrenade : > #if defined( HL2_EPISODIC ) || defined ( HL2MP ) //Tony; HL2MP > needs this too for tripmine grenades. > public CBaseCombatCharacter > #else > public CBaseAnimating > #endif > #if defined( GAME_DLL ) > , public CDefaultPlayerPickupVPhysics > #endif > { > DECLARE_CLASS( CBaseGrenade, CBaseAnimating ); > public: > > > > -Tony > > -----Original Message----- > From: hlcoders-boun...@list.valvesoftware.com > [mailto:hlcoders-boun...@list.valvesoftware.com] On Behalf Of Jorge Rodriguez > Sent: August-25-09 12:34 AM > To: Discussion of Half-Life Programming > Subject: Re: [hlcoders] Erour in OB Mod > > You have a function definition, looking similar to: > > void CBaseGrenade::HandleInteraction() > { > // ... blah blah > } > > You must have copied a function from CBaseGrenade and tried to add it to > grenade_frag.cpp because the compiler is complaining. The function is > declared as a member of CBaseGrenade when it needs to be CHL2GrenadeFrag or > whatever. > > This is a pretty simply C++ syntax problem. If you're getting in over your > head with the (complicated) C++ syntax, I recommend starting with something > simpler than what you're doing, and reading more about how C++ works. > > _______________________________________________ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders