Skip to content

Commit

Permalink
simplification
Browse files Browse the repository at this point in the history
  • Loading branch information
NBKelly committed Oct 8, 2024
1 parent 71a0516 commit 4633598
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
8 changes: 3 additions & 5 deletions src/clj/game/cards/resources.clj
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
[game.core.servers :refer [central->name is-central? is-remote?
protecting-same-server? remote->name target-server unknown->kw
zone->name zones->sorted-names]]
[game.core.set-aside :refer [set-aside get-set-aside set-aside-for-me]]
[game.core.set-aside :refer [set-aside set-aside-for-me]]
[game.core.shuffling :refer [shuffle!]]
[game.core.tags :refer [gain-tags lose-tags tag-prevent]]
[game.core.to-string :refer [card-str]]
Expand Down Expand Up @@ -3084,8 +3084,7 @@
{:cost-bonus -1
:no-toast true}))
(seq (:hosted card))))
:effect (req (set-aside state side eid (:hosted card))
(let [set-aside-cards (get-set-aside state side eid)]
:effect (req (let [set-aside-cards (set-aside state side eid (:hosted card))]
(wait-for (trash state side card {:cause :ability-cost :cause-card card})
(system-msg state side "trashed")
(continue-ability
Expand Down Expand Up @@ -3303,8 +3302,7 @@
:once-key :the-class-act-put-bottom
:async true
:effect
(req (set-aside-for-me state :runner eid (take (inc target) (:deck runner)))
(let [cards (get-set-aside state :runner eid)]
(req (let [cards (set-aside-for-me state :runner eid (take (inc target) (:deck runner)))]
(continue-ability
state side
{:waiting-prompt true
Expand Down
3 changes: 1 addition & 2 deletions src/clj/game/core/drawing.clj
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@
(effect-completed state side eid)
(let [to-draw (take draws-after-prevent (get-in @state [side :deck]))
set-aside-eid eid]
(set-aside-for-me state side set-aside-eid to-draw)
(let [drawn (get-set-aside state side set-aside-eid)
(let [drawn (set-aside-for-me state side set-aside-eid to-draw)
drawn-count (count drawn)]
(swap! state update-in [side :register :drawn-this-turn] (fnil #(+ % drawn-count) 0))
(if (not no-update-draw-stats)
Expand Down

0 comments on commit 4633598

Please sign in to comment.