view clojure/com/aurellem/run/choreo.clj @ 539:a64485223afa

cleanup.
author Robert McIntyre <rlm@mit.edu>
date Mon, 25 Jun 2012 14:55:55 -0500
parents 3ebd321f198e
children 7f8030812ac2
line wrap: on
line source
1 (ns com.aurellem.run.choreo
2 (:use (com.aurellem.gb saves gb-driver util constants
3 items vbm characters money
4 rlm-assembly))
5 (:use (com.aurellem.run util music title save-corruption
6 bootstrap-0 bootstrap-1 image
7 ram-display))
8 (:require clojure.string)
9 (:import [com.aurellem.gb.gb_driver SaveState])
10 (:import java.io.File))
14 ;; take over game
15 ;; [X] silence noise
16 ;; [ ] construct writing/playing kernel
17 ;; [ ] play pony song while writing picture-program
18 ;; [ ] run picture program to display pinkie pie mark
20 (defn-memo silence-noise
21 ([] (silence-noise (launch-main-bootstrap-program)))
22 ([script]
23 (->> script
24 (write-RAM 0xFF1A [0 0 0]))))
26 (defn-memo write-pony-music-data
27 ([] (write-pony-music-data (silence-noise)))
28 ([script]
29 (let [bytes (midi-bytes pony-csv)]
30 (->> script
31 (write-RAM (:address (:voice-1 bytes))
32 (:data (:voice-1 bytes)))
33 (write-RAM (:address (:voice-2 bytes))
34 (:data (:voice-2 bytes)))
35 (write-RAM (:address (:noise bytes))
36 (:data (:noise bytes)))
37 (write-RAM (:address (:kernel bytes))
38 (:data (:kernel bytes)))
39 (transfer-control (:address (:kernel bytes)))))))