Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Apr 16th, 2013  |  syntax: None  |  size: 1.03 KB  |  views: 24  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. monitor_upper = env("MONITOR_UPPER", 0xf615)
  2. monitor_lower = env("MONITOR_LOWER", 0x7349)
  3.  
  4. monitor = data 0xFFFF
  5. keyboard = data 0xFFFF
  6. clock = data 0xFFFF
  7.  
  8. main:
  9.     A = 0
  10.  
  11. def once _detect:
  12.     J = 0
  13.     I = hardware_count()
  14.     while J < I:
  15.         hardware_query(J)
  16.         if A == monitor_upper and B == monitor_lower:
  17.             [monitor] = J
  18.         if A == keyboard_upper and B == keyboard_lower:
  19.             [keyboard] = J
  20.         if A == clock_upper  and B == clock_lower:
  21.             [clock] = J
  22.  
  23. def display_map_screen:
  24.     A = 0
  25.     _detect()
  26.     hardware_interrupt(monitor)
  27.  
  28. def display_map_font:
  29.     A = 1
  30.     _detect()
  31.     hardware_interrupt(monitor)
  32.  
  33. def display_map_palette:
  34.     A = 2
  35.     _detect()
  36.     hardware_interrupt(monitor)
  37.  
  38. def display_set_border_color:
  39.     A = 3
  40.     _detect()
  41.     hardware_interrupt(monitor)
  42.  
  43. def display_dump_font:
  44.     A = 4
  45.     _detect()
  46.     hardware_interrupt(monitor)
  47.  
  48.  
  49. def display_dump_palette:
  50.     A = 3
  51.     _detect()
  52.     hardware_interrupt(monitor)