bones tracking (trunk only)

[See cvs log for include/rm.h or doc/window.doc for more complete description.]

Attach hero info, death reason, and date+time to a level that's being saved
as bones.  Read such data back when loading a bones file, then treat it as
part of that level for the rest of the game.  Dying on a loaded bones file
will chain the new hero+death+date to previous one(s) if new bones get saved.

outrip() now takes an extra argument of type time_t, and interface-specific
implementations of this routine need to be updated to handle that.
This commit is contained in:
nethack.rankin
2012-01-23 10:45:31 +00:00
parent b88c51deae
commit 9721470635
15 changed files with 152 additions and 64 deletions

View File

@@ -429,11 +429,12 @@ chainin_end_screen()
}
void
chainin_outrip(tmpwin, how)
chainin_outrip(tmpwin, how, when)
winid tmpwin;
int how;
time_t when;
{
(*cibase->nprocs->win_outrip)(cibase->ndata, tmpwin, how);
(*cibase->nprocs->win_outrip)(cibase->ndata, tmpwin, how, when);
}
void

View File

@@ -541,14 +541,15 @@ chainout_end_screen(vp)
}
void
chainout_outrip(vp, tmpwin, how)
chainout_outrip(vp, tmpwin, how, when)
void *vp;
winid tmpwin;
int how;
time_t when;
{
struct chainout_data *tdp = vp;
(*tdp->nprocs->win_outrip)(tmpwin, how);
(*tdp->nprocs->win_outrip)(tmpwin, how, when);
}
void

View File

@@ -928,17 +928,19 @@ trace_end_screen(vp)
}
void
trace_outrip(vp, tmpwin, how)
trace_outrip(vp, tmpwin, how, when)
void *vp;
winid tmpwin;
int how;
time_t when;
{
struct trace_data *tdp = vp;
fprintf(wc_tracelogf, "%soutrip(%d, %d)\n", INDENT, tmpwin, how);
fprintf(wc_tracelogf, "%soutrip(%d, %d, %ld)\n",
INDENT, (int)tmpwin, how, (long)when);
PRE;
(*tdp->nprocs->win_outrip)(tdp->ndata, tmpwin, how);
(*tdp->nprocs->win_outrip)(tdp->ndata, tmpwin, how, when);
POST;
}