home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 3 / PDCD_3.iso / games / gamesuite / !Amnesia / AmsHelp / Technical / PlotCode < prev    next >
Text File  |  1994-08-19  |  767b  |  33 lines

  1.  
  2. ; Amnesia module plot code
  3. ; This header was part of the module code which was assembled using !ExtAsm.
  4. ; Copyright A.Southgate 1994 but may be freely distributed and used in the
  5. ; creation of other code.
  6.  
  7. ; Before calling the module has performed the equivalent of a
  8. ; LDMIA R10,{R0,R2-R4}, where R10 is the address of the object
  9.  
  10. .plotobj
  11. STMFD R13!,{R0-R3,R14}
  12. TST R2,#Amf_anim
  13. BLNE fastspranim
  14. TST R2,#Amf_use_plot_ofs
  15. LDRNE R3,[R12,#v.plotxofs]
  16. LDR R1,[R10,#o.x]
  17. ADDNE R1,R1,R3
  18. LDRNE R3,[R12,#v.plotyofs]
  19. LDR R2,[R10,#o.y]
  20. ADDNE R2,R2,R3
  21. MOV R1,R1,ASR #coordshift
  22. MOV R2,R2,ASR #coordshift
  23. SWI FastSpr_Plot
  24. LDMFD R13!,{R0-R3,PC}
  25.  
  26. .fastspranim
  27. TST R2,#Amf_timer2
  28. LDREQ R1,[R10,#o.timer]
  29. LDRNE R1,[R10,#o.timer2]
  30. AND R1,R1,#&FF<<24
  31. ORR R0,R0,R1,LSR #8
  32. MOV PC,R14
  33.