News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_ComSoft6128

6128TYPE

Started by ComSoft6128, 08:24, 30 April 19

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ComSoft6128

Small BASIC file, by John Valentine, which creates a pseudo 3D image. I think this was a type-in in Amstrad Action or Amstrad Computer User which was later included in the WACCI PD library.
This was intended to be part of a larger video displaying another 5 or 6 small BASIC programs but due to a hardware failure - drive B "fell on its arse" :( - the video is limited to this program only. I have listed the BASIC files for 464TYPE and 6128TYPE for anyone that is interested.


https://www.youtube.com/watch?v=VUmMvdR_kR0


See also this interesting NASA image:

https://heasarc.gsfc.nasa.gov/docs/xanadu/ximage/examples/plot.html

AMSDOS

Sorry I thought I mentioned about this being published in Amstrad Action Issue 33. I recall this graphical demo as I was considering writing my own FILL routine to get it looking the same on the 464. :picard:
* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

GUNHED

It was always clear to some of us... the CPC comes from Orion.
http://futureos.de --> Get the revolutionary FutureOS (Update: 2023.11.30)
http://futureos.cpc-live.com/files/LambdaSpeak_RSX_by_TFM.zip --> Get the RSX-ROM for LambdaSpeak :-) (Updated: 2021.12.26)

AMSDOS


This is just one of the BASIC based FILL routines I created in BASIC 1.0, unsure if it would work in your graphical as the shape outlines aren't straight, a more accurate fill would search where it needs to FILL to, though that too can be a fatal thing to do with BASIC 


The idea I had with this one was draw a square anywhere onscreen and of any size and any colour (to fill). The only problem I had was the size of the square needs to be an even number, to prevent the FILL part of the program rubbing out the top line, which is what the WHILE s MOD 2=1 on line 20 checks for. Otherwise for lines 1000..1040 which draw the square, lines 1000..1020 have XPOS & YPOS to store values for the FILL routine use for guidance.



10 MODE 0:INK 14,9:INK 15,11:DEFINT a-z
20 x=INT(RND*538):y=INT(RND*282):s=INT(RND*100)+6:WHILE s MOD 2=1:s=INT(RND*100)+6:WEND:c=INT(RND*14)+1:GOSUB 1000
30 WHILE y1<y2
40   MOVE x1,y1:DRAW x2,y1,c
50   y1=y1+2
60 WEND
70 GOTO 20
1000 MOVE x,y:x1=XPOS+4:y1=YPOS+2
1010 DRAWR 0,s,1:y2=YPOS
1020 DRAWR s,0:x2=XPOS-4
1030 DRAWR 0,-s
1040 DRAWR -s,0
1050 RETURN



From that I can produce quite an Abstract Square view.
* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

ComSoft6128

#4
Thanks AMSDOS,

"your graphical" - just to be quite clear to anyone that missed the beginning of this thread - I'm not a programmer. I am fortunate enough to have a collection of PD material on 25 - 30 year old disks that are mostly still viable. I plan on making a series of videos that may be of interest to the CPC community using some of these programs.

Cheers,

Peter

AMSDOS

That's cool, merely showing an example.  :D Looking forward to the new videos.
* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

ComSoft6128

Hi AMSDOS,

A few new vids should be published this coming Monday or Tuesday. Where possible I will list the BASIC files for examination.

Cheers,

Peter

AMSDOS

Sorry I want to revisit the "464TYPE.BAS" and "6128TYPE.BAS" programmes, as there's some other things in them which weren't as apparent:

       
  • Earlier, I mentioned it came from AA33 titled "3D Hidden Line Removal Graph", both versions are on the Type-Ins page on CPCWiki.
  • The original type-in doesn't have any "Wait....", which is cleared when Drawing commences.
  • All the REMarks have been removed.
  • AA made the remark about the type-in using FILL, in addition to the FILL the 464TYPE.BAS demonstration has been altered in lines 290 & 330 to replace MOVE statements with 3 parameters with BASIC 1.0 compatible 3 parameter PLOT.
  • Line 400 of both demonstration files is a substitute line which can be used to replace line 150 or 150 can be REM out and Line 400 put on 151, running that the landscape is transformed into something similar seen in the 'Glider Rider' game. A screenshot of this was used in AA33 Type-Ins pages.
  • I made some adjustments to the alternative version to create a 464 compatible to fill in the gaps and although it's not quite perfect, seems to be better than nothing. I was able to use my BASIC translation of it to make a Hisoft Pascal 4t.

* Using the old Amstrad Languages :D   * with the Firmware :P
* I also like to problem solve code in BASIC :)   * And type-in Type-Ins! :D

Home Computing Weekly Programs
Popular Computing Weekly Programs
Your Computer Programs
Updated Other Program Links on Profile Page (Update April 16/15 phew!)
Programs for Turbo Pascal 3

Powered by SMFPacks Menu Editor Mod