Advertisement
Guest User

Untitled

a guest
Jul 27th, 2016
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.89 KB | None | 0 0
  1. ; ===========================================================================
  2. ; Colour test screen
  3. ; ===========================================================================
  4.  
  5. Load_Colour_Test:
  6. ; fade out
  7. bsr.w Pal_FadeFrom
  8.  
  9. bsr.w ClearPlane
  10.  
  11. ; clear sprite list
  12. lea ($FFFFF800).w,a1
  13. moveq #0,d0
  14. move.w #$7F,d1
  15. @clearobjects:
  16. move.l d0,(a1)+
  17. dbf d1,@clearobjects ; clear sprite RAM
  18.  
  19. ; load palette
  20. lea Pal_ColourTest,a1
  21. lea ($FFFFFB80).w,a2 ; palette transition ram location
  22. moveq #63,d0
  23. @copypal:
  24. move.w (a1)+,(a2)+
  25. dbf d0,@copypal
  26.  
  27. move.w #$8700,($C00004).l ; set background colour (line 0, palette entry 0)
  28.  
  29. ; load graphics
  30. locVRAM $0000
  31. lea (Nem_ColourTest).l,a0
  32. bsr.w NemDec
  33.  
  34. ;load mappings
  35. lea ($FF0000).l,a1
  36. lea (Eni_ColourTest).l,a0
  37. move.w #$0000,d0
  38. bsr.w EniDec
  39. lea ($FF0000).l,a1
  40. move.l #$40000003,d0
  41. moveq #40-1,d1
  42. moveq #28-1,d2
  43. bsr.w ShowVDPGraphics
  44.  
  45.  
  46. ; fade in
  47. bsr.w Pal_FadeTo
  48.  
  49. ; --------------------------------------------------------------------------
  50.  
  51. Colour_Test_Loop:
  52. move.b #$16,($FFFFF62A).w
  53. bsr.w DelayProgram ; wait for vblank
  54.  
  55. ; check for start
  56. andi.b #$80,($FFFFF605).w ; check if Start is pressed
  57. beq.w Colour_Test_Loop ; if not, branch
  58.  
  59. ; fade out
  60. bsr.w Pal_FadeFrom
  61.  
  62. ; clear colour test mappings
  63. locVRAM $C000
  64. moveq #0,d0
  65. move.w #$1EF,d1
  66. @cleartext:
  67. move.w d0,(a6)
  68. dbf d1,@cleartext
  69.  
  70. ; reload title logo mappings
  71. lea ($FF0000).l,a1
  72. lea (Eni_Title).l,a0 ; load title screen mappings
  73. move.w #0,d0
  74. bsr.w EniDec
  75. lea ($FF0000).l,a1
  76. move.l #$42060003,d0
  77. moveq #$21,d1
  78. moveq #$15,d2
  79. bsr.w ShowVDPGraphics
  80. jsr (ObjectsLoad).l
  81. jsr (BuildSprites).l
  82. bra.w LoadOptionMenuFromColourTest
  83. ; ===========================================================================
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement