From 36fbf37bb85d5cc6293c97735d89981b13596c77 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Sun, 18 Jun 2006 17:47:26 +0000 Subject: [PATCH] (arm): Fix trading block message. (disarm): Recipient must be allied. --- src/lib/commands/arm.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/lib/commands/arm.c b/src/lib/commands/arm.c index a1cf3d59..7f332063 100644 --- a/src/lib/commands/arm.c +++ b/src/lib/commands/arm.c @@ -73,7 +73,7 @@ arm(void) } if (opt_MARKET) { if (ontradingblock(EF_PLANE, &pl)) { - pr("You cannot disarm %s while it is on the trading block!\n", + pr("You cannot arm %s while it is on the trading block!\n", prplane(&pl)); return RET_FAIL; } @@ -154,6 +154,12 @@ disarm(void) continue; } getsect(nuke.nuk_x, nuke.nuk_y, §); + if (!player->owner + && getrel(getnatp(sect.sct_own), player->cnum) != ALLIED) { + pr("Disarming %s in sector %s requires an alliance!\n", + prplane(&pl), xyas(sect.sct_x, sect.sct_y, player->cnum)); + continue; + } snprintf(buf, sizeof(buf), "unloaded in your %s at %s", dchr[sect.sct_type].d_name, xyas(sect.sct_x, sect.sct_y, sect.sct_own));