summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2023-10-06 13:29:28 +0200
committerTor Andersson <tor@ccxvii.net>2023-12-10 18:16:55 +0100
commit5b9785d5a91f8756ffe401ac2305d49fc378478a (patch)
treebd09ad67348ba9443c6b4d6dd45dcce46b78ee1a
parent21f293f689217f36e53ba00bc5da9300ad173bc2 (diff)
downloadplantagenet-5b9785d5a91f8756ffe401ac2305d49fc378478a.tar.gz
Remove useless semicolons.
-rw-r--r--play.js4
-rw-r--r--rules.js44
2 files changed, 23 insertions, 25 deletions
diff --git a/play.js b/play.js
index 06455a7..3ae1d61 100644
--- a/play.js
+++ b/play.js
@@ -372,14 +372,12 @@ function count_favour(type) {
for (let x = first_locale; x < last_locale; x++) {
if (data.locales[x].type !== type)
continue
-
if (view.pieces.favourl.includes(x))
n += 1
if (view.pieces.favoury.includes(x))
n -= 1
}
-
- return n;
+ return n
}
function is_vassal_ready(vassal) {
diff --git a/rules.js b/rules.js
index 1048dae..c07b8d1 100644
--- a/rules.js
+++ b/rules.js
@@ -3596,23 +3596,23 @@ function format_group_move() {
return ""
}
function prompt_march() {
- let from = get_lord_locale(game.command);
+ let from = get_lord_locale(game.command)
if (is_first_action())
for (let to of data.locales[from].adjacent_by_path) {
- gen_action_locale(to);
+ gen_action_locale(to)
}
if (game.actions > 0) {
for (let to of data.locales[from].adjacent_by_road) {
- gen_action_locale(to);
+ gen_action_locale(to)
}
for (let to of data.locales[from].adjacent_by_highway) {
- gen_action_locale(to);
+ gen_action_locale(to)
}
}
else if (game.actions === 0 && is_first_march_highway()) {
for (let to of data.locales[from].adjacent_by_highway) {
- gen_action_locale(to);
+ gen_action_locale(to)
}
}
@@ -4122,24 +4122,24 @@ function get_supply_from_source(source){
}
function get_supply_from_source(source) {
- let prov = 0;
+ let prov = 0
if (has_exhausted_marker(source)) {
- return prov;
+ return prov
}
if ((game.command === LORD_DEVON && (game.where === LOC_EXETER || game.where === LOC_LAUNCESTON || game.where === LOC_PLYMOUTH || game.where === LOC_WELLS || game.where === LOC_DOCHESTER))) {
- prov += 1;
+ prov += 1
}
if (source === LOC_LONDON || source === LOC_CALAIS) {
- prov += 3;
+ prov += 3
} else if (is_city(source)) {
- prov += 2;
+ prov += 2
}
- prov += 1;
- return prov;
+ prov += 1
+ return prov
}
@@ -4503,31 +4503,31 @@ states.sail = {
switch(true){
case data.exile_1.includes(here):
from = data.way_exile_1
- break;
+ break
case data.exile_2.includes(here):
from = data.way_exile_2
- break;
+ break
case data.exile_3.includes(here):
from = data.way_exile_3
- break;
+ break
case data.sea_1.includes(here):
from = data.way_sea_1
- break;
+ break
case data.sea_2.includes(here):
from = data.way_sea_2
- break;
+ break
case data.sea_3.includes(here):
from = data.way_sea_3
- break;
+ break
case data.port_1.includes(here):
from = data.way_port_1
- break;
+ break
case data.port_2.includes(here):
from = data.way_port_2
- break;
+ break
case data.port_3.includes(here):
from = data.way_port_3
- break;
+ break
}
for (let to of from) {
if (to === here)
@@ -7256,7 +7256,7 @@ function get_lords_at_sea() {
results.push(x)
}
}
- return results;
+ return results
}
function is_lord_at_sea(lord) {