>Ok I know I'm gonna get flamed for this but I need to know how to write >arguments more than say 7 characters long?? No, you won't. Atleast, I hope not. >Heres what I'm trying to do: >Add a simple race system so you start off human and can buy the cyborg >class and what not :) Sounds interesting. >switch (*argument) { > case 'cyborg': > <code> > break; > case 'robot': > <code> > break; > default: > send_to_char("Your not a human!!", ch); > break; >} > You know, not too long ago I was trying to compare strings the same way. But in C, it must be done differently. Try this if (!strcmp(argument, "cyborg")) <code> else if (!strcmp(argument, "robot")) <code> else send_to_char("Your not human!", ch); +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/08/00 PST