Raknet Problem [solved]
I'm having a problem whenever I put an RPC function in a class, whenever I compile I get the following errors, Anyone know what's the problem, I would like to post in the rakkarsoft forums, but they are down unfortunately. e:\FYP Assignment\NetworkInterface.cpp(52): error C2664: 'RakClientInterface::RegisterAsRemoteProcedureCall' : cannot convert parameter 2 from 'void (char *,int,PlayerID)' to 'void (__cdecl *)(char *,int,PlayerID)' [Edited by - Kavana on February 9, 2005 10:21:12 AM]
I'm rather new to raknet so I'm not really sure whether I'm doing right, doing this for a school project.
Anyway I have a class called NetworkInterface, there is one RPC function called registerPlayer. I have another function to register the RPC as well as do other stuff, I followed the same parameters, but I can't seem to get it running, is there any other way to make it function in a class, because I want to hook it up to my game component without mixing them all up. thanks.
registerPlayer
and the clientRun function
Anyway I have a class called NetworkInterface, there is one RPC function called registerPlayer. I have another function to register the RPC as well as do other stuff, I followed the same parameters, but I can't seem to get it running, is there any other way to make it function in a class, because I want to hook it up to my game component without mixing them all up. thanks.
registerPlayer
void NetworkInterface::registerPlayer(char *input, int numberOfBitsOfData, PlayerID sender)
and the clientRun function
//! Function for client to run (simplified to make easy connectivity)void NetworkInterface::clientRun(){ // Initialise the client rakClient=RakNetworkFactory::GetRakClientInterface(); Multiplayer<RakClientInterface> rakClientMultiplayer; // Register RPC function REGISTER_AS_REMOTE_PROCEDURE_CALL(rakClient, registerPlayer); .................................. ............................
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement