Jump to content
IGNORED

Compiler Error: FASTFETCH 0000 ???? (R )


Recommended Posts

Hello,

 

Today I have a compiler error that I don't understand.

This is for my Weekend Project:

 

 - Car Racing 

 - 10 Playfields with scrolling. 

 - _change_room (street) will use bank 2 for more free space.

 

what am I doing wrong? Who can me help me?

 

Bye

Erik

 

 

 

ca1.bas

Link to comment
https://forums.atariage.com/topic/330812-compiler-error-fastfetch-0000-r/
Share on other sites

 

 

Take a look at the section called Bankswitching:

 

https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#bankswitching

 

If you're going to use "set romsize 16kSC" you need to have the correct number of banks.

 

Also look at your dims. Only reuse variables if they're not going to interfere with each other. For example, you can use the same variable with different aliases in your title screen section, the main loop, and your game over section. But you can't use "dim room11_generator = f" and "dim p0_X = player0x.f" if those variable aliases are going to be used in the main loop. If you think of the variable f as a box and you put 10 kittens in it, then you put 2 owls in the box (thinking it's a different box), you're going to have a mess.

 

If you're using Visual batari Basic, you can right click on the code and select Audit Variables. It will give you a compact list of all the variables used in the program (if you've used dim to create aliases).

 

It also looks like batari Basic doesn't like playfield data shoved into if-thens.

 

I got the code fixed up enough that it will compile:

 

ca1_2022y_02m_04d_1509t.bas

  • Like 1

Hi - I gave it a try, and the actual error that was causing the issue was "branch out of range". You are defining playfields in the midst of an if/then statement, which usually works okay, but it doesn't in one case because the playfield is too big.

 

TL;DR instead of this code:

 

 if current_room_number = 10 then playfield:

You need something like this:

 

 if current_room_number <> 10 then goto _skip_room_10

...and then put the _skip_room_10 label after the "end" of the playfield definition.

 

Edit: Yeah; what RT said. Defining a playfield after a "then" sometimes works, but it's bad practice, and can sometimes cause problems like what you have seen

 

 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...