Rogue iterate
This commit is contained in:
@@ -1357,10 +1357,9 @@ void rogue_packitemstr(char *packitemstr,struct rogue_packitem *item)
|
||||
static int32_t didinit;
|
||||
if ( didinit == 0 )
|
||||
{
|
||||
init_names(); /* Set up names of scrolls */
|
||||
init_colors(); /* Set up colors of potions */
|
||||
init_stones(); /* Set up stone settings of rings */
|
||||
init_materials(); /* Set up materials of wands */
|
||||
struct rogue_state R;
|
||||
memset(&R,0,sizeof(R));
|
||||
rogueiterate(&R);
|
||||
didinit = 1;
|
||||
}
|
||||
THING *obj = new_item();
|
||||
|
||||
@@ -420,10 +420,10 @@ int32_t rogue_playerdata(struct CCcontract_info *cp,uint256 &origplayergame,CPub
|
||||
if ( vopret.size() > 34 && script[0] == EVAL_ROGUE && (script[1] == 'H' || script[1] == 'Q' || script[1] == 'S') )
|
||||
{
|
||||
memcpy(&gametxid,script+2,sizeof(gametxid));
|
||||
fprintf(stderr,"got vin.%s gametxid.%s\n",playertx.vin[1].prevout.hash.ToString().c_str(),gametxid.ToString().c_str());
|
||||
fprintf(stderr,"got vin.%s gametxid.%s iterate.%d valid.%d\n",playertx.vin[1].prevout.hash.ToString().c_str(),gametxid.ToString().c_str(),rogue_iterateplayer(gametxid,playertx.vin[1].prevout.n,playertxid),rogue_isvalidgame(cp,gametx,buyin,maxplayers,gametxid));
|
||||
// verify highlander is a valid gametxid, verify playertxid is linked to it
|
||||
//if ( rogue_iterateplayer(highlander,playertx.vin[1].prevout.n,playertxid) == 0 )
|
||||
//if ( playertx.vin[1].prevout.hash == highlander )
|
||||
if ( playertx.vin[1].prevout.hash == gametxid )
|
||||
{
|
||||
//if ( GetTransaction(highlander,highlandertx,hashBlock,false) != 0 && (numvouts= highlandertx.vout.size()) > 0 )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user