     (catch :default ex
       false)))
 
-;; Capture
-;; x check unit can capture
-;; x check base capturable
-;; x set state to capturing
-;; x set capture round
 
 (defn capture-tx
+  "Returns a transaction that sets the unit capturing flag and capture round."
   ([db game unit]
    (let [base (base-at db game (:unit/q unit) (:unit/r unit))
          round (:game/round game)]

      (and capturing (= capture-round (:game/round game)))
      (into (end-turn-capture-tx db game unit)))))

(defn end-turn-tx [db game]
  (let [starting-faction (qe '[:find ?f
                               :in $ ?g
                               :where

;; - add legal moves to frontier
;; - repeat with updated movement points + frontier

(defn teleport-tx [db game from-q from-r to-q to-r]
  (let [unit (checked-unit-at db game from-q from-r)]
    [{:db/id (e unit)
