In this post I show I used the Atari 8 bits Player/Missile graphics to produce a highlighter effect on graphics 0 screen text.
Essentially I am using players defined 8 bits wide and using double line resolution within the player/missile graphics. This equates to an 8×8 graphics 0 character cell with normal player width selected. I chose yellow as the highlight color as you might do on paper.
The only thing you need to watch out for is to ensure you don’t set the player luminance higher than the text luminance. If the player luminance is greater, you won’t be able to see the text behind it.
Using a player definition of 8 bits and combinations of player width of normal, double, and quadruple, you can highlight text at 2, 4, and 8 characters wide with a single player. With 4 players at quadruple width you can highlight 32 characters of the 40 character screen. If you want to use all 4 missiles as one player, you can achieve another 8 character highlight bringing it to the full 40 character screen width.
By placing players of different definitions (4 bits vs 8 bits wide) and player width sizes (single) next to each other you can highlight an odd number of characters.
Example
A screenshot of the end result:

The line labels on the right denote how each line was made:
“P0 0xFF Single” is player 0 formed from a 4 byte array consisting of $FF (all bits on) at single/normal player width to achieve 2 character coverage.
“P1 0xFF Double” is player 1 formed from a 4 byte array consisting of $FF (all bits on) at double player width to achieve 4 character coverage.
“P2 0xFF Quad” is player 2 formed from a 4 byte array consisting of $FF (all bits on) at quad player width to achieve 8 character coverage.
“P3 0x0F Single” is player 3 formed from a 4 byte array consisting of $0F (4 bits off, 4 bits on) at single player width to achieve 1 character coverage.
“M0 0x03 Double” is missile 0 formed from a 4 byte array consisting of $03 (bits 2 and 1 on) at double missile width to achieve 1 character coverage.
Code
The code is documented fairly well, and in combination with the description above, you should be able to see what is happening. If not, give me a shout. It does require the Action! Toolkit’s PMG.ACT and is coded for drive D2, change it if you need to.
; Prog..: PMHLTEXT.ACT
; Author: Ripdubski
; Desc..: Use P/M to highlight text
; Date..: 2022.06.29
; Notes.: Requires Action! Toolkit
INCLUDE "D2:PMG.ACT"
PROC main()
; Player1 is 4 lines/rows of 11111111
; Player2 is 4 lines/rows of 00001111
; Missile is 4 lines/rows of 11
BYTE ARRAY aPlyr1(4)=[$FF $FF $FF $FF],
aPlyr2(4)=[$0F $0F $0F $0F],
aMiss(4)=[$03 $03 $03 $03]
BYTE bLp
; Set graphics 0, already there.
Graphics(0)
; Turn on P/M
; Double line res for 8 rows from 4 row array!
PMGraphics(2)
; For each player
FOR bLp=0 TO 3
DO
; Clear data
PMClear(bLp)
; Set color to yellow
; Luminance of 4 is less than text(8)
PMColor(bLp,13,4)
OD
; Clear needed missiles
PMClear(4)
; Draw screen text
Position(13,2)
Print("Text Highlight")
Position(21,5)
Print("P0 0xFF Single")
Position(21,7)
Print("P1 0xFF Double")
Position(21,9)
Print("P2 0xFF Quad")
Position(21,11)
Print("P3 0x0F Single")
Position(21,13)
Print("M0 0x03 Double")
FOR bLp=4 to 14
DO
Position(10,bLp)
Print("1234567890")
OD
; Create each player in diff widths
; Param 4 is the width (1=N/S,2=D,4=Q)
; Param 5 is the x position
; Param 6 is the y position
PMCreate(0,aPlyr1,4,1,88,36)
PMCreate(1,aPlyr1,4,2,88,44)
PMCreate(2,aPlyr1,4,4,88,52)
; This player uses different array definition
PMCreate(3,aPlyr2,4,1,116,60)
; Create used missiles (only 1 here)
PMCreate(4,aMiss,4,2,88,68)
RETURN
There are many possibilities for using this technique.
Have fun!