Jump to content
IGNORED

Easiest way to clear all sprites at once?


eddhell

Recommended Posts

I'm sure it's a newbie type question, but what is the easiest way (or fastest frame-wise) to 'turn off' or clear all sprites from screen at once in Intybasic?  (I'm sure there's much faster ways in ASM)

 

best I could come up with is:

 

FOR x = 0 to 7

  SPRITE x, 0

NEXT x

 

(*0 = zeros)

 

but is there a single line command i'm missing out on?

Edited by eddhell
Link to comment
Share on other sites

  • 3 weeks later...
On 11/29/2019 at 2:03 PM, eddhell said:

I'm sure it's a newbie type question, but what is the easiest way (or fastest frame-wise) to 'turn off' or clear all sprites from screen at once in Intybasic?  (I'm sure there's much faster ways in ASM)

 

best I could come up with is:

 

FOR x = 0 to 7

  SPRITE x, 0

NEXT x

 

(*0 = zeros)

 

but is there a single line command i'm missing out on?

No single command. Make sure that you have "Include Constants.bas" at the top of the main program you are writing, then you can use ResetSprite(x) from it to clear things out. HTH.

  • Like 1
Link to comment
Share on other sites

from the get go, I could not get the include statement to work, compiler says it wasn't found or something, probably some path problem I just haven't cared to track down.....(although it IS in my working folder - c:\intybasic).

I've completely worked around not having the constants file and I don't want to go back and redo everything (already around 23k rom after compiled).

Link to comment
Share on other sites

On 12/19/2019 at 9:32 AM, eddhell said:

from the get go, I could not get the include statement to work, compiler says it wasn't found or something, probably some path problem I just haven't cared to track down.....(although it IS in my working folder - c:\intybasic).

I've completely worked around not having the constants file and I don't want to go back and redo everything (already around 23k rom after compiled).

 

It's a classic debate whether to include stuff centrally or have it local to the "thing" you are working/building. For IntyBASIC, I keep constants.bas in the same local directory as my main .bas and other files: disk space is not a problem and I have tweaked it a few times for different reasons and I don't want them to pollute each other.

 

YMMV, but constants.bas is "required". It will make it much easier for the developer that has to look at your code 3 months from now, because that will probably be you...

 

Link to comment
Share on other sites

14 hours ago, First Spear said:

 

For IntyBASIC, I keep constants.bas in the same local directory as my main .bas and other files: disk space is not a problem and I have tweaked it a few times for different reasons and I don't want them to pollute each other.

 

I thought i was doing the same thing....

 

14 hours ago, First Spear said:

 

YMMV, but constants.bas is "required". It will make it much easier for the developer that has to look at your code 3 months from now, because that will probably be you...

 

that would be nice, but i'm stuck to the choice of spending time trying to get constants.bas included and working, or spend all that time actually writing some code....

it's probably all based around some problem with wacky windows and user settings/permissions/paths/privileges etc...hell i dunno anymore, if i just had an old 80486 DOS machine, everything would be just fine.

Link to comment
Share on other sites

If IntyBASIC can find intybasic_prologue.asm and intybasic_epilogue.asm, it should be able to find constants.bas.  An IntyBASIC compile won't succeed if it can't find intybasic_prologue.asm and intybasic_epilogue.asm.  Try copying contants.bas to the same directory as those two files?

 

 

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