From 90dd700487672bc76e4072a5522aa4b44d38b258 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Sun, 4 Jan 2015 15:11:49 +0100 Subject: [PATCH] BREED/PLANT/GROW are technically the same command, merge them. The new parser makes this easy. --- conf/keywords.json | 4 ++-- res/core/en/strings.xml | 6 ------ src/economy.c | 1 - src/kernel/order.c | 3 --- src/keyword.c | 1 - src/keyword.h | 1 - 6 files changed, 2 insertions(+), 14 deletions(-) diff --git a/conf/keywords.json b/conf/keywords.json index 3080a03c4..88ee6c2bd 100644 --- a/conf/keywords.json +++ b/conf/keywords.json @@ -1,6 +1,7 @@ { "keywords": { "en" : { + "grow": [ "GROW", "BREED", "PLANT" ], "combat": [ "COMBAT", "FIGHT" ] }, "de": { @@ -51,7 +52,7 @@ "cast": ["ZAUBERE", "ZAUBERN"], "show": ["ZEIGE", "ZEIGEN"], "destroy": ["ZERSTÖRE", "ZERSTÖREN"], - "grow": ["ZÜCHTE", "ZÜCHTEN"], + "grow": ["ZÜCHTE", "PFLANZE", "ZÜCHTEN", "PFLANZEN"], "default": "DEFAULT", "origin": "URSPRUNG", "email": "EMAIL", @@ -59,7 +60,6 @@ "group": "GRUPPE", "sort": ["SORTIERE", "SORTIEREN"], "prefix": "PRÄFIX", - "plant": ["PFLANZE", "PFLANZEN"], "alliance": "ALLIANZ", "claim": ["BEANSPRUCHE", "BEANSPRUCHEN"], "promote": ["BEFÖRDERE", "BEFÖRDERUNG"], diff --git a/res/core/en/strings.xml b/res/core/en/strings.xml index 71681ec44..e68915f06 100644 --- a/res/core/en/strings.xml +++ b/res/core/en/strings.xml @@ -1496,9 +1496,6 @@ PAY - - PLANT - PIRACY @@ -1568,9 +1565,6 @@ DESTROY - - GROW - loot diff --git a/src/economy.c b/src/economy.c index 4ac4210fe..886f2a210 100644 --- a/src/economy.c +++ b/src/economy.c @@ -3270,7 +3270,6 @@ void produce(struct region *r) sabotage_cmd(u, u->thisorder); break; - case K_PLANT: case K_BREED: breed_cmd(u, u->thisorder); break; diff --git a/src/kernel/order.c b/src/kernel/order.c index 4126c4a03..165769807 100644 --- a/src/kernel/order.c +++ b/src/kernel/order.c @@ -408,7 +408,6 @@ bool is_repeated(const order * ord) case K_TEACH: case K_BREED: case K_PIRACY: - case K_PLANT: case K_MAKE: case K_LOOT: case K_DESTROY: @@ -450,7 +449,6 @@ bool is_exclusive(const order * ord) case K_TEACH: case K_BREED: case K_PIRACY: - case K_PLANT: case K_MAKE: case K_LOOT: case K_DESTROY: @@ -495,7 +493,6 @@ bool is_long(const order * ord) case K_TEACH: case K_BREED: case K_PIRACY: - case K_PLANT: case K_MAKE: case K_LOOT: case K_DESTROY: diff --git a/src/keyword.c b/src/keyword.c index b4b181797..fde981bb9 100644 --- a/src/keyword.c +++ b/src/keyword.c @@ -138,7 +138,6 @@ const char *keywords[MAXKEYWORDS] = { "group", "sort", "prefix", - "plant", "alliance", "claim", "promote", diff --git a/src/keyword.h b/src/keyword.h index 24e47da51..b8094e74d 100644 --- a/src/keyword.h +++ b/src/keyword.h @@ -64,7 +64,6 @@ typedef enum { K_GROUP, K_SORT, K_PREFIX, - K_PLANT, K_ALLIANCE, K_CLAIM, K_PROMOTION,