Permalink
Browse files

battle-info split on max tickets/flags

  • Loading branch information...
dalkvist committed Mar 16, 2013
1 parent dae5d63 commit 3017510dd01302225fd9c0cea14ef5ccdaaf9fea
Showing with 7 additions and 1 deletion.
  1. +7 −1 src/bf3/info.clj
View
@@ -190,9 +190,15 @@
(partition-by :server)
(map #(sort-by :time (fn [t1 t2] (time/after? (time-format/parse t1) (time-format/parse t2))) %))
(mapcat #(partition-by
- (fn [b] (str (:gameId b) (:currentMap b) (:gameMode b) (:mapVariant b) (:vehicles b) (:mapMode b))) %)))))
+ (fn [b] (str (:gameId b) (:currentMap b) (:gameMode b) (:mapVariant b)
+ (:vehicles b) (:mapMode b)
+ (some (fn [[t s]] (apply = (vals (select-keys s [:max :current]))))
+ (:stats b)))) %))
+ (filter #(< 15 (count %))))))
(comment
+
+
(some (fn [[team score]]
(and (re-find #"conquest" (s/lower-case (str (:name b))))
(or (= 0 (:current score))

0 comments on commit 3017510

Please sign in to comment.