mirror of
https://github.com/tbamud/tbamud.git
synced 2026-01-04 16:38:49 +01:00
Added new zone creation limits to prevent misuse of zedit making the MUD unbootable. --Rumble
This commit is contained in:
parent
62e698b51f
commit
65b23ad812
2 changed files with 13 additions and 1 deletions
|
|
@ -35,6 +35,9 @@ export (QQ's a zone into a tarball)t
|
|||
Xlist (mlist, olist, rlist, zlist, slist, tlist, qlist)
|
||||
(lots of major bugfixes too)
|
||||
tbaMUD 3.59
|
||||
[Jan 25 2009] - Rumble
|
||||
Added new documentation /doc unixshelladminguide. (thanks Jamdog).
|
||||
Added new zone creation limits to prevent misuse of zedit making the MUD unbootable.
|
||||
[Jan 25 2009] - Jamdog
|
||||
Added cases for missing object types in oedit_disp_val1_menu (other, worn, treasure, trash, key, pen, boat)
|
||||
[Jan 25 2009] - Rumble
|
||||
|
|
|
|||
11
src/genzon.c
11
src/genzon.c
|
|
@ -51,17 +51,26 @@ zone_rnum create_new_zone(zone_vnum vzone_num, room_vnum bottom, room_vnum top,
|
|||
{
|
||||
FILE *fp;
|
||||
struct zone_data *zone;
|
||||
int i;
|
||||
int i, max_zone;
|
||||
zone_rnum rznum;
|
||||
char buf[MAX_STRING_LENGTH];
|
||||
|
||||
#if CIRCLE_UNSIGNED_INDEX
|
||||
max_zone = 655;
|
||||
if (vzone_num == NOWHERE) {
|
||||
#else
|
||||
max_zone = 327;
|
||||
if (vzone_num < 0) {
|
||||
#endif
|
||||
*error = "You can't make negative zones.\r\n";
|
||||
return NOWHERE;
|
||||
} else if (vzone_num > max_zone) {
|
||||
#if CIRCLE_UNSIGNED_INDEX
|
||||
*error = "New zone cannot be higher than 655.\r\n";
|
||||
#else
|
||||
*error = "New zone cannot be higher than 327.\r\n";
|
||||
#endif
|
||||
return NOWHERE;
|
||||
} else if (bottom > top) {
|
||||
*error = "Bottom room cannot be greater than top room.\r\n";
|
||||
return NOWHERE;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue