Re: [Newbie] [Code] Room Flags MSVC 6

From: brent (brack_78@yahoo.com)
Date: 10/10/02


Yes my friend said the same thing about 32, but he wasn't sure about windows that's why I was asking.
As for the code I have:

oasis.h
#define NUM_ROOM_FLAGS 24
constants.c
/* ROOM_x */
const char *room_bits[] = {
  "DARK",
  "DEATH",
  "!MOB",
  "INDOORS",
  "PEACEFUL",
  "SOUNDPROOF",
  "!TRACK",
  "!MAGIC",
  "TUNNEL",
  "PRIVATE",
  "GODROOM",
  "HOUSE",
  "HCRSH",
  "ATRIUM",
  "OLC",
  "NOMAGICUSER",
  "NOCLERIC",
  "NOTHIEF",
  "NOWARRIOR",
  "GOOD_REGEN",
  "VAMPIRE",
  "LAIR",
  "!RECALL",
  "*",    /* BFS MARK */
  "\n"
};

structs.h
#define ROOM_DARK        (1 << 0)   /* Dark   */
#define ROOM_DEATH      (1 << 1)   /* Death trap  */
#define ROOM_NOMOB      (1 << 2)   /* MOBs not allowed  */
#define ROOM_INDOORS    (1 << 3)   /* Indoors   */
#define ROOM_PEACEFUL    (1 << 4)   /* Violence not allowed */
#define ROOM_SOUNDPROOF  (1 << 5)   /* Shouts, gossip blocked */
#define ROOM_NOTRACK    (1 << 6)   /* Track won't go through */
#define ROOM_NOMAGIC    (1 << 7)   /* Magic not allowed  */
#define ROOM_TUNNEL      (1 << 8)   /* room for only 1 pers */
#define ROOM_PRIVATE    (1 << 9)   /* Can't teleport in  */
#define ROOM_GODROOM    (1 << 10)  /* LVL_GOD+ only allowed */
 #define ROOM_HOUSE      (1 << 11)  /* (R) Room is a house */
#define ROOM_HOUSE_CRASH (1 << 12)  /* (R) House needs saving */
#define ROOM_ATRIUM      (1 << 13)  /* (R) The door to a house */
#define ROOM_OLC        (1 << 14)  /* (R) Modifyable/!compress */
#define ROOM_NOMAGICUSER        (1 << 15)
#define ROOM_NOCLERIC           (1 << 16)
#define ROOM_NOTHIEF            (1 << 17)
#define ROOM_NOWARRIOR          (1 << 18)
#define ROOM_GOOD_REGEN   (1 << 19)  // Good Regeneration Room
#define ROOM_VAMPIRE      (1 << 20)
#define ROOM_LAIR         (1 << 21)  // Vampire's Lair
#define ROOM_NORECALL     (1 << 22)  /* Recalling not allowed  */
#define ROOM_BFS_MARK     (1 << 23)  /* (R) breath-first srch mrk */
 "Daniel A. Koepke" wrote:
On Wed, 9 Oct 2002, brent wrote:

> is there a preset limit to how many room flags you can use while
> compiling under msvc 6.0?

The only limitation on the number of room flags is the number of bits in
an integer on your platform. For you, like most people, that's 32. (You
would get a compiler error if you exceeded that limit, though.)



> I know I coded everthing properly.

How do you know that? Such surety is best not broached.


> I can get them to work if I move them higher up on the list for example
> move roomflag 21 - 24 and make them 16-20...but the others that was
> originall 16-20 that is now 21-24 don't show.

It sounds as if NUM_ROOM_FLAGS in oasis.h does not agree with the actual
number of room flags you have.


-dak




---------------------------------
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos, & more
faith.yahoo.com

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   | Newbie List:  http://groups.yahoo.com/group/circle-newbies/   |
   +---------------------------------------------------------------+



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