-prints
This commit is contained in:
@@ -20,7 +20,6 @@
|
|||||||
void
|
void
|
||||||
command(struct rogue_state *rs)
|
command(struct rogue_state *rs)
|
||||||
{
|
{
|
||||||
static FILE *fp2;
|
|
||||||
register char ch;
|
register char ch;
|
||||||
register int ntimes = 1; /* Number of player moves */
|
register int ntimes = 1; /* Number of player moves */
|
||||||
char *fp;
|
char *fp;
|
||||||
@@ -466,25 +465,8 @@ over:
|
|||||||
if (!after)
|
if (!after)
|
||||||
ntimes++;
|
ntimes++;
|
||||||
}
|
}
|
||||||
if ( fp2 == 0 )
|
|
||||||
rs->logfp = fp2 = fopen("commands","wb");
|
|
||||||
if ( fp2 != 0 )
|
|
||||||
{
|
|
||||||
fprintf(fp2,"after if (%c).%d seed.%llu\n",ch,ch,(long long)seed);
|
|
||||||
fflush(fp2);
|
|
||||||
}
|
|
||||||
do_daemons(rs,AFTER);
|
do_daemons(rs,AFTER);
|
||||||
if ( fp2 != 0 )
|
do_fuses(rs,AFTER,0);
|
||||||
{
|
|
||||||
fprintf(fp2,"after daemons (%c).%d seed.%llu isring.%d teleport.%d || search.%d teleport.%d\n",ch,ch,(long long)seed,ISRING(LEFT, R_SEARCH),ISRING(LEFT, R_TELEPORT),ISRING(RIGHT, R_SEARCH),ISRING(RIGHT, R_TELEPORT));
|
|
||||||
fflush(fp2);
|
|
||||||
}
|
|
||||||
do_fuses(rs,AFTER,fp2);
|
|
||||||
if ( fp2 != 0 )
|
|
||||||
{
|
|
||||||
fprintf(fp2,"after fuses (%c).%d seed.%llu isring.%d teleport.%d || search.%d teleport.%d\n",ch,ch,(long long)seed,ISRING(LEFT, R_SEARCH),ISRING(LEFT, R_TELEPORT),ISRING(RIGHT, R_SEARCH),ISRING(RIGHT, R_TELEPORT));
|
|
||||||
fflush(fp2);
|
|
||||||
}
|
|
||||||
if (ISRING(LEFT, R_SEARCH))
|
if (ISRING(LEFT, R_SEARCH))
|
||||||
search(rs);
|
search(rs);
|
||||||
else if (ISRING(LEFT, R_TELEPORT) && rnd(50) == 0)
|
else if (ISRING(LEFT, R_TELEPORT) && rnd(50) == 0)
|
||||||
@@ -493,11 +475,6 @@ over:
|
|||||||
search(rs);
|
search(rs);
|
||||||
else if (ISRING(RIGHT, R_TELEPORT) && rnd(50) == 0)
|
else if (ISRING(RIGHT, R_TELEPORT) && rnd(50) == 0)
|
||||||
teleport(rs);
|
teleport(rs);
|
||||||
if ( fp2 != 0 )
|
|
||||||
{
|
|
||||||
fprintf(fp2,"after command (%c).%d seed.%llu\n",ch,ch,(long long)seed);
|
|
||||||
fflush(fp2);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -187,6 +187,8 @@ char *actionfunc_str(char *str,void *ptr)
|
|||||||
strcpy(str,"rollwand");
|
strcpy(str,"rollwand");
|
||||||
else if ( ptr == (void *)visuals )
|
else if ( ptr == (void *)visuals )
|
||||||
strcpy(str,"visuals");
|
strcpy(str,"visuals");
|
||||||
|
else if ( ptr == (void *)turn_see )
|
||||||
|
strcpy(str,"turn_see");
|
||||||
else strcpy(str,"no match");
|
else strcpy(str,"no match");
|
||||||
return(str);
|
return(str);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -160,7 +160,7 @@ readchar(struct rogue_state *rs)
|
|||||||
if ( rs->ind < rs->numkeys )
|
if ( rs->ind < rs->numkeys )
|
||||||
{
|
{
|
||||||
c = rs->keystrokes[rs->ind++];
|
c = rs->keystrokes[rs->ind++];
|
||||||
if ( 1 )
|
if ( 0 )
|
||||||
{
|
{
|
||||||
static FILE *fp; static int32_t counter;
|
static FILE *fp; static int32_t counter;
|
||||||
if ( fp == 0 )
|
if ( fp == 0 )
|
||||||
|
|||||||
Reference in New Issue
Block a user