home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Game Programming Gurus / Tricks_of_the_Game_Programming_Gurus_SAMS_Publishing_1994.iso / source / chap_02 / setmodea.asm < prev    next >
Assembly Source File  |  1994-01-29  |  749b  |  26 lines

  1.  
  2. .MODEL MEDIUM,C                 ; use medium model with C parameter passing
  3.     
  4. .CODE                 ; this is the beginning of the code
  5.  
  6. PUBLIC Set_Mode                 ; this let's the linker have access to the function
  7.                                 ; name so that it can be exported
  8.  
  9. Set_Mode PROC FAR C vmode:WORD    ; the function takes one parameter
  10.  
  11.  
  12. mov ah,0                        ; function 0:set video mode
  13. mov al, BYTE PTR vmode          ; set the mode we want to change to
  14. int 10h                         ; use BIOS to set the mode
  15.  
  16. ret                             ; return to caller
  17.  
  18. Set_Mode ENDP                   ; this is the end of the procedure
  19.  
  20. END                             ; this is the end of the code
  21.  
  22.  
  23.  
  24.  
  25.  
  26.