Jump to content
IGNORED

Questions thread


STGraves

Recommended Posts

Now I understand how it works, but I have one more question, can pfread be used to check specifically the top row of the playfield, instead of a single pixel at a time, I want to use it for sort of collision detection with the top row in particular but no for stopping the character from going through it, instead I want to use it to trigger a goto another screen, well actually not to another screen but to the previous one, kind of like going back and forth between 'em, do you think that using a counter that adds 1 every time you go to a new screen and substracts one when you return to the previous one, for cycles counting, or RAM saving?

Link to comment
Share on other sites

Now I understand how it works, but I have one more question, can pfread be used to check specifically the top row of the playfield, instead of a single pixel at a time, I want to use it for sort of collision detection with the top row in particular but no for stopping the character from going through it, instead I want to use it to trigger a goto another screen, well actually not to another screen but to the previous one, kind of like going back and forth between 'em, do you think that using a counter that adds 1 every time you go to a new screen and substracts one when you return to the previous one, for cycles counting, or RAM saving?

 

You could use the playfield variables to detect pixels more roughly. As in, if var0 > 0 then you know one of the eight first playfield pixels is set.

Link to comment
Share on other sites

I've tried the player1 coordinates to trigger them but it just causes the game to glitch, crash or reset, I'll try theloon's method if my current one doesn't succeed, I find out that if you use a counter it works wonderfully, instead of triggering the gosub with the coordinates I trigger it with the counter's value which changes depending the coordinate of the player, I made one for "Y" and one for "X", and whenever the player moves to a specific coordinate depending on if it's the X axis or the Y axis, and depending on the current value of the counter is which screen has to be triggered.

Link to comment
Share on other sites

I've tried the player1 coordinates to trigger them but it just causes the game to glitch, crash or reset . . .

If checking sprite coordinates caused a game to crash or reset, most bB games would be crashing and resetting. It's probably just buggy code.

Link to comment
Share on other sites

Perhaps but bblint doesn't show me any error at all, and besides my method worked very nicely without issues, all it needs is a bit of tweaking in order to work with even more screens, with 5 it works great.

If using something that everybody else uses without a problem causes problems for you, you're doing something wrong. There doesn't have to be an error that bblint can see.

Link to comment
Share on other sites

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...