mirror of
https://github.com/tbamud/tbamud.git
synced 2025-09-22 05:50:48 +02:00
Addressed warnings from -Wall.
This commit is contained in:
parent
5119361f15
commit
cacd2c2dd2
8 changed files with 9 additions and 8 deletions
|
@ -6,7 +6,6 @@ Development moved to Github:
|
|||
https://github.com/tbamud/tbamud
|
||||
Changelog also available on Github:
|
||||
https://github.com/tbamud/tbamud/commits/master
|
||||
|
||||
Changes prior to Github transition:
|
||||
[Jun 21 2013] - Vatiken
|
||||
Added 'toupper' as a dg_script command to capitalize the first letter
|
||||
|
|
|
@ -4,4 +4,5 @@
|
|||
|
||||
Immortals
|
||||
~~~~~~~~~
|
||||
Wylder
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
|
||||
Implementors
|
||||
~~~~~~~~~~~~
|
||||
Wyld
|
||||
|
||||
Greater Gods
|
||||
~~~~~~~~~~~~
|
||||
|
|
|
@ -71,7 +71,7 @@ static void show_obj_to_char(struct obj_data *obj, struct char_data *ch, int mod
|
|||
}
|
||||
|
||||
if ((mode == 0) && obj->description) {
|
||||
if (!GET_OBJ_VAL(obj, 1) == 0 || OBJ_SAT_IN_BY(obj)) {
|
||||
if (GET_OBJ_VAL(obj, 1) != 0 || OBJ_SAT_IN_BY(obj)) {
|
||||
temp = OBJ_SAT_IN_BY(obj);
|
||||
for (temp = OBJ_SAT_IN_BY(obj); temp; temp = NEXT_SITTING(temp)) {
|
||||
if (temp == ch)
|
||||
|
@ -1481,7 +1481,7 @@ ACMD(do_users)
|
|||
"UNDEFINED",
|
||||
state, idletime, timestr);
|
||||
|
||||
if (d->host && *d->host)
|
||||
if (*d->host)
|
||||
sprintf(line + strlen(line), "[%s]\r\n", d->host);
|
||||
else
|
||||
strcat(line, "[Hostname unknown]\r\n");
|
||||
|
|
|
@ -880,7 +880,7 @@ ACMD(do_drink)
|
|||
send_to_char(ch, "Your stomach can't contain anymore!\r\n");
|
||||
return;
|
||||
}
|
||||
if ((GET_OBJ_VAL(temp, 1) == 0) || (!GET_OBJ_VAL(temp, 0) == 1)) {
|
||||
if ((GET_OBJ_VAL(temp, 1) == 0) || (GET_OBJ_VAL(temp, 0) != 1)) {
|
||||
send_to_char(ch, "It is empty.\r\n");
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -4983,7 +4983,7 @@ ACMD(do_recent)
|
|||
ct = this->time;
|
||||
strftime(timestr, sizeof(timestr), "%a %b %d %H:%M:%S %Y", localtime(&ct));
|
||||
|
||||
if (this->host && *(this->host)) {
|
||||
if (*(this->host)) {
|
||||
if (!strcmp(this->host, "localhost")) loc = TRUE;
|
||||
}
|
||||
|
||||
|
|
|
@ -585,9 +585,9 @@ MapArea(target_room, ch, centre, centre, min, max, ns_size/2, ew_size/2, worldma
|
|||
char_size = 3*(size+1) + (size) + 4;
|
||||
|
||||
if(worldmap)
|
||||
send_to_char(ch, "%s", strpaste(strfrmt(str, GET_SCREEN_WIDTH(ch) - char_size, size*2 + 1, FALSE, TRUE, TRUE), WorldMap(centre, size, MAP_CIRCLE, MAP_COMPACT), " \tn"));
|
||||
send_to_char(ch, "%s", strpaste(WorldMap(centre, size, MAP_CIRCLE, MAP_COMPACT), strfrmt(str, GET_SCREEN_WIDTH(ch) - char_size, size*2 + 1, FALSE, TRUE, TRUE), " \tn"));
|
||||
else
|
||||
send_to_char(ch, "%s", strpaste(strfrmt(str, GET_SCREEN_WIDTH(ch) - char_size, size*2 + 1, FALSE, TRUE, TRUE), CompactStringMap(centre, size), " \tn"));
|
||||
send_to_char(ch, "%s", strpaste(CompactStringMap(centre, size), strfrmt(str, GET_SCREEN_WIDTH(ch) - char_size, size*2 + 1, FALSE, TRUE, TRUE), " \tn"));
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -514,7 +514,7 @@ void save_char(struct char_data * ch)
|
|||
|
||||
/* If ch->desc is not null, then update session data before saving. */
|
||||
if (ch->desc) {
|
||||
if (ch->desc->host && *ch->desc->host) {
|
||||
if (*ch->desc->host) {
|
||||
if (!GET_HOST(ch))
|
||||
GET_HOST(ch) = strdup(ch->desc->host);
|
||||
else if (GET_HOST(ch) && strcmp(GET_HOST(ch), ch->desc->host)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue