Re: top_of_zone_table?

From: Sam Moggach (
Date: 10/05/02

The problem is obviously top_of_zone_table going too high. the mud always
assumes that top_of_zone_table is the zone with the highest rnum. So the
real problem: you're top_of_zone_table variable is 1 too many,

>int real_zone(int number)
>   int counter;
>   for (counter = 0; counter <= top_of_zone_table; counter++)
>     if ((number >= (zone_table[counter].number * 100)) &&
>       (number <= (zone_table[counter].top)))
>       return counter;
>   return -1;

top_of_zone_table  lies! it says there are (n) zones in teh mud when really
there are (n-1) zones. so when counter = top_of_zone_table, it is trying to
access a zone that does not exist.

This means that somewhere in your code you have increased the value of
top_of_zone_table one too many times. check around and see where you change
the value of this variable. (i'm no good at helping people, which is why you
dont see me do it often, cause i have a hard time explaining things, so hope
u get some help from someone a little more useful.)

- Micken

Send and receive Hotmail on your mobile device:

   | FAQ: |
   | Archives: |
   | Newbie List:   |

This archive was generated by hypermail 2b30 : 06/25/03 PDT