summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--play.js6
-rw-r--r--rules.js4
2 files changed, 5 insertions, 5 deletions
diff --git a/play.js b/play.js
index d870438..cbac289 100644
--- a/play.js
+++ b/play.js
@@ -364,7 +364,7 @@ function create(t, p, ...c) {
function register_action(e, action, id) {
e.my_action = action
e.my_id = id
- e.onclick = on_click_action
+ e.onmousedown = on_click_action
}
function is_action(action, arg) {
@@ -580,7 +580,7 @@ function init_ui() {
my_id: id,
my_x_offset: x,
my_y_offset: y,
- onclick: on_click_action
+ onmousedown: on_click_action
})
document.getElementById("pieces").appendChild(e)
return e
@@ -1421,7 +1421,7 @@ function sub_card(match, p1) {
function sub_space(match, p1) {
let x = p1 | 0
let n = data.space_name[x]
- return `<span class="tip" onmouseenter="on_focus_space_tip(${x})" onmouseleave="on_blur_space_tip(${x})" onclick="on_click_space_tip(${x})">${n}</span>`
+ return `<span class="tip" onmouseenter="on_focus_space_tip(${x})" onmouseleave="on_blur_space_tip(${x})" onmousedown="on_click_space_tip(${x})">${n}</span>`
}
function on_log(text) {
diff --git a/rules.js b/rules.js
index 0a54d51..0ebc435 100644
--- a/rules.js
+++ b/rules.js
@@ -5458,7 +5458,7 @@ function goto_cultivate() {
states.cultivate = {
prompt() {
- view.prompt = "Cultivate: Select Department or City to place or relocate Base."
+ view.prompt = "Cultivate: Relocate Base to City or Department (or place if Rally Department)."
for (let s = first_pop; s <= last_pop; ++s)
if (can_cultivate_in_space(s))
gen_action_space(s)
@@ -5466,7 +5466,7 @@ states.cultivate = {
space(s) {
push_undo()
game.sa.where = s
- if (is_selected_op_space(s) && game.op.type === "Rally") {
+ if (is_selected_op_space(s) && is_dept(s) && game.op.type === "Rally") {
if (auto_place_piece(s, CARTELS, BASE)) {
log_space(game.sa.where, "Cultivate")
logi("Placed Cartels Base")