Add stormy level flag
Which makes clouds create lightning bolts at random. This flag is used on the plane of air. Breaks saves and bones.
This commit is contained in:
+1
-1
@@ -6,7 +6,7 @@
|
|||||||
--
|
--
|
||||||
des.level_init({ style = "solidfill", fg = " " });
|
des.level_init({ style = "solidfill", fg = " " });
|
||||||
|
|
||||||
des.level_flags("mazelevel", "noteleport", "hardfloor", "shortsighted")
|
des.level_flags("mazelevel", "noteleport", "hardfloor", "shortsighted", "stormy")
|
||||||
-- The following messages are somewhat obtuse, to make then
|
-- The following messages are somewhat obtuse, to make then
|
||||||
-- equally meaningful if the player can see or not.
|
-- equally meaningful if the player can see or not.
|
||||||
des.message("What a strange feeling!")
|
des.message("What a strange feeling!")
|
||||||
|
|||||||
@@ -615,6 +615,7 @@ Set flags for this level.
|
|||||||
| nomongen | Prevents random monster generation.
|
| nomongen | Prevents random monster generation.
|
||||||
| nodeathdrops | Prevents killed monsters from dropping corpses or random death drops.
|
| nodeathdrops | Prevents killed monsters from dropping corpses or random death drops.
|
||||||
| fumaroles | Lava emits poison gas clouds at random.
|
| fumaroles | Lava emits poison gas clouds at random.
|
||||||
|
| stormy | Clouds create lightning bolts at random.
|
||||||
|===
|
|===
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
* Incrementing EDITLEVEL can be used to force invalidation of old bones
|
* Incrementing EDITLEVEL can be used to force invalidation of old bones
|
||||||
* and save files.
|
* and save files.
|
||||||
*/
|
*/
|
||||||
#define EDITLEVEL 79
|
#define EDITLEVEL 80
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Development status possibilities.
|
* Development status possibilities.
|
||||||
|
|||||||
@@ -393,6 +393,7 @@ struct levelflags {
|
|||||||
Bitfield(deathdrops, 1); /* monsters may drop corpses/death drops */
|
Bitfield(deathdrops, 1); /* monsters may drop corpses/death drops */
|
||||||
Bitfield(noautosearch, 1); /* automatic searching disabled */
|
Bitfield(noautosearch, 1); /* automatic searching disabled */
|
||||||
Bitfield(fumaroles, 1); /* lava emits poison gas at random */
|
Bitfield(fumaroles, 1); /* lava emits poison gas at random */
|
||||||
|
Bitfield(stormy, 1); /* clouds create lightning bolts at random */
|
||||||
|
|
||||||
schar temperature; /* +1 == hot, -1 == cold */
|
schar temperature; /* +1 == hot, -1 == cold */
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -3749,6 +3749,8 @@ lspo_level_flags(lua_State *L)
|
|||||||
gl.level.flags.noautosearch = 1;
|
gl.level.flags.noautosearch = 1;
|
||||||
else if (!strcmpi(s, "fumaroles"))
|
else if (!strcmpi(s, "fumaroles"))
|
||||||
gl.level.flags.fumaroles = 1;
|
gl.level.flags.fumaroles = 1;
|
||||||
|
else if (!strcmpi(s, "stormy"))
|
||||||
|
gl.level.flags.stormy = 1;
|
||||||
else {
|
else {
|
||||||
char buf[BUFSZ];
|
char buf[BUFSZ];
|
||||||
Sprintf(buf, "Unknown level flag %s", s);
|
Sprintf(buf, "Unknown level flag %s", s);
|
||||||
|
|||||||
+2
-2
@@ -1706,8 +1706,8 @@ do_storms(void)
|
|||||||
int dirx, diry;
|
int dirx, diry;
|
||||||
int count;
|
int count;
|
||||||
|
|
||||||
/* no lightning if not the air level or too often, even then */
|
/* no lightning if not stormy level or too often, even then */
|
||||||
if (!Is_airlevel(&u.uz) || rn2(8))
|
if (!gl.level.flags.stormy || rn2(8))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* the number of strikes is 8-log2(nstrike) */
|
/* the number of strikes is 8-log2(nstrike) */
|
||||||
|
|||||||
Reference in New Issue
Block a user