BASIC V POWA ! :)

discuss general risc os software applications and utilities
Related forum: adventures


Post Reply
drfloyd
Posts: 381
Joined: Tue Jun 09, 2020 3:36 pm
Contact:

BASIC V POWA ! :)

Post by drfloyd » Thu Aug 06, 2020 6:09 pm

Hello, here is the frog, now interesting in Archimedes machines :) Wanted a A3010.

I love BASIC IV on BBC MASTER....

Who can speak about the BASIC V ?

Is it really powerfull ? Can we imagine quality game with it without assembler ?0

Can we manipulate block of images ?

What about the compilers ? There are several no ?

Have you link to video of good programs with basic V ?

Thanks !

User avatar
jms2
Posts: 2683
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: BASIC V POWA ! :)

Post by jms2 » Thu Aug 06, 2020 10:25 pm

drfloyd wrote: Is it really powerfull ?
It was said to be the fastest interpreted BASIC in the world, but of course much of that speed came from the Archimedes machines that it ran on. There is actually a version for the 6502 (called Advanced BASIC), but I would expect this is no faster than BASIC IV.

The difference with BASIC V is that it has a lot of new commands, some that I can remember are:
CIRCLE, RECTANGLE [FILL]
CASE... ENDCASE, WHILE... ENDWHILE, IF...THEN has a multi-line version with ENDIF
Array operations
Binary numbers prefixed with %
A%=A%+1 can be shortened to A%+=1
etc etc.
drfloyd wrote: Can we imagine quality game with it without assembler ?
On an Archimedes, yes definitely. It is possible to write a game that is comparable to a "reasonably good" BBC micro machine code game, just by using BASIC. However, if you want to use the Archimedes to its full potential, obviously you must use ARM machine code.
drfloyd wrote: Can we manipulate block of images ?
Yes, I think the command is something like RECTANGLE x1,y1,x2,y2 TO x3,y3... but I think you can only move to somewhere else on the screen, if I remember correctly.
drfloyd wrote: What about the compilers ? There are several no ?
There is the Archimedes BASIC compiler (ABC) which is very good I believe. Not used it though.
drfloyd wrote: Have you link to video of good programs with basic V ?
Hmm, I'm sure there are quite a few games but I'm not familiar with them myself. Many small (but useful) applications were written in BASIC, and the GUI desktop for the first operating system (Arthur 1.2) was written in BASIC.

Naomasa298
Posts: 391
Joined: Sat Feb 16, 2013 12:49 pm
Contact:

Re: BASIC V POWA ! :)

Post by Naomasa298 » Thu Aug 06, 2020 11:22 pm

RISC OS includes sprite routines, which can be called using OS_SpriteOp, all doable from BASIC.

User avatar
IanJeffray
Posts: 302
Joined: Sat Jun 06, 2020 3:50 pm
Contact:

Re: BASIC V POWA ! :)

Post by IanJeffray » Fri Aug 07, 2020 12:23 am

Naomasa298 wrote:
Thu Aug 06, 2020 11:22 pm
RISC OS includes sprite routines, which can be called using OS_SpriteOp, all doable from BASIC.
You can even use simple BASIC V "PLOT" to draw sprites from the system sprite area.

Quite a few RISC OS games have their menu system / front-end written in BASIC, even if the 'main game' is written in asm. A great number of RISC OS desktop applications are also written in BASIC, including comparatively huge applications such as video editors and painting programs.

drfloyd
Posts: 381
Joined: Tue Jun 09, 2020 3:36 pm
Contact:

Re: BASIC V POWA ! :)

Post by drfloyd » Fri Aug 07, 2020 6:43 am

wonderful, thanks for your reply ! Need to try it !

We can aldo download images, cut it in several tiles, and put on screen ? ... with a double buffering ?

User avatar
jms2
Posts: 2683
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: BASIC V POWA ! :)

Post by jms2 » Fri Aug 07, 2020 9:42 am

Yes double buffering is possible, but this is an OS feature rather than BASIC.

You should read this - it's the manual for BASIC VI. :D This is the same as BASIC V except it has 64-bit floating point.

https://www.4corn.co.uk/archive/docs/BB ... al-opt.pdf

The manual describes all the BASIC V functions very clearly, and there is also an appendix which explains the differences between all the BBC BASIC variants.

User avatar
helpful
Posts: 634
Joined: Tue Sep 22, 2009 1:18 pm
Location: London
Contact:

Re: BASIC V POWA ! :)

Post by helpful » Fri Aug 07, 2020 3:22 pm

AMCOG produces games which are all written in BASIC, although the minimum spec machine for them is a Pi1 which has rather more processing power than the original Archimedes!

http://www.amcog-games.co.uk/index.htm

Bryan.
RISC OS User Group Of London - http://www.rougol.jellybaby.net/
RISC OS London Show - http://www.riscoslondonshow.co.uk/

User avatar
Richard Russell
Posts: 1668
Joined: Sun Feb 27, 2011 10:35 am
Location: Downham Market, Norfolk
Contact:

Re: BASIC V POWA ! :)

Post by Richard Russell » Fri Aug 07, 2020 4:47 pm

jms2 wrote:
Thu Aug 06, 2020 10:25 pm
The difference with BASIC V is that it has a lot of new commands, some that I can remember are:
CIRCLE, RECTANGLE [FILL]
CASE... ENDCASE, WHILE... ENDWHILE, IF...THEN has a multi-line version with ENDIF
Array operations
Binary numbers prefixed with %
A%=A%+1 can be shortened to A%+=1
You've covered most things there, but others worthy of note are assigning to a sub-string, swapping two variables and local error trapping:

Code: Select all

      MID$(a$,3,2) = "AB"
      SWAP a%,b%
      ON ERROR LOCAL...
What you've described as "Array operations" are so extensive and important that they would need their own thread to do them justice!

drfloyd
Posts: 381
Joined: Tue Jun 09, 2020 3:36 pm
Contact:

Re: BASIC V POWA ! :)

Post by drfloyd » Sat Aug 08, 2020 6:24 pm

jms2 wrote:
Fri Aug 07, 2020 9:42 am
Yes double buffering is possible, but this is an OS feature rather than BASIC.

You should read this - it's the manual for BASIC VI. :D This is the same as BASIC V except it has 64-bit floating point.

https://www.4corn.co.uk/archive/docs/BB ... al-opt.pdf

The manual describes all the BASIC V functions very clearly, and there is also an appendix which explains the differences between all the BBC BASIC variants.
Starting reading the manual, it's near Basic IV

The section about tiles/sprites is very short.

If I want to draw a RPG map, for exemple 21x21 tiles (of 16x16 pixels) i should load the tiles as sprites ?

Apparently, more informations in the "Programmer's Reference Manual", available online in PDF ?

User avatar
jms2
Posts: 2683
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: BASIC V POWA ! :)

Post by jms2 » Sat Aug 08, 2020 7:31 pm

That’s because sprites are an OS feature, not a BASIC feature (although you can of course call up the feature from BASIC).

Yes, if you want to plot any kind of bitmap from BASIC you should define it as a sprite. This can be done using the editor !Paint in RISC OS, or you can define them using Windows software and a suitable converter program.

Then you can plot it, either the BBC Master way using PLOT, if you want, or the newer RISC OS way using OS_SpriteOp. To be honest I don’t know what advantages the new way has.

drfloyd
Posts: 381
Joined: Tue Jun 09, 2020 3:36 pm
Contact:

Re: BASIC V POWA ! :)

Post by drfloyd » Sat Aug 08, 2020 8:01 pm

download a unique and full picture, and then cut it in several tiles into variables should also possible ?

Naomasa298
Posts: 391
Joined: Sat Feb 16, 2013 12:49 pm
Contact:

Re: BASIC V POWA ! :)

Post by Naomasa298 » Sat Aug 08, 2020 8:28 pm

drfloyd wrote:
Sat Aug 08, 2020 8:01 pm
download a unique and full picture, and then cut it in several tiles into variables should also possible ?
I would do that on a PC and convert it. IIRC, !Paint isn't very good for that.

User avatar
jms2
Posts: 2683
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: BASIC V POWA ! :)

Post by jms2 » Sat Aug 08, 2020 8:30 pm

I’m not quite sure what you mean, but I think it is possible to store part of the screen as a sprite, so you can use that method to cut a big picture into chunks.

I briefly played with sprites on the Archimedes, and I used the old fashioned BBC method rather than SpriteOp. From memory, I think the commands I used to plot a sprite on the screen were:

*SLOAD <filename>
*SCHOOSE 1
PLOT &EA,x,y

... but this is almost certainly not the best way.

Have you got your A3000 yet?

drfloyd
Posts: 381
Joined: Tue Jun 09, 2020 3:36 pm
Contact:

Re: BASIC V POWA ! :)

Post by drfloyd » Sat Aug 08, 2020 9:39 pm

next week I will have :)

I think with ABC compiler...

Perhaps I will try to develop a SCI FI role Game on it... perhaps ;)

Post Reply

Return to “32-bit acorn software: other”