that the pixel with these coordinates is set to. To illustrate this rewrite the previous example as:
CLS: POINT 0,0 TO t: PRINT t: PLOT
0,0:POINT 0,0 TO t: PRINT t
Although this may not be the best example for the benefits of using POINT TO instead of the simple POINT, you can save a lot of typing by foregoing a lot of LET statements whilst, at the same time, making your code a lot easier to read and working in every graphics mode. It's important to mention that POINT TO does not return the contents of a sprite that's currently on the given coordinates on screen and instead will return the contents of the layer it's run on.
Notes
POINT here is a function and not a PRINT modifier. Note the distinction as it's important.
Enter screen mode (EDIT for NextBASIC Menu and then the Screen option) in the editor and then type:
PAPER 7: INK 0
and let us investigate how INVERSE and OVER work inside a standard graphics statement. These two affect just the relevant pixel, and not the rest of the character positions. They are normally off (0) in a graphics statement, so you only need to mention them to turn them on (1).
Here is a list of the possibilities for reference:
As another example of using the OVER statement fill the screen up with writing using black on white, and then type:
PLOT 0,0: DRAW OVER 1;255,175
This will draw a fairly decent line, even though it has gaps in it wherever it hits some writing. Now do exactly the same command again. The line will vanish without leaving any traces whatsoever. This is the great advantage of OVER 1. If you had drawn the line using:
PLOT 0,0: DRAW 255,175
and erased it using:
PLOT 0,0: DRAW INVERSE 1;255,175
then you would also have erased some of the writing. Now try:
PLOT 0,0: DRAW OVER 1;250,175
ZX Spectrum Next User Manual, 3rd Edition (ISBN 978-1-5272-5496-1), written and illustrated by Phoebus R. Dokos. Copyright © 2020-2024 Phoebus Dokos / SpecNext Ltd. Licensed under CC BY-NC-SA 4.0. This is a transcription and can contain errors; check any doubt against the printed page.