|
Im Magazin „8000 PLUS" wurde im September 1990 der folgende Artikel abgedruckt.
|
|
| The PCW challenges you to a game of skill and strategy in the program othello.bas |
|---|
| The program is set up in lines 10 to 40. The program then prompts the user to enter the level of play and the board is drawn. Line 80 is the main program loop. |
| Lines 90 to 180 consist of a subroutine which assigns values to the board. This subroutine is called in line 70 ot the main program. |
| The subroutine at line 190 starts by allowing the player to enter a move. The subroutine is called during the main program loop on line 80. |
| This part ot the subroutine checks to see if a move is valid, and is used to check either the computer's or player's move. |
|
The computer finds its best move in this part of the program, using the previous subroutine to check whether a move is valid or not. Make sure that when typing in lines 350, 360 and 380 that you don't press [RETURN] as these are simply very long lines. |
| Between line 430 and line 630 is the subroutine to draw the screen. It calls on separate subroutines, at lines 540 and 680, to draw the black and white counters. |
| From line 720 onwards the program loads a section of machine code into memory, including the data needed to provide the graphics for this program. |
| [BASIC-Listing und [Assembler-Listing] |
HTML-Bearbeitung von
Werner Cirsovius
Februar 2015
© 8000 PLUS