summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2011-01-28 02:20:13 +0000
committerai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2011-01-28 02:20:13 +0000
commitd5590087f94f18b2a85980f504b26643eb3f62a1 (patch)
treef5f8220ce5fbf0094f47357ce5087137f52e992e /src
parent4c3099bb6c186786858887730b896c6b96415b2a (diff)
downloadhercules-d5590087f94f18b2a85980f504b26643eb3f62a1.tar.gz
hercules-d5590087f94f18b2a85980f504b26643eb3f62a1.tar.bz2
hercules-d5590087f94f18b2a85980f504b26643eb3f62a1.tar.xz
hercules-d5590087f94f18b2a85980f504b26643eb3f62a1.zip
* Fixed @accept not checking, whether or not a duel is already full (bugreport:2740, since r4111).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14684 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/map/atcommand.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index 9d069e0c2..dce7441df 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -7963,6 +7963,13 @@ ACMD_FUNC(accept)
return 0;
}
+ if( duel_list[sd->duel_invite].max_players_limit > 0 && duel_list[sd->duel_invite].members_count >= duel_list[sd->duel_invite].max_players_limit )
+ {
+ // "Duel: Limit of players is reached."
+ clif_displaymessage(fd, msg_txt(351));
+ return 0;
+ }
+
duel_accept(sd->duel_invite, sd);
// "Duel: Invitation has been accepted."
clif_displaymessage(fd, msg_txt(361));