Jump to content

Moj Mikro listings: Player/Missile demo + simple paint program


2 replies to this topic

#1  

    Dragonstomper

  • 771 posts
  • Joined: 13-July 05

Posted Wed Mar 10, 2010 5:42 PM

Here are two listings using player/missile feature of Atari computers.

Posted Image Posted Image


Player/Missile demonstration

Magazine: Moj Mikro, 1988/9
Author : Zlatko Bleha
Page : 41 - 43
Article link
Atari BASIC listing in magazine
Atari BASIC listing on disk (tokenized): MM880942.BAS

This program is a simple demonstration of using player/missile graphics on Atari. Just choose single or double resolution of players and missiles and program will proceed.

Posted Image Posted Image Posted Image Posted Image Posted Image Posted Image

Usage:

Load program from disk by typing:

LOAD "D:MM880942.BAS"

and type RUN to execute the program.


Paint with joystick

Magazine: Moj Mikro, 1988/10
Author : Zlatko Bleha
Page : 54 - 55
Atari BASIC listing on disk (tokenized): MM881054.BAS
Atari BASIC listing on disk (listed): JOYPAINT.LST
Screen Print routine (assembly language disassembled listing): pmg.asm

This is simple painting program in hi-res resolution ( graphics mode 8 ). You move pencil (player) to draw pixels and lines on the screen. The only other feature of this short program is machine language routine which enables you to make hardcopy of Atari graphics screen to Seikosha GP 500 AT printer. It will probably work on any other printer with similar specifications (for example EPSON dot-matrix printers).

Because Atari graphics layout is different from dot-matrix printer with 7-bit logic, we need routine to convert between layouts. Machine language routine, called Screen Print, does move 7 rows to the left by one pixel in one batch. When data byte is prepared, it is send to printer and printed to paper. This happens 320 times so whole screen (picture) is printed. This data manipulation would wipe out picture on the screen, but this will not happen, because special subroutine moves all processed pixels to the right side of the display.

Posted Image Posted Image
Posted Image Posted Image

The syntax for using the routine from Atari BASIC is like this:

A=USR(1600,D,D-1)

Variable D is starting byte of the first 7 rows, which is what has to be converted to the appropriate printer matrix. This routine must be called 320 times. Resulting value in variable A holds data which goes to the printer. In next iterations we have to change the formula for the parameter D: D=D+7*40, so it will point to the starting byte of the next 7 rows.

Usage:

Load program from disk by typing:

LOAD "D:MM881054.BAS"

and type RUN to execute the program.

Program options:

Start - Draw pixels and lines
Select - Erase pixels and lines
Option - Dump current picture to the printer

Greetings,
Gury

Attached Files

  • Attached File  Pmg.zip   17.36K   55 downloads

Edited by Gury, Wed Mar 10, 2010 5:47 PM.


#2  

    Star Raider

  • 77 posts
  • Joined: 02-December 06

Posted Thu Mar 11, 2010 11:37 AM

hi Gury,

are some examples of player 1 with collisions with playfiled?

greetings

#3  

    Dragonstomper

  • 771 posts
  • Joined: 13-July 05

Posted Fri Mar 12, 2010 12:53 AM

View Postascrnet, on Thu Mar 11, 2010 11:37 AM, said:

hi Gury,

are some examples of player 1 with collisions with playfiled?

greetings
Hi ascrnet,

Demo example uses collision detection at the end of the program. The magazine article includes only one example with good prepared text with theory behind. All other is just the imagination of the programmer how he/she uses the features of Atari computer.

Edited by Gury, Fri Mar 12, 2010 12:57 AM.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users