Castle of Riddles.

having trouble with an archived file or want to correct something? report it here!
User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Castle of Riddles.

Postby leenew » Thu Feb 20, 2014 8:23 pm

Hi,
Amongst other things, I am still pootling away trying to put to disc all of the latest versions of software that is available.
Castle of Riddles is on disc in V1 form.
V2 is in the cassette archive.
It appears unprotected so it should be a breeze to put to disc.
I have however come across some issues
Firstly, Beebem does not seem to like this program.
Try the one in the STH disc image archive, or the one on AC3 in the 143 disc collection.
When it starts, press I to start at the initial position.
Next type E to go EAST. It errors to "WOULD YOU LKE ANOTHER GAME?"
It shouldn't do that!
Also, when trying to put it to disc, I *LOADed it at 1100 then saved it to disc *SAVE "castle2"1100+6500
When I come to run the program - by loading it in and relocating it to E00 then running it, it errors, sometimes with random commands appearing at the end of lines.
LINE210 has OSCLI OSCLI at the end.
My version played through the datacentre on the real beeb seems to play OK.

Do we know what is happening.

Lee.

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 8:37 pm

I've tried this one on Beebem ...

http://www.stairwaytohell.com/bbc/archi ... iddles.zip

... and I push I and the game starts.

There's a flash of error messages BEFORE I get prompted to start, but otherwise it goes.

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Thu Feb 20, 2014 8:48 pm

after you push the letter I Richard and you get the first description of where you are, type E for east and tell me what it says please. :D

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 8:51 pm

](*,) DOH!!! :oops: It's too early in the morning, only 9.50 a.m. :^o

:E
WOULD YOU LIKE ANOTHER GAME?

Seems to have taken E for End rather than East?

If you say N to another game you can LIST it ... maybe there are some clues in there.

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Thu Feb 20, 2014 9:02 pm

It's not right.
E should say "YOU CAN'T GO IN THAT DIRECTION"
The reason it says "DO YOU WANT ANOTHER GAME" is because of an error.
line 8 is on error proc do you want another game....
But, the error is something in the way it has been transferred.
Don't even bother trying to follow the program, it is probably the hardest to follow program of all time!!
The point is, it should be simple to transfer, but something seems to be going wrong if Beebem is used for loading/saving??
I shall try to do the transfer from the beeb tomorrow, but I don't have an original tape, or UPURS (yet) to get the tape to the beeb...
Not sure how to approach it at the moment (2 glasses of wine are coursing through my veins :D )

Lee.

**EDIT Get a cup of coffee Richard :D **
Last edited by leenew on Thu Feb 20, 2014 9:07 pm, edited 1 time in total.

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 9:07 pm

Armed with my Killworth (now, who did I buy that from?) maybe the code will make more sense? :lol:

But I agree - trying to re-transfer might be easier. I've got my BITD tape so can give that a go some time.

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Thu Feb 20, 2014 9:14 pm

Here's what I did.

*TAPE
LOAD"CASTLE"

DELETE 140 PAGE=&E00:CHAIN"CASTLE2"
140 LOAD CASTLE2 AT 1100 THEN RELOCATE TO E00 THEN RUN THE PROGRAM

MAKE A !BOOT TO LOAD THE CASTLE AT 7600

*LOAD CASTLE2 1600
*DISC
*SAVE "CASTLE2" 1600+6500

BOOT THE DISC

this should load CASTLE at 7600 which LOADS CASTLE2 at 1100 then relocates it to E00 and RUN it.

It appears to work but has errors in the listing for some reason, eg the OSCLI OSCLI appearing from nowhere?

User avatar
sweh
Posts: 1847
Joined: Sat Mar 10, 2012 12:05 pm
Location: New York, New York
Contact:

Re: Castle of Riddles.

Postby sweh » Thu Feb 20, 2014 9:28 pm

Changing the ON to a REM we can see the error:
"Arguments at line 420"

Line 420 reads:

Code: Select all

  420I%=I%+1+3*(I%=25):PROCMO(8,IOSCLIOSCLI0)


Yeah, that looks wrong. I think it should be

Code: Select all

  420I%=I%+1+3*(I%=25):PROCMO(8,I%,0)

Somehow the "%," got replaced with &FF &FF
I binary edited the code so that it reads what I expected and now it says

Code: Select all

:E
YOU CAN'T GO IN THAT DIRECTION!

:
Rgds
Stephen

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 9:29 pm

Coffee? Yuck. Nice cup of tea!

I get the OSCLIOSCLI in the STH version, too:
CoR.jpg
OSCLIOSCLI my precious
Not saying directly related to what you are seeing and I've hacked at it a little bit.

BUT if I load the game (with no changes) press I, E, N and then LIST 420 - it shows like what's in the screenshot.

User avatar
sweh
Posts: 1847
Joined: Sat Mar 10, 2012 12:05 pm
Location: New York, New York
Contact:

Re: Castle of Riddles.

Postby sweh » Thu Feb 20, 2014 9:31 pm

FWIW, that's the only line where OSCLI appears; there could be other corruption, though!
Rgds
Stephen

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 9:33 pm

Yep, I'll dig the tape out ... think I've got at least one copy of it ... but not sure if V1 or V2.

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Thu Feb 20, 2014 9:39 pm

The UEF of V2 in the STH archive seems to load and play just fine in Beebem but it seems to corrupt when saving the CASTLE2 file to disc.
I don't think there is any protection, it seems to be a BASIC program with all the data above TOP
It is quite a big file (&6500) but it should easily be relocatable.
nothing's ever simple :(

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 9:44 pm

leenew wrote:nothing's ever simple :(
Go have another glass of wine.

What's the link to the V2 version - is it the save game one?

http://www.stairwaytohell.com/bbc/archi ... veGame.zip

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Thu Feb 20, 2014 10:00 pm

Here you go
CastleOfRiddles-v2.0_B.zip
(15.64 KiB) Downloaded 59 times

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 10:04 pm

Thanks - I'll have look tonight. Better get back to the $JOB if I want any $MONEY!

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Thu Feb 20, 2014 11:52 pm

leenew wrote:Here's what I did.

*TAPE
LOAD"CASTLE"

DELETE 140 PAGE=&E00:CHAIN"CASTLE2"
140 LOAD CASTLE2 AT 1100 THEN RELOCATE TO E00 THEN RUN THE PROGRAM

MAKE A !BOOT TO LOAD THE CASTLE AT 7600

*LOAD CASTLE2 1600
*DISC
*SAVE "CASTLE2" 1600+6500

BOOT THE DISC

this should load CASTLE at 7600 which LOADS CASTLE2 at 1100 then relocates it to E00 and RUN it.

It appears to work but has errors in the listing for some reason, eg the OSCLI OSCLI appearing from nowhere?
What DFS are you using/where is PAGE? I'm guessing you are loading/saving it into DFS workspace, so when you save you get the contents corrupted as DFS uses the workspace.

BUT if you are using an E00 DFS, it won't be that.

CASTLE2 is &6500 long, so the lowest you can load it before hitting MODE 7 memory is going to be &1700 ... but that would still be in DFS workspace (up to &1900.)

UEF:

CASTLE 04 0500 E00 801F
CASTLE2 64 6500 E00 801F

On the DISC image, CASTldr is at &900, the main program (CASTLE) &1200.

Not sure how that would work with a non E00-DFS? Need to have a bit more of a look at
what's in DFS workspace - maybe you can get away with using some below &1900?

I'd guess the STH V1 disc image is corrupted - I tried loading the main program on a Master (where PAGE is &E00) and you get the same behaviour.

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Fri Feb 21, 2014 12:27 am

Hi
I load the first program at around &7600 and load the second part at &1100 then relocate down to &E00 where it is run.
As far as I am aware there is no problem with a normal &1900 page DFS loading one program in at &1100.
You can't do complicated stuff including #openin etc. but I haven't had problems before going as low as &1100 as long as it is for one program load.
Having said that, when I was creating the file on the disc image, I loaded it at &1600 and saved it to disc as &1600+6500.
Maybe the saving to disc when I have loaded at &1600 is causing some corruption? but I don't think so as it seems to work on the real beeb...

Lee.

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 12:28 am

What DFS are you using in Beebem vs the real BBC?

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Fri Feb 21, 2014 12:32 am

The real beeb has Acorn DFS 1.20 the same as Beebem.
The only difference is that the real beeb has page at &1700 with the datacentre fitted and Beebem is at &1900.
The way that it appears to me though, is that the corruption is occurring is occurring at or after the time I load it back from disc on Beebem.
The file does not appear to be corrupted when loading from the same disc image into the Beeb.

Lee.

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 12:35 am

Re. PAGE at &1100, dug out me old Pharo and he says ...

&1100-&11FF The Acorn DFS allows you to open up to five files ... This area contains information about the ... file buffers and their parameter blocks.

&1200-&12FF Buffer area for the first opened file.

&1300-&13FF Buffer area for the second opened file.

&1400-&14FF Buffer area for the third opened file.

&1500-&15FF Buffer area for the fourth opened file.

&1600-&16FF Buffer area for the fifth opened file.

&1700-&18FF Private Workspace Save Area. The DFS uses this area of memory to save its environment, if another paged ROM demands the memory area from &E00 to &16FF.

P. 114 - "... we can set page to &1300. We cannot sensibly reduce PAGE below this value."

But maybe we are not sensible ... :twisted:

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Fri Feb 21, 2014 12:38 am

Hmm... the great Pharo.... what about the legendary Albert Schofield :lol:
http://www.8bs.com/artt2d.htm

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 12:40 am

So I go into Master mode on Beebem.

Try the CASTLE image from the STH V1 disc - get the error.

Load the V2 UEF onto the Master, at E00.

Save that as CASTLE E00+6500 801F back onto the disc - then I can CHAIN it.

But not sure that I am proving anything by doing so - it might be an issue with V1.

What happens if you change your loader to use &1300 instead of &1100 - any improvement?

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Fri Feb 21, 2014 1:02 am

nope.
There's definitely something funny going on here.
I have tried loading castle2 in from the uef at a low speed (just in case?) on beebem at &1600 and saving it to disc as *save "castle2" 1600+6500 801f e00 then using a very short loader at &7b00 which *loads castle2 at &1600 and relocates to &e00 but I get the oscli oscli errors :?
Can't figure out when the corruption is occurring?
Anyway I must leave it until tomorrow. It's 1 a.m. here and my eyes don't seem to be working anymore :shock:

Nighty night :D

Lee.

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 1:03 am

We'll get there!

It's a Castle of Riddles, alright! :lol:

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 3:05 am

richardtoohey wrote:Save that as CASTLE E00+6500 801F back onto the disc - then I can CHAIN it.
So then I go back into BBC B mode, and ...

*LOAD CASTLE 1100
FOR I%=0 TO &6500 STEP 4:I%!&E00=I%!&1100:N.
PAGE=&E00

And run it - and it works on Beebem.

So this CASTLE file is CASTLE2 off the UEF of V2.

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 3:34 am

So here's my CoR with a very simple loader - this works for me on Beebem ... just going to try on a real BBC now.

It needs you to press F1 and it does a slow BASIC move and then does a LIST before a RUN ... if I didn't do the LIST - the RUN did not work!

Obviously not saying this is the solution - just asking if it works for you, Lee? If so we can pretty it up!

I've not tested it past the I and E key presses.

Works on my real BBC as well. HOW DO I TURN THE *@#!# LAMP ON?!! (EDIT: looked at the CoR box and there it was "ON" it says ...)
Attachments
CoR.zip
Fudged Castle of Riddles
(14.05 KiB) Downloaded 55 times

User avatar
billcarr2005
Posts: 1094
Joined: Fri Sep 09, 2005 3:01 pm
Location: UK
Contact:

Re: Castle of Riddles.

Postby billcarr2005 » Fri Feb 21, 2014 4:25 am

richardtoohey wrote:It needs you to press F1 and it does a slow BASIC move and then does a LIST before a RUN ... if I didn't do the LIST - the RUN did not work!

if you issue an OLD, instead of LIST, then it'll work fine (at least it did here!)

Here's an attempt i made. Messes up the logo on load, because i didn't want to drop any lower than &1700.
Attachments
CASTLE OF RIDDLES V2.zip
This gets past the I + E key presses too
(14.32 KiB) Downloaded 57 times

User avatar
richardtoohey
Posts: 3378
Joined: Thu Dec 29, 2011 5:13 am
Location: Tauranga, New Zealand

Re: Castle of Riddles.

Postby richardtoohey » Fri Feb 21, 2014 6:09 am

Yep, that works. :D

I tried replacing the CASTLE file on the STH disc with one I had saved from the "Master" - definitely see what Lee is seeing - corruption on load on a BBC:

Arguments at line 2085

2085IFRPEVAL',R(194)...

Should be

2085IFNOTFNRP(R,6)

Load exactly the same file in the Master - it's fine - so the file on disc is fine, but when it gets loaded in at 1100 or 1200 ... unhappiness results.

User avatar
1024MAK
Posts: 6786
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...

Re: Castle of Riddles.

Postby 1024MAK » Fri Feb 21, 2014 8:53 am

So the corruption is due to values being stored in the Beebs RAM which are overwriting parts of the program code. Most likely due to the DFS writing to what it considers is its allocated space.
If you work out which memory addresses are affected, then off set the loading address by say two bytes, the corruption should also move within the program.

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

User avatar
leenew
Posts: 3394
Joined: Wed Jul 04, 2012 3:27 pm
Location: Doncaster, Yorkshire

Re: Castle of Riddles.

Postby leenew » Fri Feb 21, 2014 12:25 pm

Morning!
After a good night's sleep I have tidied this up, so now we have V2 on disk with a tidy loader.
I am still convinced the corruption is Beebem related and does not happen when trying it on a real beeb.
I am positive that BITD I would regularly go as low as &1100 for loading very big programs in. As long as the disc wasn't needed after that load then everything worked. (Or that is my memory anyway :D )

Anyhoo,
What I ended up doing on Beebem was this:

*load the main program at 1900 from the UEF.
Being &6500 long, it overruns the screen a bit but that is OK for now.

Save to disc 1900+6500
This should be uncorrupted now.
Even loading at &1700 it would corrupt, and I am certain that isn't supposed to happen? :?

Anyway, the 6500 file should be on disc now, uncorrupted.
Next, I created a !BOOT that sets PAGE at &7B00
The Acornsoft logo is &100 above PAGE so it conveniently loads perfectly onto the screen 8)
The loader just has to be less than &100 long obviously.
so, all it does is *LOAD it as high as possible without corrupting the loader, which is &1600
Then a simple relocater drops it down to &E00.
Then I set *KEY0 to do PAGE=&E00, OLD, RUN and a virtual keypress with *FX138,0,128

This seems to be fine.
I can't remember the ins and outs and do's and don'ts of loaders, but I am sure Mick can chuck a few FX15's at it, or whatever else he does!

Castle.zip
(40.94 KiB) Downloaded 63 times


Lee.


Return to “archive issues”

Who is online

Users browsing this forum: No registered users and 1 guest