case 'h' :
if(IS_SET(ch->act, PLR_COLOUR)) {
int hperc = ((ch->hit*100)/ch->max_hit);
if(hperc>=75) {
sprintf( buf2, "%s%d%s", C_WHITE, ch->hit, CLEAR);
} else if(hperc>=50) {
sprintf( buf2, "%s%d%s", C_YELLOW, ch->hit, CLEAR);
} else if(hperc>=25) {
sprintf( buf2, "%s%d%s", C_B_RED, ch->hit, CLEAR);
} else {
sprintf( buf2, "%s%d%s", C_RED, ch->hit, CLEAR);
}
} else {
sprintf( buf2, "%d", ch->hit);
}
i = buf2; break;
*(s+sizeof(char) * index) = 'c';
s[index] ='c';
index[s] ='c';
*(s+sizeof(char) * index) = 'c';
*(s+index) = 'c';
s[index] = 'c';
index[s] = 'c';
You see Main Street.
-South to [ 3034] Key: [ -1] Exit flags: [none]
You see the Jeweller's Shop.
-West to [ 3014] Key: [ -1] Exit flags: [none]
You see the market square.
30000m 30000mv>
Also from some other methods…not just redit.
Here is the code I put into bust_a_prompt in comm.c
Then the usual stuff, then I put a thing to break down color codes for the prompt
Then later…
I don't see how other stuff keeps getting locked in here…I haven't coded in awhile and was never a pro at all..