; This defines the Paintown menu
; Encoded with UTF-8 

(menu
  (version 3 3 1)
  ; Using the space api
  (space absolute-space 0 0 640 480)
  (space relative-space -1 -1 1 1)
  ; (coordinate (space absolute-space 100 200 450 450)
  ;             (radius 15)
  ;             (z 0))
  ; (position ...) will be equivalent to (coordinate (space absolute-space ...))

  ; **Required** to name each menu, the top level menu is always named "main"
  (name main)
  ; **Required** Positioning of menu
  ; This is absolute placement of the menu list x | y | width | height
  ;(position 100 200 450 250)
  ; This is using the relative coordinate system ranging from -1 through 1:  x1 | y1 | x2 | y2  
  ;(relative-position -.6 -.3 .6 .8)
  ; Two methods of using the coordinate option and effecting the roundness of corners with radius
  ; Currently z is unused
  (coordinate (absolute 100 200 450 250) (radius 15) (z 0))
  ;(coordinate (relative -.6 -.3 .6 .8) (radius 5) (z 0))
  ; **Optional** This is body color of above menu red | blue | green | alpha
  (position-body 0 0 0 128)
  ; **Optional** This is border color of above menu red | blue | green | alpha
  (position-border 200 200 200 255)
  ; **Optional** This is the fade speed of the appearing menus, default at 12
  (fade-speed 12)
  ; **Optional** for the toplevel menu "main"
  ; 		 If there is no bitmap specified then the clear-color will be used instead
  ;		 Note that if the top level menu has a bitmap then subsequent menus will utilize that if there is none declared in the menu.
  ;(background menu/paintown.png)
  ; **Optional** Clear color for the background in case there is no background defined defaults to black (0,0,0)
  (clear-color 0 0 0)
  ; **Optional** The option info text placement defaults to 0 -0.5
  ; location centered on the x and y coordinate
  (info-position 0, -.5)
  ; ** Optional** menu info text
  (menuinfo "Main Menu")
  ; **optional** The menu info text placement if menu info text is set defaults to 0 .95
  ; location centered on the x and y coordinate
  (menuinfo-position 0, .95)
  ; **Optional** to use music
  (music music/aqua.s3m)
  ; **Optional** to use a sound for menu item selection
  (select-sound menu/sounds/menu-select.wav)
  (back-sound menu/sounds/menu-back.wav)
  (ok-sound menu/sounds/menu-ok.wav)
  ; **Optional** Set default gamespeed
  (action (fixedspeed 1.0))
  ; **Optional** Font name and size (default /fonts/arial.ttf 24 24) 
  ; (font "fonts/arial.ttf" 24 24)
  (font "fonts/Neuropol.ttf" 24 24)
  ; Main options which are basically optional
  ; Each mode will have be similar to this
  (option
    (adventure
      ; ** Each option is required to have a name!
      (name
        (language "English" "Adventure Mode")
        (language "Русский" "Режим Приключение")
        (language "Español" "Modo Aventura")
        (language "Deutsch" "Abenteuer-Modus"))
      ; ** Optional** This is a popup with information regarding the selected item
      ; Place text
      ; location is optional which is centered on the x and y coordinate and overwrites info-position in the main menu
      (info
        (language "English" "Play through an adventure yourself")
        (language "Русский" "Играть в режиме Приключение в одиночку")
        (language "Español" "Juega a través de una aventura solo")
        (language "Deutsch" "Ein Abenteuer alleine spielen")
        )))
  (option
    (adventure-cpu
      (name
        (language "English" "Adventure Mode with computer")
        (language "Русский" "Играть в Режиме Приключение с компьютером")
        (language "Deutsch" "Abenteuer-Modus mit dem Computer")
        (language "Español" "El modo Aventura con la computadora"))
      (info
        (language "English" "Play through an adventure with\nthe computers help")
        (language "Русский" "Играть в режиме Приключение в команде с компьютером")
        (language "Deutsch" "Ein Abenteuer mit Hilfe\ndes Computers spielen")
        (language "Español" "Juega a través de una aventura\ncon la ayuda de la computadora")
        )))
  ; Write more menus
  ;@
  (option
    (menu
      (name "Versus Mode")
      (select-sound menu/sounds/menu-select.wav)
      (back-sound menu/sounds/menu-back.wav)
      (ok-sound menu/sounds/menu-ok.wav)
      (position 100 300 450 100)
      ; **Optional** This is body color of above menu red | blue | green | alpha
      (position-body 0 0 0 128)
      ; **Optional** This is border color of above menu red | blue | green | alpha
      (position-border 200 200 200 255)
      ;(anim (location 0) (image 0 "menu/paintown.png") (velocity -.001 0) (frame (image 0) (time -1)))
      (option
        (versus
          (name
            (language "English" "Player Vs. Player")
            (language "Deutsch" "Spieler gegen Spieler")
            (language "Español" "Jugador contra Jugador"))
          (human)))
      ; cpu is default so essentially it's not needed, but is shown here for clarity
      (option
        (versus
          (name
            (language "English" "Player Vs. Computer")
            (language "Deutsch" "Spieler gegen Computer")
            (language "Español" "Jugador contra Computadora"))
          (cpu)))
      (info
        (language "English" "Play a 1 on 1 fight")
        (language "Deutsch" "Einen 1-gegen-1-Kampf spielen")
        (language "Español" "Juega 1 por 1 pelea"))))
  ; a submenu can be created inline
  (option
    (change-mod
      (name
        (language "English" "Change mod")
        (language "Deutsch" "Mod wechseln")
        (language "Русский" "Внешний вид")
        (language "Español" "Cambia mod"))
      (info
        (language "English" "Switch to a different game mod")
        (language "Русский" "Изменить внешний вид игры")
        (language "Deutsch" "Zu einem anderen Mod umschalten")
        (language "Español" "Cambia a differente mod"))))
  (option
    (network-host
      (name "Network - Host")
      (info "Host a game that can be\nplayed over the internet")))
  (option
    (network-join
      (name
        (language "English" "Network - Join")
        (language "Русский" "Сеть - присоединится")
        (language "Deutsch" "Netzwerkspiel beitreten")
        (language "Español" "Network - Join"))
      (info
        (language "English" "Join a game over the internet")
        (language "Русский" "Присоединится к игре через интернет")
        (language "Deutsch" "Einem Netzwerkspiel übers Internet beitreten")
        (language "Español" "Join a game over the internet"))))
  
  ; And submenu can also be created via another file
  (option (menu menu/options.txt))
  (option
    (credits
      (name
        (language "English" Credits)
        (language "Русский" "Разработчики")
        (language "Deutsch" "Credits")
        (language "Español" Creditos))
      (info
        (language "English" "See who did what on Paintown")
        (language "Русский" "Посмотреть список разработчиков Paintown")
        (language "Deutsch" "Anzeigen, wer wie zu Paintown beigetragen hat")
        (language "Español" "Ve quien lo hacieron que en Paintown"))
      ; set music
      (music music/kilimanz.mod)
      ; Optional else you'll have a black background
      (background menu/paintown.png)
      ; Optional to set colors of fonts
      ; This is the first word
      (titlecolor 0 255 255)
      ; This is the rest of the text
      (color 255 255 255)
      ; This adds additional credits to the static ones included with the game
      (additional "Additional thanks")
      (additional "Paintown logo by Mark Oates")
      (additional "Elecbyte")
      (additional "Senile Team")))
  ; Added a test menu, that gets ommited
  ; (option (menu (name Test)(info Test)(position 120 200 400 130)(position-body 0 0 0 192)(position-border 200 200 200 255)))
  
  ; This is a M.U.G.E.N. Menu currently in testing
  (option 
    (mugen 
  	(name "M.U.G.E.N. mode")
        ; This is optional gives you more flexibility otherwise it is pulled from mugen.cfg
  	; (motif "data/kfm/system.def")
    ; (motif "data/mt3/system.def")
  	(motif "data/system.def")
    ; (motif "data/db/data/system.def")
  	(info "M.U.G.E.N. Menu")))

  (option
    (quit
      (name
        (language "English" "Quit")
        (language "Русский" "Выход")
        (language "Deutsch" "Beenden")
        (language "Español" "Salir"))
      (info
        (language "English" "Exit the game")
        (language "Русский" "Закрыть игру")
        (language "Deutsch" "Beendet das Spiel")
        (language "Español" "Terminar el juego"))))
  ; Two Example animations for use in menus
  ; Animations can be used in options as well but they require to be name "option-anim" instead of "anim", they will be updated and ran only when the option is selected
  ; to get a better understanding of the useage of the animation, look at menu_animation.cpp about info
  ;
  ; scroll main menu background in foreground with alpha
  (anim
    (location 0)
    (image 0 "menu/paintown.png")
    (velocity -.001 0)
    (frame
      (image 0)
      (time -1)))
  ;@
  (anim (location 1) (image 0 "menu/paintown.png") (window 0 0 0 -300) (velocity -.5 0) (frame (image 0) (alpha 25) (time -1)))
  ;
  ; this renders images and fades in and out within the main menu box
  ;@
  (anim
    (id 0)
    (location 0)
    (basedir "menu/bgs/seizure-bg/")
    (velocity -.0015 -.0015)
    (image 0 "00200000.png")
    (image 1 "00200001.png")
    (image 2 "00200002.png")
    (image 3 "00200003.png")
    (image 4 "00200004.png")
    (image 5 "00200005.png")
    (image 6 "00200006.png")
    (image 7 "00200007.png")
    (image 8 "00200008.png")
    (image 9 "00200009.png")
    (image 10 "00200010.png")
    (image 11 "00200011.png")
    (image 12 "00200012.png")
    (image 13 "00200013.png")
    (axis .06 .70)
    (reset 1)
    (window -.325 -.89 .3 .18) 
    (frame (image 0) (alpha 0) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 1) (alpha 15) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 2) (alpha 30) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 3) (alpha 45) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 4) (alpha 60) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 5) (alpha 75) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 6) (alpha 90) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 7) (alpha 105) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 8) (alpha 120) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 9) (alpha 135) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 10) (alpha 150) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 11) (alpha 175) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 12) (alpha 190) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 13) (alpha 200) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 0) (alpha 190) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 1) (alpha 175) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 2) (alpha 150) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 3) (alpha 135) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 4) (alpha 120) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 5) (alpha 105) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 6) (alpha 90) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 7) (alpha 75) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 8) (alpha 60) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 9) (alpha 45) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 10) (alpha 30) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 11) (alpha 15) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 12) (alpha 5) (offset 0 0) (hflip 0) (vflip 0) (time 5))
    (frame (image 13) (alpha 0) (offset 0 0) (hflip 0) (vflip 0) (time 5)))
  )
