diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-04-06 14:54:28 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-04-06 14:54:28 -0600 |
commit | b8e18bab09688cd73415f7ceb72a738a4528529b (patch) | |
tree | 2bed4071aa084a5c2613f036b7e914c8e9f28fcb /src/char | |
parent | 0187b02a470c12b7e135c4f1c261000d1ce64ff5 (diff) | |
download | tmwa-b8e18bab09688cd73415f7ceb72a738a4528529b.tar.gz tmwa-b8e18bab09688cd73415f7ceb72a738a4528529b.tar.bz2 tmwa-b8e18bab09688cd73415f7ceb72a738a4528529b.tar.xz tmwa-b8e18bab09688cd73415f7ceb72a738a4528529b.zip |
Fix to allow divorce is weird situations
Like when only the requesting parter is part of the marriage.
Diffstat (limited to 'src/char')
-rw-r--r-- | src/char/char.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/char/char.c b/src/char/char.c index f7cb491..677d4b3 100644 --- a/src/char/char.c +++ b/src/char/char.c @@ -1406,6 +1406,14 @@ int char_divorce(struct mmo_charstatus *cs) { char_dat[i].partner_id = 0; return 0; } + // The other char doesn't have us as their partner, so just clear our partner + // Don't worry about this, as the map server should verify itself that the other doesn't have us as a partner, and so won't mess with their marriage + else if (char_dat[i].char_id == cs->partner_id) { + WBUFL(buf,6) = cs->partner_id; + mapif_sendall(buf,10); + cs->partner_id = 0; + return 0; + } } WBUFL(buf,6) = 0; // partner id 0 means failure |