Author Topic: Basic Playroutine  (Read 1466 times)

0 Members and 1 Guest are viewing this topic.

Offline Fabrizio Radica

  • Supporter
  • CPC664
  • *
  • Posts: 135
  • Country: it
  • Amiga and CPC6128 User
    • Retroacademy
  • Liked: 128
  • Likes Given: 122
Basic Playroutine
« on: 19:18, 03 August 16 »
HI  :)
i've a little question  ::)

We have a play-routine to play music in basic? For an intro game for example.
If yes, how i implement it in basic?

I learned how to load (and save like screenshots) .SCR in to ram, but i don't know how to play musics.
I would not want to use the sound command  :P

thanks in advance and long life to CPC :D
Amstrad CPC6128 <3
http://www.facebook.com/groups/retroacademy/
Retroacademy.it - retrocomputing, retrogame anni &#039;70, &#039;80, &#039;90
Retroacademy.it - retrocomputing, retrogame anni '70, '80, '90

Offline SRS

  • Supporter
  • 6128 Plus
  • *
  • Posts: 620
  • Country: de
  • Schneider CPC464 - what else ?
  • Liked: 612
  • Likes Given: 351
Re: Basic Playroutine
« Reply #1 on: 19:52, 03 August 16 »
Hi,

if you want to play MIDI :

simple ay playback example: pb on winape

Offline Fabrizio Radica

  • Supporter
  • CPC664
  • *
  • Posts: 135
  • Country: it
  • Amiga and CPC6128 User
    • Retroacademy
  • Liked: 128
  • Likes Given: 122
Re: Basic Playroutine
« Reply #2 on: 22:47, 03 August 16 »
Hi,

if you want to play MIDI :

simple ay playback example: pb on winape


uhm. i need to convert it in basic.  :doh:
Amstrad CPC6128 <3
http://www.facebook.com/groups/retroacademy/
Retroacademy.it - retrocomputing, retrogame anni &#039;70, &#039;80, &#039;90
Retroacademy.it - retrocomputing, retrogame anni '70, '80, '90

Offline SRS

  • Supporter
  • 6128 Plus
  • *
  • Posts: 620
  • Country: de
  • Schneider CPC464 - what else ?
  • Liked: 612
  • Likes Given: 351
Re: Basic Playroutine
« Reply #3 on: 23:09, 03 August 16 »
Ah, well.

Take i.e. "Dune" asm.

 You assemble it in emulator to memory
then you can save it  from BASIC - SAVE"DUNE.BIN",B,&8000,&51E

In your BASIC-Game you set

MEMORY &7FFF

and

LOAD"dune.bin",&8000

and if you want the music to play: CALL &8000. now it plays "infinite" until you CALL &8003.

Offline Fabrizio Radica

  • Supporter
  • CPC664
  • *
  • Posts: 135
  • Country: it
  • Amiga and CPC6128 User
    • Retroacademy
  • Liked: 128
  • Likes Given: 122
Re: Basic Playroutine
« Reply #4 on: 23:42, 03 August 16 »
Ah, well.

Take i.e. "Dune" asm.

 You assemble it in emulator to memory
then you can save it  from BASIC - SAVE"DUNE.BIN",B,&8000,&51E

In your BASIC-Game you set

MEMORY &7FFF

and

LOAD"dune.bin",&8000

and if you want the music to play: CALL &8000. now it plays "infinite" until you CALL &8003.


It seems like you do with the asm c64.

jsr 1000 ;init SID
jsr 1003 ;playSID

tnx, i try. :)
Amstrad CPC6128 <3
http://www.facebook.com/groups/retroacademy/
Retroacademy.it - retrocomputing, retrogame anni &#039;70, &#039;80, &#039;90
Retroacademy.it - retrocomputing, retrogame anni '70, '80, '90

Offline Fabrizio Radica

  • Supporter
  • CPC664
  • *
  • Posts: 135
  • Country: it
  • Amiga and CPC6128 User
    • Retroacademy
  • Liked: 128
  • Likes Given: 122
Re: Basic Playroutine
« Reply #5 on: 00:23, 04 August 16 »
Ah, well.

Take i.e. "Dune" asm.

 You assemble it in emulator to memory
then you can save it  from BASIC - SAVE"DUNE.BIN",B,&8000,&51E

In your BASIC-Game you set

MEMORY &7FFF

and

LOAD"dune.bin",&8000

and if you want the music to play: CALL &8000. now it plays "infinite" until you CALL &8003.


yeah, works fine :D
here a snapshot of the game, taken with JavaCPC (on OSX)

:)

Amstrad CPC6128 <3
http://www.facebook.com/groups/retroacademy/
Retroacademy.it - retrocomputing, retrogame anni &#039;70, &#039;80, &#039;90
Retroacademy.it - retrocomputing, retrogame anni '70, '80, '90

Offline AMSDOS

  • Supporter
  • 6128 Plus
  • *
  • Posts: 3.939
  • Country: au
    • index.php?action=treasury
    • Programs for Turbo Pascal 3
  • Liked: 1155
  • Likes Given: 1923
Re: Basic Playroutine
« Reply #6 on: 00:36, 04 August 16 »

uhm. i need to convert it in basic.  :doh:

Earlier I found a BASIC game which allowed @Morri to use in their Coolbox game I think.
* 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