Skip to content
48 changes: 29 additions & 19 deletions src/clj/game/cards/agendas.clj
Original file line number Diff line number Diff line change
Expand Up @@ -804,6 +804,7 @@
(defcard "Escalate Vitriol"
{:abilities [{:action true
:label "Gain 1 [Credit] for each Runner tag"
:change-in-game-state {:req (req tagged)}
:cost [(->c :click 1)]
:once :per-turn
:msg (msg "gain " (count-tags state) " [Credits]")
Expand Down Expand Up @@ -833,7 +834,7 @@
:effect (effect (gain-credits :corp eid 5))}}}})

(defcard "False Lead"
{:abilities [{:req (req (<= 2 (:click runner)))
{:abilities [{:change-in-game-state {:req (req (<= 2 (:click runner)))}
:label "runner loses [Click][Click]"
:msg "force the Runner to lose [Click][Click]"
:cost [(->c :forfeit-self)]
Expand Down Expand Up @@ -933,16 +934,16 @@
(defcard "Glenn Station"
{:abilities [{:action true
:label "Host a card from HQ"
:req (req (and (not-empty (:hand corp))
(empty? (filter corp? (:hosted card)))))
:change-in-game-state {:req (req (and (not-empty (:hand corp))
(empty? (filter corp? (:hosted card)))))}
:cost [(->c :click 1)]
:msg "host a card from HQ"
:prompt "Choose a card to host"
:choices {:card #(and (corp? %) (in-hand? %))}
:effect (effect (host card target {:facedown true}))}
{:action true
:label "Add a hosted card to HQ"
:req (req (not-empty (filter corp? (:hosted card))))
:change-in-game-state {:req (req (not-empty (filter corp? (:hosted card))))}
:cost [(->c :click 1)]
:msg "add a hosted card to HQ"
:prompt "Choose a hosted card"
Expand Down Expand Up @@ -994,19 +995,24 @@
:effect (effect (continue-ability (graft 1) card nil))}}))

(defcard "Hades Fragment"
{:flags {:corp-phase-12 (req (and (not-empty (get-in @state [:corp :discard]))
(is-scored? state :corp card)))}
:abilities [{:prompt "Choose a card to add to the bottom of R&D"
:label "add card to bottom of R&D"
:show-discard true
:choices {:card #(and (corp? %)
(in-discard? %))}
:effect (effect (move target :deck))
:msg (msg "add "
(if (:seen target)
(:title target)
"a card")
" to the bottom of R&D")}]})
(let [abi {:prompt "Choose a card to add to the bottom of R&D"
:label "add card to bottom of R&D"
:show-discard true
:event :corp-turn-begins
:once :per-turn
:choices {:card #(and (corp? %)
(in-discard? %))}
:effect (effect (move target :deck))
:msg (msg "add "
(if (:seen target)
(:title target)
"a card")
" to the bottom of R&D")}]
{:flags {:corp-phase-12 (req (and (seq (:discard corp))
(is-scored? state :corp card)))}
:abilities [abi]
:events [(assoc abi
:change-in-game-state {:req (req (seq (:discard corp))) :silent (req true)})]}))

(defcard "Helium-3 Deposit"
{:on-score
Expand All @@ -1029,6 +1035,7 @@
:silent (req true)}
:abilities [{:action true
:cost [(->c :click 1) (->c :agenda 1)]
:change-in-game-state {:req (req (pos? (:credit runner)))}
:label "gain credits"
:msg (msg "gain " (:credit runner) " [Credits]")
:async true
Expand Down Expand Up @@ -1203,7 +1210,7 @@
:effect (effect (add-counter eid card :power 2 nil))}
:interactions {:prevent [{:type #{:jack-out}
:req (req (pos? (get-counters card :power)))}]}
:abilities [{:req (req (:run @state))
:abilities [{:change-in-game-state {:req (req (:run @state))}
:cost [(->c :power 1)]
:msg "prevent the Runner from jacking out"
:effect (effect (jack-out-prevent))}]})
Expand Down Expand Up @@ -1452,7 +1459,7 @@
{:on-score {:silent (req true)
:async true
:effect (effect (add-counter eid card :agenda 1 nil))}
:abilities [{:req (req (:run @state))
:abilities [{:change-in-game-state {:req (req (:run @state))}
:cost [(->c :agenda 1)]
:msg "end the run"
:async true
Expand Down Expand Up @@ -1644,6 +1651,8 @@
:choices {:card #(and (ice? %)
(rezzed? %))}
:cost [(->c :agenda 1)]
:change-in-game-state {:req (req (and run (some (every-pred ice? rezzed?)
(all-installed state :corp))))}
:keep-menu-open :while-agenda-tokens-left
:msg (str "make a piece of ice gain \"[Subroutine] Do 1 net damage\" "
"after all its other subroutines for the remainder of the run")
Expand Down Expand Up @@ -2312,6 +2321,7 @@
:async true
:effect (effect (add-counter eid card :agenda 2 nil))}
:abilities [{:cost [(->c :agenda 1)]
:once :per-turn
:req (req run)
:msg "prevent this run from becoming successful"
:effect (effect (register-lingering-effect
Expand Down
11 changes: 8 additions & 3 deletions src/clj/game/cards/assets.clj
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@
:abilities [{:label "Install a non-agenda card from HQ"
:async true
:prompt "Choose a non-agenda card to install from HQ"
:change-in-game-state {:req (req (seq (:hand corp)))}
:req (req (not (:run @state)))
:choices {:card #(and (corp-installable-type? %)
(not (agenda? %))
Expand Down Expand Up @@ -312,8 +313,8 @@
:effect (req (wait-for (gain-credits state side 1)
(lose-credits state :runner eid 1)))}]})

(defcard "B-1001"
{:abilities [{:req (req (not this-server))
(defcard "B-1001" ;; note -> run restriction added by rules as errata
{:abilities [{:req (req (and run (not this-server)))
:async true
:cost [(->c :tag 1)]
:msg "end the run"
Expand Down Expand Up @@ -395,6 +396,7 @@
{:implementation "Timing restriction of ability use not enforced"
:abilities [{:label "Install 1 card, paying all costs"
:req (req (= (:active-player @state) :corp))
:change-in-game-state {:req (req (seq (:hand corp)))}
:prompt "Choose a card in HQ to install"
:choices {:card #(and (not (operation? %))
(in-hand? %)
Expand Down Expand Up @@ -818,7 +820,7 @@
:effect (effect (add-counter :corp eid card :credit 2 nil))}]
:abilities [{:label "Take all hosted credits"
:cost [(->c :trash-can)]
:req (req (pos? (get-counters card :credit)))
:change-in-game-state {:req (req (pos? (get-counters card :credit)))}
:msg (msg "gain " (get-counters card :credit) " [Credits]")
:async true
:effect (effect (gain-credits eid (get-counters card :credit)))}
Expand Down Expand Up @@ -1033,6 +1035,7 @@
:effect (effect (add-counter eid card :power 1 nil))}]
:abilities [{:label "Draw 1 card and gain 2 [Credits] for each hosted power counter"
:cost [(->c :trash-can)]
:change-in-game-state {:req (req (pos? (get-counters card :power)))}
:async true
:effect (req (let [counters (get-counters card :power)
credits (* 2 counters)]
Expand Down Expand Up @@ -1376,6 +1379,7 @@
:effect (effect (trash eid target {:cause-card card}))
:msg (msg "trash " (:title target) " from the grip")}))
choose-ability {:label "Trash 1 card in the grip of a named type"
:change-in-game-state {:req (req (seq (:hand runner))) :silent true}
:once :per-turn
:req (req (seq (:hand runner)))
:prompt "Choose a card type"
Expand Down Expand Up @@ -1518,6 +1522,7 @@
{:derezzed-events [corp-rez-toast]
:flags {:corp-phase-12 (req true)}
:abilities [{:msg "look at the top card of the stack"
:change-in-game-state {:req (req (seq (:deck runner)))}
:async true
:effect (effect (continue-ability
{:prompt (req (->> runner :deck first :title (str "The top card of the stack is ")))
Expand Down
Loading