diff options
author | Haru <haru@dotalux.com> | 2016-04-20 17:06:18 +0200 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2016-04-23 19:09:33 +0200 |
commit | d7ffa6adbcf4800821fe3f961513952450d06f98 (patch) | |
tree | f6565bf5ae7e0d2d46a42dc734c83b9adb7b6abe /src/map/duel.c | |
parent | e4feddf5198f1c9d45a6c34a95b251df773ab6db (diff) | |
download | hercules-d7ffa6adbcf4800821fe3f961513952450d06f98.tar.gz hercules-d7ffa6adbcf4800821fe3f961513952450d06f98.tar.bz2 hercules-d7ffa6adbcf4800821fe3f961513952450d06f98.tar.xz hercules-d7ffa6adbcf4800821fe3f961513952450d06f98.zip |
Removed the 'len' argument from clif_disp_onlyself() and clif->disp_message()
- The argument was redundant, since the passed value is always the same
as the passed string's length (it doesn't make sense otherwise). The
argument is implicit now. Less typing and less errors.
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/map/duel.c')
-rw-r--r-- | src/map/duel.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/map/duel.c b/src/map/duel.c index 86c218acd..64991d39c 100644 --- a/src/map/duel.c +++ b/src/map/duel.c @@ -73,7 +73,7 @@ static int duel_showinfo_sub(struct map_session_data* sd, va_list va) if (sd->duel_group != ssd->duel_group) return 0; sprintf(output, " %d. %s", ++(*p), sd->status.name); - clif_disp_onlyself(ssd, output, strlen(output)); + clif_disp_onlyself(ssd, output); return 1; } @@ -93,7 +93,7 @@ void duel_showinfo(const unsigned int did, struct map_session_data* sd) { duel->list[did].members_count, duel->list[did].members_count + duel->list[did].invites_count); - clif_disp_onlyself(sd, output, strlen(output)); + clif_disp_onlyself(sd, output); map->foreachpc(duel_showinfo_sub, sd, &p); } @@ -113,7 +113,7 @@ int duel_create(struct map_session_data* sd, const unsigned int maxpl) { duel->list[i].max_players_limit = maxpl; safestrncpy(output, msg_sd(sd,372), sizeof(output)); // " -- Duel has been created (@invite/@leave) --" - clif_disp_onlyself(sd, output, strlen(output)); + clif_disp_onlyself(sd, output); clif->map_property(sd, MAPPROPERTY_FREEPVPZONE); clif->maptypeproperty2(&sd->bl,SELF); @@ -127,7 +127,7 @@ void duel_invite(const unsigned int did, struct map_session_data* sd, struct map nullpo_retv(target_sd); // " -- Player %s invites %s to duel --" sprintf(output, msg_sd(sd,373), sd->status.name, target_sd->status.name); - clif->disp_message(&sd->bl, output, strlen(output), DUEL_WOS); + clif->disp_message(&sd->bl, output, DUEL_WOS); target_sd->duel_invite = did; duel->list[did].invites_count++; @@ -152,7 +152,7 @@ void duel_leave(const unsigned int did, struct map_session_data* sd) { nullpo_retv(sd); // " <- Player %s has left duel --" sprintf(output, msg_sd(sd,375), sd->status.name); - clif->disp_message(&sd->bl, output, strlen(output), DUEL_WOS); + clif->disp_message(&sd->bl, output, DUEL_WOS); duel->list[did].members_count--; if(duel->list[did].members_count == 0) { @@ -177,7 +177,7 @@ void duel_accept(const unsigned int did, struct map_session_data* sd) { // " -> Player %s has accepted duel --" sprintf(output, msg_sd(sd,376), sd->status.name); - clif->disp_message(&sd->bl, output, strlen(output), DUEL_WOS); + clif->disp_message(&sd->bl, output, DUEL_WOS); clif->map_property(sd, MAPPROPERTY_FREEPVPZONE); clif->maptypeproperty2(&sd->bl,SELF); @@ -189,7 +189,7 @@ void duel_reject(const unsigned int did, struct map_session_data* sd) { nullpo_retv(sd); // " -- Player %s has rejected duel --" sprintf(output, msg_sd(sd,377), sd->status.name); - clif->disp_message(&sd->bl, output, strlen(output), DUEL_WOS); + clif->disp_message(&sd->bl, output, DUEL_WOS); duel->list[did].invites_count--; sd->duel_invite = 0; |