komodo_netevent
This commit is contained in:
@@ -48,6 +48,10 @@ std::string MYCCLIBNAME = (char *)"rogue";
|
||||
std::string MYCCLIBNAME = (char *)"sudoku";
|
||||
#endif
|
||||
|
||||
#ifndef BUILD_GAMESCC
|
||||
void komodo_netevent(std::vector<uint8_t> payload) {}
|
||||
#endif
|
||||
|
||||
char *CClib_name() { return((char *)MYCCLIBNAME.c_str()); }
|
||||
|
||||
struct CClib_rpcinfo
|
||||
|
||||
@@ -178,6 +178,14 @@ UniValue games_register(uint64_t txfee,struct CCcontract_info *cp,cJSON *params)
|
||||
return(result);
|
||||
}
|
||||
|
||||
void komodo_netevent(std::vector<uint8_t> payload)
|
||||
{
|
||||
int32_t i;
|
||||
for (i=0; i<payload.size(); i++)
|
||||
fprintf(stderr,"%02x",payload[i]);
|
||||
fprintf(stderr," got event[%d]\n",(int32_t)payload.size());
|
||||
}
|
||||
|
||||
bool games_validate(struct CCcontract_info *cp,int32_t height,Eval *eval,const CTransaction tx)
|
||||
{
|
||||
return(true);
|
||||
|
||||
@@ -81,5 +81,6 @@ extern int32_t USE_EXTERNAL_PUBKEY;
|
||||
int tx_height( const uint256 &hash );
|
||||
extern char NOTARYADDRS[64][36];
|
||||
extern uint8_t NUM_NOTARIES;
|
||||
void komodo_netevent(std::vector<uint8_t> payload);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -7045,9 +7045,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
|
||||
}
|
||||
std::vector<uint8_t> payload;
|
||||
vRecv >> payload;
|
||||
for (i=0; i<payload.size(); i++)
|
||||
fprintf(stderr,"%02x",payload[i]);
|
||||
fprintf(stderr," got event[%d]\n",(int32_t)payload.size());
|
||||
komodo_netevent(payload);
|
||||
return(true);
|
||||
}
|
||||
else if (strCommand == "verack")
|
||||
|
||||
Reference in New Issue
Block a user