And some more warning fixes
This commit is contained in:
30
src/sp_lev.c
30
src/sp_lev.c
@@ -93,6 +93,7 @@ static void NDECL(spo_pop_container);
|
||||
static int FDECL(l_create_stairway, (lua_State *, BOOLEAN_P));
|
||||
static void FDECL(spo_endroom, (struct sp_coder *));
|
||||
static void FDECL(l_table_getset_feature_flag, (lua_State *, int, int, const char *, int));
|
||||
static void FDECL(sel_set_lit, (int, int, genericptr_t));
|
||||
static void FDECL(sel_set_ter, (int, int, genericptr_t));
|
||||
static void FDECL(sel_set_door, (int, int, genericptr_t));
|
||||
static void FDECL(sel_set_feature, (int, int, genericptr_t));
|
||||
@@ -4825,32 +4826,6 @@ genericptr_t arg;
|
||||
(*func)(x, y, arg);
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
stackDump(L)
|
||||
lua_State *L;
|
||||
{
|
||||
int i;
|
||||
int top = lua_gettop(L);
|
||||
for (i = 1; i <= top; i++) { /* repeat for each level */
|
||||
int t = lua_type(L, i);
|
||||
switch (t) {
|
||||
case LUA_TSTRING: /* strings */
|
||||
pline("%i:\"%s\"", i, lua_tostring(L, i));
|
||||
break;
|
||||
case LUA_TBOOLEAN: /* booleans */
|
||||
pline("%i:%s", i, lua_toboolean(L, i) ? "true" : "false");
|
||||
break;
|
||||
case LUA_TNUMBER: /* numbers */
|
||||
pline("%i:%g", i, lua_tonumber(L, i));
|
||||
break;
|
||||
default: /* other values */
|
||||
pline("%i:%s", i, lua_typename(L, t));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
sel_set_ter(x, y, arg)
|
||||
int x, y;
|
||||
@@ -5548,8 +5523,7 @@ lua_State *L;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
static void
|
||||
sel_set_lit(x, y, arg)
|
||||
int x, y;
|
||||
genericptr_t arg;
|
||||
|
||||
@@ -1020,11 +1020,11 @@ level_tele()
|
||||
which branches don't connect to anything deeper;
|
||||
mainly used to distinguish "can't get there from here"
|
||||
vs "from anywhere" rather than to control destination */
|
||||
d_level *branch = In_quest(&u.uz) ? &qstart_level
|
||||
d_level *qbranch = In_quest(&u.uz) ? &qstart_level
|
||||
: In_mines(&u.uz) ? &mineend_level
|
||||
: &sanctum_level;
|
||||
int deepest = g.dungeons[branch->dnum].depth_start
|
||||
+ dunlevs_in_dungeon(branch) - 1;
|
||||
int deepest = g.dungeons[qbranch->dnum].depth_start
|
||||
+ dunlevs_in_dungeon(qbranch) - 1;
|
||||
|
||||
/* if invocation did not yet occur, teleporting into
|
||||
* the last level of Gehennom is forbidden.
|
||||
|
||||
@@ -9,6 +9,8 @@ extern const char *const destroy_strings[][3]; /* from zap.c */
|
||||
|
||||
static boolean FDECL(keep_saddle_with_steedcorpse, (unsigned, struct obj *,
|
||||
struct obj *));
|
||||
static boolean FDECL(mu_maybe_destroy_web, (struct monst *, BOOLEAN_P,
|
||||
struct trap *));
|
||||
static struct obj *FDECL(t_missile, (int, struct trap *));
|
||||
static char *FDECL(trapnote, (struct trap *, BOOLEAN_P));
|
||||
static int FDECL(steedintrap, (struct trap *, struct obj *));
|
||||
@@ -805,7 +807,7 @@ struct obj *objchn, *saddle;
|
||||
|
||||
/* monster or you go through and possibly destroy a web.
|
||||
return TRUE if could go through. */
|
||||
boolean
|
||||
static boolean
|
||||
mu_maybe_destroy_web(mtmp, domsg, trap)
|
||||
struct monst *mtmp;
|
||||
boolean domsg;
|
||||
|
||||
@@ -17,6 +17,7 @@ static struct obj *FDECL(on_ground, (SHORT_P));
|
||||
static boolean FDECL(you_have, (int));
|
||||
static unsigned long FDECL(target_on, (int, struct monst *));
|
||||
static unsigned long FDECL(strategy, (struct monst *));
|
||||
static void FDECL(choose_stairs, (xchar *, xchar *));
|
||||
|
||||
/* adding more neutral creatures will tend to reduce the number of monsters
|
||||
summoned by nasty(); adding more lawful creatures will reduce the number
|
||||
@@ -321,7 +322,7 @@ register struct monst *mtmp;
|
||||
return dstrat;
|
||||
}
|
||||
|
||||
void
|
||||
static void
|
||||
choose_stairs(sx, sy)
|
||||
xchar *sx;
|
||||
xchar *sy;
|
||||
|
||||
Reference in New Issue
Block a user