|
@@ -1433,7 +1433,8 @@ ACMD_FUNC(item)
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
- clif_displaymessage(fd, msg_txt(18)); // Item created.
|
|
|
|
|
|
+ if (flag == 0)
|
|
|
|
+ clif_displaymessage(fd, msg_txt(18)); // Item created.
|
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -1504,7 +1505,8 @@ ACMD_FUNC(item2)
|
|
clif_additem(sd, 0, 0, flag);
|
|
clif_additem(sd, 0, 0, flag);
|
|
}
|
|
}
|
|
|
|
|
|
- clif_displaymessage(fd, msg_txt(18)); // Item created.
|
|
|
|
|
|
+ if (flag == 0)
|
|
|
|
+ clif_displaymessage(fd, msg_txt(18)); // Item created.
|
|
} else {
|
|
} else {
|
|
clif_displaymessage(fd, msg_txt(19)); // Invalid item ID or name.
|
|
clif_displaymessage(fd, msg_txt(19)); // Invalid item ID or name.
|
|
return -1;
|
|
return -1;
|
|
@@ -3264,11 +3266,11 @@ ACMD_FUNC(doommap)
|
|
*------------------------------------------*/
|
|
*------------------------------------------*/
|
|
static void atcommand_raise_sub(struct map_session_data* sd)
|
|
static void atcommand_raise_sub(struct map_session_data* sd)
|
|
{
|
|
{
|
|
- if (!status_isdead(&sd->bl))
|
|
|
|
- return;
|
|
|
|
-
|
|
|
|
- if(!status_revive(&sd->bl, 100, 100))
|
|
|
|
- return;
|
|
|
|
|
|
+ if(pc_isdead(sd))
|
|
|
|
+ status_revive(&sd->bl, 100, 100);
|
|
|
|
+ else
|
|
|
|
+ status_percent_heal(&sd->bl, 100, 100);
|
|
|
|
+
|
|
clif_skill_nodamage(&sd->bl,&sd->bl,ALL_RESURRECTION,4,1);
|
|
clif_skill_nodamage(&sd->bl,&sd->bl,ALL_RESURRECTION,4,1);
|
|
clif_displaymessage(sd->fd, msg_txt(63)); // Mercy has been shown.
|
|
clif_displaymessage(sd->fd, msg_txt(63)); // Mercy has been shown.
|
|
}
|
|
}
|
|
@@ -4602,21 +4604,21 @@ char* txt_time(unsigned int duration)
|
|
minutes = duration / 60;
|
|
minutes = duration / 60;
|
|
seconds = duration - (60 * minutes);
|
|
seconds = duration - (60 * minutes);
|
|
|
|
|
|
- if (days < 2)
|
|
|
|
|
|
+ if (days == 1)
|
|
sprintf(temp, msg_txt(219), days); // %d day
|
|
sprintf(temp, msg_txt(219), days); // %d day
|
|
- else
|
|
|
|
|
|
+ else if (days > 1)
|
|
sprintf(temp, msg_txt(220), days); // %d days
|
|
sprintf(temp, msg_txt(220), days); // %d days
|
|
- if (hours < 2)
|
|
|
|
|
|
+ if (hours == 1)
|
|
sprintf(temp1, msg_txt(221), temp, hours); // %s %d hour
|
|
sprintf(temp1, msg_txt(221), temp, hours); // %s %d hour
|
|
- else
|
|
|
|
|
|
+ else if (hours > 1)
|
|
sprintf(temp1, msg_txt(222), temp, hours); // %s %d hours
|
|
sprintf(temp1, msg_txt(222), temp, hours); // %s %d hours
|
|
if (minutes < 2)
|
|
if (minutes < 2)
|
|
sprintf(temp, msg_txt(223), temp1, minutes); // %s %d minute
|
|
sprintf(temp, msg_txt(223), temp1, minutes); // %s %d minute
|
|
else
|
|
else
|
|
sprintf(temp, msg_txt(224), temp1, minutes); // %s %d minutes
|
|
sprintf(temp, msg_txt(224), temp1, minutes); // %s %d minutes
|
|
- if (seconds < 2)
|
|
|
|
|
|
+ if (seconds == 1)
|
|
sprintf(temp1, msg_txt(225), temp, seconds); // %s and %d second
|
|
sprintf(temp1, msg_txt(225), temp, seconds); // %s and %d second
|
|
- else
|
|
|
|
|
|
+ else if (seconds > 1)
|
|
sprintf(temp1, msg_txt(226), temp, seconds); // %s and %d seconds
|
|
sprintf(temp1, msg_txt(226), temp, seconds); // %s and %d seconds
|
|
|
|
|
|
return temp1;
|
|
return temp1;
|
|
@@ -6326,6 +6328,12 @@ ACMD_FUNC(pettalk)
|
|
|
|
|
|
nullpo_retr(-1, sd);
|
|
nullpo_retr(-1, sd);
|
|
|
|
|
|
|
|
+ if ( battle_config.min_chat_delay ) {
|
|
|
|
+ if( DIFF_TICK(sd->cantalk_tick, gettick()) > 0 )
|
|
|
|
+ return 0;
|
|
|
|
+ sd->cantalk_tick = gettick() + battle_config.min_chat_delay;
|
|
|
|
+ }
|
|
|
|
+
|
|
if(!sd->status.pet_id || !(pd=sd->pd))
|
|
if(!sd->status.pet_id || !(pd=sd->pd))
|
|
{
|
|
{
|
|
clif_displaymessage(fd, msg_txt(184));
|
|
clif_displaymessage(fd, msg_txt(184));
|
|
@@ -7088,6 +7096,12 @@ ACMD_FUNC(homtalk)
|
|
|
|
|
|
nullpo_retr(-1, sd);
|
|
nullpo_retr(-1, sd);
|
|
|
|
|
|
|
|
+ if ( battle_config.min_chat_delay ) {
|
|
|
|
+ if( DIFF_TICK(sd->cantalk_tick, gettick()) > 0 )
|
|
|
|
+ return 0;
|
|
|
|
+ sd->cantalk_tick = gettick() + battle_config.min_chat_delay;
|
|
|
|
+ }
|
|
|
|
+
|
|
if (sd->sc.count && //no "chatting" while muted.
|
|
if (sd->sc.count && //no "chatting" while muted.
|
|
(sd->sc.data[SC_BERSERK] ||
|
|
(sd->sc.data[SC_BERSERK] ||
|
|
(sd->sc.data[SC_NOCHAT] && sd->sc.data[SC_NOCHAT]->val1&MANNER_NOCHAT)))
|
|
(sd->sc.data[SC_NOCHAT] && sd->sc.data[SC_NOCHAT]->val1&MANNER_NOCHAT)))
|
|
@@ -8084,6 +8098,12 @@ ACMD_FUNC(main)
|
|
return -1;
|
|
return -1;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ if ( battle_config.min_chat_delay ) {
|
|
|
|
+ if( DIFF_TICK(sd->cantalk_tick, gettick()) > 0 )
|
|
|
|
+ return 0;
|
|
|
|
+ sd->cantalk_tick = gettick() + battle_config.min_chat_delay;
|
|
|
|
+ }
|
|
|
|
+
|
|
// send the message using inter-server system
|
|
// send the message using inter-server system
|
|
intif_main_message( sd, message );
|
|
intif_main_message( sd, message );
|
|
}
|
|
}
|