gender, pc_race_types, and pc_class_types are arrays. The number in the
brackets is the subscript. That number must(?) be an integer.
ch->player.chclass is defined as a byte, last time I checked. Ditto sex.
Probably race as well.[1]
Solution? gender[(int) GET_SEX(ch)]
.-----------------------------------.
| Arioch |
| The Fractal Dimension |
| telnet://oberon.krans.com:4096 |
'-----------------------------------'
1 - I'm tired. Maybe those are different types. But this message should
still make sense.
On Thu, 6 May 1999, Shaun Bourque wrote:
> warning: array subscript has type 'char'
>
> sprintf(buf, "%s: You are a %d year old %s %s %s. Your level is %d.",
> GET_NAME(ch), GET_AGE(ch), gender[GET_SEX(ch)], pc_race_types[GET_RACE(ch)],
> pc_class_types[GET_CLASS(ch)], GET_LEVEL(ch));
> send_to_char(buf, ch);
>
> i added a couple externs...
> extern const char *pc_class_types[] and the same for race
>
+------------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
| http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
+------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST