Hey, I recently learned ICE and have been toying around with displaying sprites in certain ways.
Problem #1:
I'm not sure how to scale a sprite. I've been using
det(58,det(89,<sprite_name>,<output_name>,0,2),10,10))
but this command is only resetting my calc. How can I scale a sprite without doing that?

Problem #2:
Is there an easier way to make sprites? I use spritecreator on-calc, store it in a string, then type it in by hand into an asm program using
minY16,16,"<sprite_text>"→SPRITENAME
Can this be done in a faster and easier way?

Thanks for the help!

Edit: I solved problem 2, but I still need help with problem 1.
You need to allocate memory using DefineSprite() before scaling sprites. Allocate the data field by making a blank sprite and storing the pointer to it, then do what you tried earlier again. Or you could just use det(62 or 63.

For sprite creation, the best option in my opinion is calclover2514ís rewrite of Samís ICE sprite creator. Once youíve made a sprite, use Rcl to insert it into your program instead of typing it out by hand (2nd->Sto->vars->string->whatever string you exported to).

Download here: https://www.cemetech.net/programs/84pce/asm/graphics/ICESpriteCreator.zip

I hope this helps. If you have any more questions, Iíd be happy to answer them.
Thanks! What is the syntax for DefineSprite()? I just used DefineSprite(14,16)→<name>.
Edit: Yeah, I just used det(63 instead...
Thatís correct syntax. Then use the pointer as PTROUT. Just donít put anything inside, and youíll be fine. By the way, sprites are length x width + 2 bytes in size.
Argus wrote:
Thanks! What is the syntax for DefineSprite()? I just used DefineSprite(14,16)→<name>.
Edit: Yeah, I just used det(63 instead...

You can find syntax for all of the commands, as well as all of the command names here.
https://github.com/PeterTillema/ICE/blob/master/documentation/commands.html

Or (self promotion), you can use my ICE Commands program for an on-calc documentation.
Yeah I have been using ICE commands on calc and it's been a huge boost to speed up my progress. Thanks for the help!
epsilon5 wrote:
Thatís correct syntax. Then use the pointer as PTROUT. Just donít put anything inside, and youíll be fine.


That's weird, cause the compiler still returns an error for me. The exact code I have is

Code:
DefineSprite(14,16)→CURRENTSPRITE

and I'm not sure why it won't work. It might be because I typed the command in by hand, because it's not an on-calculator command.
This may sound obvious, but do you have ICE installed on your calc? If you do, press TRACE to open the commands list, and then select the one you want.

Download ICE:
https://www.cemetech.net/programs/84pce/asm/programs/ICECompiler.zip

I hope this helps. Feel free to reach out if you have any more questions.

EDIT- Your code wonít work if you either donít have ICE on your calc or if you donít select your command from the aforementioned menu.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement