Added new zone creation limits to prevent misuse of zedit making the MUD unbootable. --Rumble
This commit is contained in:
@@ -35,6 +35,9 @@ export (QQ's a zone into a tarball)t
|
|||||||
Xlist (mlist, olist, rlist, zlist, slist, tlist, qlist)
|
Xlist (mlist, olist, rlist, zlist, slist, tlist, qlist)
|
||||||
(lots of major bugfixes too)
|
(lots of major bugfixes too)
|
||||||
tbaMUD 3.59
|
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
|
[Jan 25 2009] - Jamdog
|
||||||
Added cases for missing object types in oedit_disp_val1_menu (other, worn, treasure, trash, key, pen, boat)
|
Added cases for missing object types in oedit_disp_val1_menu (other, worn, treasure, trash, key, pen, boat)
|
||||||
[Jan 25 2009] - Rumble
|
[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;
|
FILE *fp;
|
||||||
struct zone_data *zone;
|
struct zone_data *zone;
|
||||||
int i;
|
int i, max_zone;
|
||||||
zone_rnum rznum;
|
zone_rnum rznum;
|
||||||
char buf[MAX_STRING_LENGTH];
|
char buf[MAX_STRING_LENGTH];
|
||||||
|
|
||||||
#if CIRCLE_UNSIGNED_INDEX
|
#if CIRCLE_UNSIGNED_INDEX
|
||||||
|
max_zone = 655;
|
||||||
if (vzone_num == NOWHERE) {
|
if (vzone_num == NOWHERE) {
|
||||||
#else
|
#else
|
||||||
|
max_zone = 327;
|
||||||
if (vzone_num < 0) {
|
if (vzone_num < 0) {
|
||||||
#endif
|
#endif
|
||||||
*error = "You can't make negative zones.\r\n";
|
*error = "You can't make negative zones.\r\n";
|
||||||
return NOWHERE;
|
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) {
|
} else if (bottom > top) {
|
||||||
*error = "Bottom room cannot be greater than top room.\r\n";
|
*error = "Bottom room cannot be greater than top room.\r\n";
|
||||||
return NOWHERE;
|
return NOWHERE;
|
||||||
|
|||||||
Reference in New Issue
Block a user