Mercurial > vba-clojure
comparison clojure/com/aurellem/gb/items.clj @ 161:cd7979aa544e
emabled setting pokemon moves and PP
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Tue, 20 Mar 2012 17:13:12 -0500 |
parents | 412ca096a9ba |
children | 8665160f0f3d |
comparison
equal
deleted
inserted
replaced
160:9ca350a476f0 | 161:cd7979aa544e |
---|---|
210 | 210 |
211 | 211 |
212 (defn set-inventory [^SaveState state new-inventory] | 212 (defn set-inventory [^SaveState state new-inventory] |
213 (set-inv-mem state (inventory-codes new-inventory))) | 213 (set-inv-mem state (inventory-codes new-inventory))) |
214 | 214 |
215 (defn give | 215 (defn give-items |
216 ([^SaveState state items] | 216 ([^SaveState state items] |
217 (set-inventory state | 217 (set-inventory state |
218 (concat items (inventory state)))) | 218 (concat items (inventory state)))) |
219 ([items] | 219 ([items] |
220 (give @current-state items))) | 220 (give-items @current-state items))) |
221 | 221 |
222 (defn clear-inventory | 222 (defn clear-inventory |
223 ([^SaveState state] | 223 ([^SaveState state] |
224 (set-inventory state [])) | 224 (set-inventory state [])) |
225 ([] (clear-inventory @current-state))) | 225 ([] (clear-inventory @current-state))) |