Login
Forum Help



Post Your Message
="hidden" name="cat" value="Games">
Username: (Login)

Topic:
Message:
 


Previous Messages
Posted By

Csabo
on 2024-09-15
10:26:17
 Re: CASCADE (1982) and FRUIT HOOT.

Yeah, on an Android, you need a Bluetooth keyboard connected. In that case, it does work (albeit not the smoothest experience ever happy).

The online emulator is developed by @Gaia maestro (who also maintains YAPE, the de facto standard Plus/4 emulator). Hopefully we will see more improvements to both in the future happy

Posted By

orac81
on 2024-09-15
05:57:06
 Re: CASCADE (1982) and FRUIT HOOT.

That would be better, testing for equality is less likely to give a false positive, other cbm machines will have rom there that is >=128..
Anyway the poke to ram seems also to work.

And yes it seems vice +4 is lagging behind. I do have a real +4, but it needs work to run.

I notice that you supply a link to online emulation for progs on +4world, which is a nice feature, but did u know the keyboard on the emulator doesn't seem to work on android phones?

thanks again!

Posted By

Csabo
on 2024-09-10
14:51:42
 Re: CASCADE (1982) and FRUIT HOOT.

A better check would be
T = 65303 : POKE T, 0 : IF PEEK(T) = 128 THEN ?"TED"
This should work for all Commodore computers.

Posted By

orac81
on 2024-09-10
10:33:30
 Re: CASCADE (1982) and FRUIT HOOT.

Ok so hopefully i have fixed this.
The zip files at the start link to new versions of the programs. the c16/+4 version is now a compiled basic version. The "basic" version (cascade2bas.prg) is the source file (located at $0400, load with ,8) which should run on any 40 column commodore.

I decided to add:

62105 poke 65500,255

as the simplest fix, everything else is unaltered. doing this:

T = 65303 : POKE T, 0 : IF PEEK(T) >= 128 THEN ?"TED"

might give a "false positive" on some machines.
Anyway the compiled version is much faster, and is the choice if simply running the game to play, rather than looking at the source.

i have a few more old pet/c64 progs like this, i will publish more over time.

let me know if there is a problem, and thanks again for the help!

Posted By

Csabo
on 2024-09-09
11:55:25
 Re: CASCADE (1982) and FRUIT HOOT.

Can you suggest a BASIC2 test that tells a program if it is running on a c16/plus4?

Well, the first thing I would suggest is NOT to do this happy Since your ZIP file already contains a dedicated file for the C16, that one should be targeting the C16/Plus4, no detection needed.

Otherwise, this is from the startup program of The Hulk, which is official CBM software from 1984 (it checks the reset vector):

40 B=PEEK(65532)+256*PEEK(65533)
50 A$="SAGA.TED":IFB=64738 THEN A$="SAGA.C64"
60 LOAD (A$),8,1


This isn't 100% reliable either though, someone could have a custom cartridge which changes those values. I would personally check for the presence of a TED. One possible way to do it is:
T = 65303 : POKE T, 0 : IF PEEK(T) >= 128 THEN ?"TED"

This relies on the fact that the TED color registers will always have the highest bit set.

it works in winvice

There's your problem happy VICE is the bane of the Plus/4 scene. The problem is, because the C64 emulation is so good and VICE is so widespread, people assume the Plus/4 emulation must be equally good. Unfortunately it buggy, basic, and it hasn't been updated in years - and it likely won't be, because the actual Plus/4 emulators (YAPE, Plus4EMU) are so good, it would be a monumental effort to get it to that point.

To see what I'm talking about, open Wizard Of Wor Classic or Plus/4 XL in VICE.

In addition, the code only works by random chance. In VICE, go to settings / Machine / RAM and set the start up values to zero, you will see that it fails.

all other CBM computers by default will have rom there, not ram..

Yeah, the Plus/4 is unique in this regard. Above $FF40 there's a tiny slice of RAM which can be (and often is) freely used.

Posted By

orac81
on 2024-09-09
11:16:44
 Re: CASCADE (1982) and FRUIT HOOT.

Thinking a bit more, would simply adding

62105 poke 65500, 255

work? all other CBM computers by default will have rom there, not ram..

Posted By

orac81
on 2024-09-09
11:09:10
 Re: CASCADE (1982) and FRUIT HOOT.

just typing

62110 qvdu=3072: qcol=2048

would make a c16/+4 version for both programs..

Posted By

orac81
on 2024-09-09
11:05:25
 Re: CASCADE (1982) and FRUIT HOOT.

Ah ok, it works in winvice, thats what happens when you rely on emulation!
I use a test on line 62110 if peek(65500)=255 then qvdu=3072..
etc to set variables for screen/colour ram.
Can you suggest a BASIC2 test that tells a program if it is running on a c16/plus4? It must not use basic3.5 commands, which would make the code fail on a vic or pet etc..

Thanks for the input!

Posted By

Csabo
on 2024-09-09
10:37:27
 Re: CASCADE (1982) and FRUIT HOOT.

I think these two need a bit more time in the oven before we add them to the site. Both games have the same problem: white on white text is impossible to read.

Edit: ah, after looking at your code, I see the problem. Your code is checking $FFDC=$FF to determine if the computer is a Plus/4, but that won't work. That memory location is simply RAM, and the value there will be "undefined".

Posted By

orac81
on 2024-09-09
10:08:02
 CASCADE (1982) and FRUIT HOOT.

CASCADE is a BASIC game for any 40 column CBM computer. (C64, C16, PETs..)

https://github.com/orac81/miniapples/raw/main/cascade2.zip




"cascade2bas.prg" - Basic version for any cbm, load with ",8" not ",8,1" (it is located at $0401 so PETs can load it.)
"cascade2c64.prg" - Compiled c64 version.
"cascade2c16.prg" - c16/+4 version. (Basic)
"cascade11v20.prg" - Vic20 version (unexpanded)

To move, type the letter (a-z) you wish to remove and the balls will cascade down the gaps left. on reaching the bottom they will add to your score.
The computer trys to do the same. The game ends when there are no balls left.
A simple game, but its a neat concept.

The original PET version of CASCADE was first published in CCI Nov 1982 magazine.



FRUIT HOOT

FRUIT HOOT is a BASIC fruit machine game (originally written for the PET) that can run on any 40 column CBM computer. (C64, C16, PETs..)

https://github.com/orac81/miniapples/raw/main/fruit-hoot3.zip


"fruit3bas.prg" - Basic version for any cbm, load with ",8" NOT ",8,1"
(it is located at $0401 so PETs can load it.)
"fruit3c64.prg" - Compiled c64 version. (BASIC64)
"fruit3c16.prg" - c16/+4 version. (Basic, located to load ",8,1" ok.)

Fruit-hoot is a simple fruit machine game for any 40 column CBM machine. You start with $100, each go costs $1. During play press space to spin,
x to quit, n for a new game.

Its nothing special, but I liked my early PETSCII art of cherries, owl, bell.. Extra features like "hold" could be added quite easily.
I am sure someone can improve on it!

Both of the programs are released under the gnu gpl3 open license.


Copyright © Plus/4 World Team, 2001-2024. Support Plus/4 World on Patreon