comparison org/rom.org @ 371:b477970d0b7a

Added more sandbox stuff in rom.org to show how the memory is laid out.
author Dylan Holmes <ocsenave@gmail.com>
date Mon, 09 Apr 2012 01:40:26 -0500
parents 5aabbe326eb0
children 998702f021e3
comparison
equal deleted inserted replaced
370:5aabbe326eb0 371:b477970d0b7a
73 73
74 *** See the data 74 *** See the data
75 75
76 Here you can see the raw data in three stages: in the first stage, we 76 Here you can see the raw data in three stages: in the first stage, we
77 just grab the first few bytes starting from position 0xE8000. In the 77 just grab the first few bytes starting from position 0xE8000. In the
78 second stage, we partition it into ten-letter chunks to show you 78 second stage, we partition the bytes into ten-letter chunks to show you
79 where the names begin and end. In the final stage, we convert each 79 where the names begin and end. In the final stage, we convert each
80 byte into the letter it represents using the =character-codes->str= 80 byte into the letter it represents using the =character-codes->str=
81 function. (0x50 is rendered as the symbol \ldquo{} =#= \rdquo{} for 81 function. (0x50 is rendered as the symbol \ldquo{} =#= \rdquo{} for
82 ease of reading). 82 ease of reading).
83 83
84 #+begin_src clojure :exports both :cache no :results output 84 #+begin_src clojure :exports both :cache no :results output
85 (ns com.aurellem.gb.hxc 85 (ns com.aurellem.gb.hxc
86 (:use (com.aurellem.gb assembly characters gb-driver util mem-util 86 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
87 constants)) 87 constants))
88 (:import [com.aurellem.gb.gb_driver SaveState])) 88 (:import [com.aurellem.gb.gb_driver SaveState]))
89
89 90
90 (println (take 100 (drop 0xE8000 (rom)))) 91 (println (take 100 (drop 0xE8000 (rom))))
91 92
92 (println (partition 10 (take 100 (drop 0xE8000 (rom))))) 93 (println (partition 10 (take 100 (drop 0xE8000 (rom)))))
93 94
155 #+begin_src clojure 156 #+begin_src clojure
156 (defn hxc-pokemon-base 157 (defn hxc-pokemon-base
157 ([] (hxc-pokemon-base com.aurellem.gb.gb-driver/original-rom)) 158 ([] (hxc-pokemon-base com.aurellem.gb.gb-driver/original-rom))
158 ([rom] 159 ([rom]
159 (let [entry-size 28 160 (let [entry-size 28
160 pkmn-count (count (hxc-pokedex-text rom)) 161
161 pokemon (rest (hxc-pokedex-names)) 162 pokemon (rest (hxc-pokedex-names))
163 pkmn-count (inc(count pokemon))
162 types (apply assoc {} 164 types (apply assoc {}
163 (interleave 165 (interleave
164 (range) 166 (range)
165 pkmn-types)) ;;!! softcoded 167 pkmn-types)) ;;!! softcoded
166 moves (apply assoc {} 168 moves (apply assoc {}
555 ** COMMENT Names of permanent stats 557 ** COMMENT Names of permanent stats
556 0DD4D-DD72 558 0DD4D-DD72
557 559
558 * Items 560 * Items
559 ** Item names 561 ** Item names
562
563 *** See the data
564 #+begin_src clojure :exports both :results output
565 (ns com.aurellem.gb.hxc
566 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
567 constants))
568 (:import [com.aurellem.gb.gb_driver SaveState]))
569
570 (println (take 100 (drop 0x045B7 (rom))))
571
572 (println
573 (partition-by
574 (partial = 0x50)
575 (take 100 (drop 0x045B7 (rom)))))
576
577 (println
578 (map character-codes->str
579 (partition-by
580 (partial = 0x50)
581 (take 100 (drop 0x045B7 (rom))))))
582
583
584 #+end_src
585
586 #+results:
587 : (140 128 146 147 132 145 127 129 128 139 139 80 148 139 147 145 128 127 129 128 139 139 80 134 145 132 128 147 127 129 128 139 139 80 143 142 138 186 127 129 128 139 139 80 147 142 150 141 127 140 128 143 80 129 136 130 152 130 139 132 80 230 230 230 230 230 80 146 128 133 128 145 136 127 129 128 139 139 80 143 142 138 186 131 132 151 80 140 142 142 141 127 146 147 142 141 132 80 128 141)
588 : ((140 128 146 147 132 145 127 129 128 139 139) (80) (148 139 147 145 128 127 129 128 139 139) (80) (134 145 132 128 147 127 129 128 139 139) (80) (143 142 138 186 127 129 128 139 139) (80) (147 142 150 141 127 140 128 143) (80) (129 136 130 152 130 139 132) (80) (230 230 230 230 230) (80) (146 128 133 128 145 136 127 129 128 139 139) (80) (143 142 138 186 131 132 151) (80) (140 142 142 141 127 146 147 142 141 132) (80) (128 141))
589 : (MASTER BALL # ULTRA BALL # GREAT BALL # POKé BALL # TOWN MAP # BICYCLE # ????? # SAFARI BALL # POKéDEX # MOON STONE # AN)
590
591 *** Automatically grab the data
560 #+name: item-names 592 #+name: item-names
561 #+begin_src clojure 593 #+begin_src clojure
562 594
563 (def hxc-items-raw 595 (def hxc-items-raw
564 "The hardcoded names of the items in memory. List begins at 596 "The hardcoded names of the items in memory. List begins at
570 keywords. List begins at ROM@045B7. See also, hxc-items-raw." 602 keywords. List begins at ROM@045B7. See also, hxc-items-raw."
571 (comp (partial map format-name) hxc-items-raw)) 603 (comp (partial map format-name) hxc-items-raw))
572 #+end_src 604 #+end_src
573 605
574 ** Item prices 606 ** Item prices
607
608 ***
609 #+begin_src clojure :exports both :results output
610 (ns com.aurellem.gb.hxc
611 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
612 constants))
613 (:import [com.aurellem.gb.gb_driver SaveState]))
614
615 (println (take 90 (drop 0x4495 (rom))))
616
617 (println
618 (partition 3
619 (take 90 (drop 0x4495 (rom)))))
620
621 (println
622 (partition 3
623 (map hex
624 (take 90 (drop 0x4495 (rom))))))
625
626 (println
627 (map decode-bcd
628 (map butlast
629 (partition 3
630 (take 90 (drop 0x4495 (rom)))))))
631
632 (println
633 (map
634 vector
635 (hxc-items (rom))
636 (map decode-bcd
637 (map butlast
638 (partition 3
639 (take 90 (drop 0x4495 (rom))))))))
640
641
642
643
644
645 #+end_src
646
647 #+results:
648 : (0 0 0 18 0 0 6 0 0 2 0 0 0 0 0 0 0 0 0 0 0 16 0 0 0 0 0 0 0 0 1 0 0 2 80 0 2 80 0 2 0 0 2 0 0 48 0 0 37 0 0 21 0 0 7 0 0 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 5 80 0 3 80 0)
649 : ((0 0 0) (18 0 0) (6 0 0) (2 0 0) (0 0 0) (0 0 0) (0 0 0) (16 0 0) (0 0 0) (0 0 0) (1 0 0) (2 80 0) (2 80 0) (2 0 0) (2 0 0) (48 0 0) (37 0 0) (21 0 0) (7 0 0) (3 0 0) (0 0 0) (0 0 0) (0 0 0) (0 0 0) (0 0 0) (0 0 0) (0 0 0) (0 0 0) (5 80 0) (3 80 0))
650 : ((0x0 0x0 0x0) (0x12 0x0 0x0) (0x6 0x0 0x0) (0x2 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x10 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x1 0x0 0x0) (0x2 0x50 0x0) (0x2 0x50 0x0) (0x2 0x0 0x0) (0x2 0x0 0x0) (0x30 0x0 0x0) (0x25 0x0 0x0) (0x15 0x0 0x0) (0x7 0x0 0x0) (0x3 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x0 0x0 0x0) (0x5 0x50 0x0) (0x3 0x50 0x0))
651 : (0 1200 600 200 0 0 0 1000 0 0 100 250 250 200 200 3000 2500 1500 700 300 0 0 0 0 0 0 0 0 550 350)
652 : ([:master-ball 0] [:ultra-ball 1200] [:great-ball 600] [:poké-ball 200] [:town-map 0] [:bicycle 0] [:????? 0] [:safari-ball 1000] [:pokédex 0] [:moon-stone 0] [:antidote 100] [:burn-heal 250] [:ice-heal 250] [:awakening 200] [:parlyz-heal 200] [:full-restore 3000] [:max-potion 2500] [:hyper-potion 1500] [:super-potion 700] [:potion 300] [:boulderbadge 0] [:cascadebadge 0] [:thunderbadge 0] [:rainbowbadge 0] [:soulbadge 0] [:marshbadge 0] [:volcanobadge 0] [:earthbadge 0] [:escape-rope 550] [:repel 350])
653
654
655 ***
575 #+name: item-prices 656 #+name: item-prices
576 #+begin_src clojure 657 #+begin_src clojure
577 (defn hxc-item-prices 658 (defn hxc-item-prices
578 "The hardcoded list of item prices in memory. List begins at ROM@4495" 659 "The hardcoded list of item prices in memory. List begins at ROM@4495"
579 ([] (hxc-item-prices com.aurellem.gb.gb-driver/original-rom)) 660 ([] (hxc-item-prices com.aurellem.gb.gb-driver/original-rom))
633 714
634 715
635 716
636 * Types 717 * Types
637 ** Names of types 718 ** Names of types
719 ***
720 #+begin_src clojure :exports both :results output
721 (ns com.aurellem.gb.hxc
722 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
723 constants))
724 (:import [com.aurellem.gb.gb_driver SaveState]))
725
726 (println (take 90 (drop 0x27D99 (rom))))
727
728 (println
729 (partition-by (partial = 0x50)
730 (take 90 (drop 0x27D99 (rom)))))
731
732 (println
733 (map character-codes->str
734 (partition-by (partial = 0x50)
735 (take 90 (drop 0x27D99 (rom))))))
736
737 #+end_src
738
739 #+results:
740 : (141 142 145 140 128 139 80 133 136 134 135 147 136 141 134 80 133 139 152 136 141 134 80 143 142 136 146 142 141 80 133 136 145 132 80 150 128 147 132 145 80 134 145 128 146 146 80 132 139 132 130 147 145 136 130 80 143 146 152 130 135 136 130 80 136 130 132 80 134 145 142 148 141 131 80 145 142 130 138 80 129 136 145 131 80 129 148 134 80 134)
741 : ((141 142 145 140 128 139) (80) (133 136 134 135 147 136 141 134) (80) (133 139 152 136 141 134) (80) (143 142 136 146 142 141) (80) (133 136 145 132) (80) (150 128 147 132 145) (80) (134 145 128 146 146) (80) (132 139 132 130 147 145 136 130) (80) (143 146 152 130 135 136 130) (80) (136 130 132) (80) (134 145 142 148 141 131) (80) (145 142 130 138) (80) (129 136 145 131) (80) (129 148 134) (80) (134))
742 : (NORMAL # FIGHTING # FLYING # POISON # FIRE # WATER # GRASS # ELECTRIC # PSYCHIC # ICE # GROUND # ROCK # BIRD # BUG # G)
743
744
745 ***
638 #+name: type-names 746 #+name: type-names
639 #+begin_src clojure 747 #+begin_src clojure
640 (def hxc-types 748 (def hxc-types
641 "The hardcoded type names in memory. List begins at ROM@27D99, 749 "The hardcoded type names in memory. List begins at ROM@27D99,
642 shortly before hxc-titles." 750 shortly before hxc-titles."
643 (hxc-thunk-words 0x27D99 102)) 751 (hxc-thunk-words 0x27D99 102))
644 752
645 #+end_src 753 #+end_src
646 754
647 ** Type effectiveness 755 ** Type effectiveness
756 ***
757 #+begin_src clojure :exports both :results output
758 (ns com.aurellem.gb.hxc
759 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
760 constants))
761 (:import [com.aurellem.gb.gb_driver SaveState]))
762
763
764 ;; POKEMON TYPES
765
766 (println pkmn-types) ;; these are the pokemon types
767 (println (map vector (range) pkmn-types)) ;; each type has an id number.
768
769 (newline)
770
771
772
773
774 ;;; TYPE EFFECTIVENESS
775
776 (println (take 15 (drop 0x3E62D (rom))))
777 (println (partition 3 (take 15 (drop 0x3E62D (rom)))))
778
779 (println
780 (map
781 (fn [[atk-type def-type multiplier]]
782 (list atk-type def-type (/ multiplier 10.)))
783
784 (partition 3
785 (take 15 (drop 0x3E62D (rom))))))
786
787
788 (println
789 (map
790 (fn [[atk-type def-type multiplier]]
791 [
792 (get pkmn-types atk-type)
793 (get pkmn-types def-type)
794 (/ multiplier 10.)
795 ])
796
797 (partition 3
798 (take 15 (drop 0x3E62D (rom))))))
799
800 #+end_src
801
802 #+results:
803 : [:normal :fighting :flying :poison :ground :rock :bird :bug :ghost :A :B :C :D :E :F :G :H :I :J :K :fire :water :grass :electric :psychic :ice :dragon]
804 : ([0 :normal] [1 :fighting] [2 :flying] [3 :poison] [4 :ground] [5 :rock] [6 :bird] [7 :bug] [8 :ghost] [9 :A] [10 :B] [11 :C] [12 :D] [13 :E] [14 :F] [15 :G] [16 :H] [17 :I] [18 :J] [19 :K] [20 :fire] [21 :water] [22 :grass] [23 :electric] [24 :psychic] [25 :ice] [26 :dragon])
805 :
806 : (0 5 5 0 8 0 8 8 20 20 7 20 20 5 5)
807 : ((0 5 5) (0 8 0) (8 8 20) (20 7 20) (20 5 5))
808 : ((0 5 0.5) (0 8 0.0) (8 8 2.0) (20 7 2.0) (20 5 0.5))
809 : ([:normal :rock 0.5] [:normal :ghost 0.0] [:ghost :ghost 2.0] [:fire :bug 2.0] [:fire :rock 0.5])
810
811
812 ***
648 #+name: type-advantage 813 #+name: type-advantage
649 #+begin_src clojure 814 #+begin_src clojure
650 (defn hxc-advantage 815 (defn hxc-advantage
651 ;; in-game multipliers are stored as 10x their effective value 816 ;; in-game multipliers are stored as 10x their effective value
652 ;; to allow for fractional multipliers like 1/2 817 ;; to allow for fractional multipliers like 1/2
667 832
668 833
669 834
670 * Moves 835 * Moves
671 ** Names of moves 836 ** Names of moves
837 *** See the data
838 #+begin_src clojure :exports both :results output
839 (ns com.aurellem.gb.hxc
840 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
841 constants))
842 (:import [com.aurellem.gb.gb_driver SaveState]))
843
844 (println (take 100 (drop 0xBC000 (rom))))
845
846 (println
847 (partition-by
848 (partial = 0x50)
849 (take 100 (drop 0xBC000 (rom)))))
850
851 (println
852 (map character-codes->str
853 (partition-by
854 (partial = 0x50)
855 (take 100 (drop 0xBC000 (rom))))))
856
857
858 #+end_src
859
860 #+results:
861 : (143 142 148 141 131 80 138 128 145 128 147 132 127 130 135 142 143 80 131 142 148 129 139 132 146 139 128 143 80 130 142 140 132 147 127 143 148 141 130 135 80 140 132 134 128 127 143 148 141 130 135 80 143 128 152 127 131 128 152 80 133 136 145 132 127 143 148 141 130 135 80 136 130 132 127 143 148 141 130 135 80 147 135 148 141 131 132 145 143 148 141 130 135 80 146 130 145 128 147 130)
862 : ((143 142 148 141 131) (80) (138 128 145 128 147 132 127 130 135 142 143) (80) (131 142 148 129 139 132 146 139 128 143) (80) (130 142 140 132 147 127 143 148 141 130 135) (80) (140 132 134 128 127 143 148 141 130 135) (80) (143 128 152 127 131 128 152) (80) (133 136 145 132 127 143 148 141 130 135) (80) (136 130 132 127 143 148 141 130 135) (80) (147 135 148 141 131 132 145 143 148 141 130 135) (80) (146 130 145 128 147 130))
863 : (POUND # KARATE CHOP # DOUBLESLAP # COMET PUNCH # MEGA PUNCH # PAY DAY # FIRE PUNCH # ICE PUNCH # THUNDERPUNCH # SCRATC)
864
865 *** Automatically grab the data
866
672 #+name: move-names 867 #+name: move-names
673 #+begin_src clojure 868 #+begin_src clojure
674 (def hxc-move-names 869 (def hxc-move-names
675 "The hardcoded move names in memory. List begins at ROM@BC000" 870 "The hardcoded move names in memory. List begins at ROM@BC000"
676 (hxc-thunk-words 0xBC000 1551)) 871 (hxc-thunk-words 0xBC000 1551))
741 (drop 0x38000 rom)))))))) 936 (drop 0x38000 rom))))))))
742 937
743 #+end_src 938 #+end_src
744 939
745 ** TM and HM moves 940 ** TM and HM moves
746 941 ***
942 #+begin_src clojure :exports both :results output
943 (ns com.aurellem.gb.hxc
944 (:use (com.aurellem.gb assembly characters gb-driver util mem-util
945 constants))
946 (:import [com.aurellem.gb.gb_driver SaveState]))
947
948
949 (println (hxc-move-names))
950 (println (map vector (rest(range)) (hxc-move-names)))
951
952 (newline)
953
954 (println (take 55 (drop 0x1232D (rom))))
955
956 (println
957 (interpose "."
958 (map
959 (zipmap (rest (range)) (hxc-move-names))
960 (take 55 (drop 0x1232D (rom))))))
961
962 #+end_src
963
964 #+results:
965 : (POUND KARATE CHOP DOUBLESLAP COMET PUNCH MEGA PUNCH PAY DAY FIRE PUNCH ICE PUNCH THUNDERPUNCH SCRATCH VICEGRIP GUILLOTINE RAZOR WIND SWORDS DANCE CUT GUST WING ATTACK WHIRLWIND FLY BIND SLAM VINE WHIP STOMP DOUBLE KICK MEGA KICK JUMP KICK ROLLING KICK SAND-ATTACK HEADBUTT HORN ATTACK FURY ATTACK HORN DRILL TACKLE BODY SLAM WRAP TAKE DOWN THRASH DOUBLE-EDGE TAIL WHIP POISON STING TWINEEDLE PIN MISSILE LEER BITE GROWL ROAR SING SUPERSONIC SONICBOOM DISABLE ACID EMBER FLAMETHROWER MIST WATER GUN HYDRO PUMP SURF ICE BEAM BLIZZARD PSYBEAM BUBBLEBEAM AURORA BEAM HYPER BEAM PECK DRILL PECK SUBMISSION LOW KICK COUNTER SEISMIC TOSS STRENGTH ABSORB MEGA DRAIN LEECH SEED GROWTH RAZOR LEAF SOLARBEAM POISONPOWDER STUN SPORE SLEEP POWDER PETAL DANCE STRING SHOT DRAGON RAGE FIRE SPIN THUNDERSHOCK THUNDERBOLT THUNDER WAVE THUNDER ROCK THROW EARTHQUAKE FISSURE DIG TOXIC CONFUSION PSYCHIC HYPNOSIS MEDITATE AGILITY QUICK ATTACK RAGE TELEPORT NIGHT SHADE MIMIC SCREECH DOUBLE TEAM RECOVER HARDEN MINIMIZE SMOKESCREEN CONFUSE RAY WITHDRAW DEFENSE CURL BARRIER LIGHT SCREEN HAZE REFLECT FOCUS ENERGY BIDE METRONOME MIRROR MOVE SELFDESTRUCT EGG BOMB LICK SMOG SLUDGE BONE CLUB FIRE BLAST WATERFALL CLAMP SWIFT SKULL BASH SPIKE CANNON CONSTRICT AMNESIA KINESIS SOFTBOILED HI JUMP KICK GLARE DREAM EATER POISON GAS BARRAGE LEECH LIFE LOVELY KISS SKY ATTACK TRANSFORM BUBBLE DIZZY PUNCH SPORE FLASH PSYWAVE SPLASH ACID ARMOR CRABHAMMER EXPLOSION FURY SWIPES BONEMERANG REST ROCK SLIDE HYPER FANG SHARPEN CONVERSION TRI ATTACK SUPER FANG SLASH SUBSTITUTE STRUGGLE)
966 : ([1 POUND] [2 KARATE CHOP] [3 DOUBLESLAP] [4 COMET PUNCH] [5 MEGA PUNCH] [6 PAY DAY] [7 FIRE PUNCH] [8 ICE PUNCH] [9 THUNDERPUNCH] [10 SCRATCH] [11 VICEGRIP] [12 GUILLOTINE] [13 RAZOR WIND] [14 SWORDS DANCE] [15 CUT] [16 GUST] [17 WING ATTACK] [18 WHIRLWIND] [19 FLY] [20 BIND] [21 SLAM] [22 VINE WHIP] [23 STOMP] [24 DOUBLE KICK] [25 MEGA KICK] [26 JUMP KICK] [27 ROLLING KICK] [28 SAND-ATTACK] [29 HEADBUTT] [30 HORN ATTACK] [31 FURY ATTACK] [32 HORN DRILL] [33 TACKLE] [34 BODY SLAM] [35 WRAP] [36 TAKE DOWN] [37 THRASH] [38 DOUBLE-EDGE] [39 TAIL WHIP] [40 POISON STING] [41 TWINEEDLE] [42 PIN MISSILE] [43 LEER] [44 BITE] [45 GROWL] [46 ROAR] [47 SING] [48 SUPERSONIC] [49 SONICBOOM] [50 DISABLE] [51 ACID] [52 EMBER] [53 FLAMETHROWER] [54 MIST] [55 WATER GUN] [56 HYDRO PUMP] [57 SURF] [58 ICE BEAM] [59 BLIZZARD] [60 PSYBEAM] [61 BUBBLEBEAM] [62 AURORA BEAM] [63 HYPER BEAM] [64 PECK] [65 DRILL PECK] [66 SUBMISSION] [67 LOW KICK] [68 COUNTER] [69 SEISMIC TOSS] [70 STRENGTH] [71 ABSORB] [72 MEGA DRAIN] [73 LEECH SEED] [74 GROWTH] [75 RAZOR LEAF] [76 SOLARBEAM] [77 POISONPOWDER] [78 STUN SPORE] [79 SLEEP POWDER] [80 PETAL DANCE] [81 STRING SHOT] [82 DRAGON RAGE] [83 FIRE SPIN] [84 THUNDERSHOCK] [85 THUNDERBOLT] [86 THUNDER WAVE] [87 THUNDER] [88 ROCK THROW] [89 EARTHQUAKE] [90 FISSURE] [91 DIG] [92 TOXIC] [93 CONFUSION] [94 PSYCHIC] [95 HYPNOSIS] [96 MEDITATE] [97 AGILITY] [98 QUICK ATTACK] [99 RAGE] [100 TELEPORT] [101 NIGHT SHADE] [102 MIMIC] [103 SCREECH] [104 DOUBLE TEAM] [105 RECOVER] [106 HARDEN] [107 MINIMIZE] [108 SMOKESCREEN] [109 CONFUSE RAY] [110 WITHDRAW] [111 DEFENSE CURL] [112 BARRIER] [113 LIGHT SCREEN] [114 HAZE] [115 REFLECT] [116 FOCUS ENERGY] [117 BIDE] [118 METRONOME] [119 MIRROR MOVE] [120 SELFDESTRUCT] [121 EGG BOMB] [122 LICK] [123 SMOG] [124 SLUDGE] [125 BONE CLUB] [126 FIRE BLAST] [127 WATERFALL] [128 CLAMP] [129 SWIFT] [130 SKULL BASH] [131 SPIKE CANNON] [132 CONSTRICT] [133 AMNESIA] [134 KINESIS] [135 SOFTBOILED] [136 HI JUMP KICK] [137 GLARE] [138 DREAM EATER] [139 POISON GAS] [140 BARRAGE] [141 LEECH LIFE] [142 LOVELY KISS] [143 SKY ATTACK] [144 TRANSFORM] [145 BUBBLE] [146 DIZZY PUNCH] [147 SPORE] [148 FLASH] [149 PSYWAVE] [150 SPLASH] [151 ACID ARMOR] [152 CRABHAMMER] [153 EXPLOSION] [154 FURY SWIPES] [155 BONEMERANG] [156 REST] [157 ROCK SLIDE] [158 HYPER FANG] [159 SHARPEN] [160 CONVERSION] [161 TRI ATTACK] [162 SUPER FANG] [163 SLASH] [164 SUBSTITUTE] [165 STRUGGLE])
967 :
968 : (5 13 14 18 25 92 32 34 36 38 61 55 58 59 63 6 66 68 69 99 72 76 82 85 87 89 90 91 94 100 102 104 115 117 118 120 121 126 129 130 135 138 143 156 86 149 153 157 161 164 15 19 57 70 148)
969 : (MEGA PUNCH . RAZOR WIND . SWORDS DANCE . WHIRLWIND . MEGA KICK . TOXIC . HORN DRILL . BODY SLAM . TAKE DOWN . DOUBLE-EDGE . BUBBLEBEAM . WATER GUN . ICE BEAM . BLIZZARD . HYPER BEAM . PAY DAY . SUBMISSION . COUNTER . SEISMIC TOSS . RAGE . MEGA DRAIN . SOLARBEAM . DRAGON RAGE . THUNDERBOLT . THUNDER . EARTHQUAKE . FISSURE . DIG . PSYCHIC . TELEPORT . MIMIC . DOUBLE TEAM . REFLECT . BIDE . METRONOME . SELFDESTRUCT . EGG BOMB . FIRE BLAST . SWIFT . SKULL BASH . SOFTBOILED . DREAM EATER . SKY ATTACK . REST . THUNDER WAVE . PSYWAVE . EXPLOSION . ROCK SLIDE . TRI ATTACK . SUBSTITUTE . CUT . FLY . SURF . STRENGTH . FLASH)
970
971
972 ***
747 #+name: machines 973 #+name: machines
748 #+begin_src clojure 974 #+begin_src clojure
749 (defn hxc-machines 975 (defn hxc-machines
750 "The hardcoded moves taught by TMs and HMs. List begins at ROM@1232D." 976 "The hardcoded moves taught by TMs and HMs. List begins at ROM@1232D."
751 ([] (hxc-machines 977 ([] (hxc-machines
925 1151
926 All the legitimate move effects are listed in the table 1152 All the legitimate move effects are listed in the table
927 below. Here are some notes for reading it: 1153 below. Here are some notes for reading it:
928 1154
929 - Whenever an effect has a chance of doing something (like a chance of 1155 - Whenever an effect has a chance of doing something (like a chance of
930 poisoning the opponent), I list the chance as a hexadecimal amount out of 256 to avoid rounding errors. To convert the hex amount into a percentage, divide by 256. 1156 poisoning the opponent), I list the chance as a hexadecimal amount
1157 out of 256; this is to avoid rounding errors. To convert the hex amount into a percentage, divide by 256.
931 - For some effects, the description is too cumbersome to 1158 - For some effects, the description is too cumbersome to
932 write. Instead, I just write a move name 1159 write. Instead, I just write a move name
933 in parentheses, like: (leech seed). That move gives a characteristic example 1160 in parentheses, like: (leech seed). That move gives a characteristic example
934 of the effect. 1161 of the effect.
935 - I use the abbreviations =atk=, =def=, =spd=, =spc=, =acr=, =evd= for 1162 - I use the abbreviations =atk=, =def=, =spd=, =spc=, =acr=, =evd= for
936 attack, defense, speed, special, accuracy, and evasion. 1163 attack, defense, speed, special, accuracy, and evasiveness.
937 . 1164 .
938 1165
939 1166
940 1167
941 | ID (hex) | Description | Notes | 1168 | ID (hex) | Description | Notes |