1
0
mirror of https://github.com/PDP-10/its.git synced 2026-02-13 19:44:00 +00:00
Files
PDP-10.its/src/spcwar/340def.4
Lars Brinkhoff 4d32246eea Spacewar! game.
Build for both standalone and timesharing.
2018-02-19 08:21:59 -08:00

95 lines
2.5 KiB
Groff
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
SUBTTL 340 Display Definitions
;Command Operation Codes
;----- Valid in Any Mode
GTOPRM==BIT2.9 ;this command is guarenteed to place the display
;into parameter mode regardless of the current mode
;----- Valid in Parameter and Point Commands
PARM== 0 ;next command is parameter mode
POINT== BIT2.5 ; " " " point "
VECT== BIT2.7 ; " " " vector "
VECTC== BIT2.7+BIT2.5 ; " " " vector-continue mode
CHAR== BIT2.6+BIT2.5 ; " " " character mode
INCR== BIT2.7+BIT2.6 ; " " " increment "
;----- Valid in Vector, Vector-Continue, and Increment Modes
ESCAPE==BIT2.9 ;return display to parameter mode
;Specific Bits/Values for Different Command Types
;----- Parameter Mode
DISHLT==<GTOPRM,,BIT2.2+BIT2.1> ;stop this display list
;----- Point Mode
DISPNT==BIT2.2 ;intensify the current point
;----- Vector and Vector-Continue Modes
DISVCT==BIT2.8 ;make this vector visible
NEGX== BIT1.8 ;if on, X shift is negative
NEGY== BIT2.7 ;if on, Y shift is negative
;----- Character Mode (Any Case)
CHRESC==37 ;escape from character mode
CHRUC== 35 ;shift to upper-case
CHRLC== 36 ; " " lower-case
CHRLF== 33 ;line-feed
CHRCR== 34 ;carriage-return
CHRSP== 40 ;space
;Macros to Generate Display Commands
;SCALE(VALUE)
; Function:
; Generates a parameter mode command to set the display scaling factor.
; Inputs:
; VALUE: The scaling factor as a value from 0 to 3.
DEFINE SCALE (VALUE
<BIT1.7+<VALUE&3>_4>TERMIN
;INTSTY(VALUE)
; Function:
; Generates a parameter mode display command to set the display intesity.
; Inputs:
; VALUE: The intensity as a value from 0 through 7.
DEFINE INTSTY (VALUE
<BIT1.4+<VALUE&7>>TERMIN
;SETY(VALUE)
; Function:
; Generates a point mode command to set the Y ordinate.
; Inputs:
; VALUE: The Y ordinate as a value from 0 through 1777(8).
DEFINE SETY (VALUE
<BIT2.8+<VALUE&1777'>>TERMIN
;SETX(VALUE)
; Function:
; Generates a point mode command to set the X ordinate.
; Inputs:
; VALUE: The X ordinate as a value from 0 through 1777(8).
DEFINE SETX (VALUE
<VALUE&1777'>TERMIN
;VECTOR(XVALUE,YVALUE)
; Function:
; Generates a vector or vector-continue command to create a vector.
; Inputs:
; XVALUE: The magnitude (positive) of the X shift. It is in the range 0
; through 177(8).
; YVALUE: The magnitude of the Y shift. It is treated identically to XVALUE.
DEFINE VECTOR (XVALUE,YVALUE
<<XVALUE&177'>+<<YVALUE&177'>_8.>>TERMIN