Re: [Circle] Do_who Parse Error

From: Graham Gilmore (gilmore@gmgate.vircom.com)
Date: 08/13/96


On Mon, 12 Aug 1996 grond@grotl.com wrote:

> CH>> sprintf(Mort_buf, "%s%s[%2d %s %s] %s %s|n",Mort_buf,
> CH>>   ((GET_CLASS(wch) == CLASS_CLERIC) ? CCMAG(ch,C_SPR)) :
> CH>>   ((GET_CLASS(wch) == CLASS_WARRIOR) ? CCYEL(ch,C_SPR)) :
> CH>>   ((GET_CLASS(wch) == CLASS_THIEF) ? CCBLU(ch,C_SPR)) :
> CH>>   ((GET_CLASS(wch) == CLASS_MAGIC_USER) ? CCRED(ch,C_SPR)),
> CH>                                see this? ^ need a colon here ^
> CH>>   GET_LEVEL(wch), CLASS_ABBR(wch), RACE_ABBR(wch),
> CH>>   GET_NAME(wch), GET_TITLE(wch));

	It seems to me that your ':' on each line is outside the 
parentheses containing the (I assume) corresponding '?'.  Strip off a 
trailing ')' from each line containing a "? :" structure, and add them to 
the end of the argument (ie, just before " , GET_LEVEL(wch)")
-->
	sprintf(Mort_buf, "%s%s[%2d %s %s] %s %s|n", Mort_buf,
  	   ((GET_CLASS(wch) == CLASS_CLERIC) ? CCMAG(ch, C_SPR) : 
	   ((GET_CLASS(wch) == CLASS_WARRIOR) ? CCYEL(ch, C_SPR) :
	   ((GET_CLASS(wch) == CLASS_THIEF) ? CCBLU(ch, C_SPR) :
	   ((GET_CLASS(wch) == CLASS_MAGIC_USER) ? CCRED(ch, C_SPR))))),
	   GET_LEVEL(wch), CLASS_ABBR(wch), RACE_ABBR(wch),
	   GET_NAME(wch), GET_TITLE(wch));


	
	Graham Gilmore



	 

+-----------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
|   http://cspo.queensu.ca/~fletcher/Circle/list_faq.html   |
+-----------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/07/00 PST