Today I spent many hours making a program that allows the user to create homescreen maps for BASIC programs. Not just regular crappy maps, of course, but scrolling maps that use strings. It's actually pretty cool and I'm pretty proud of it, so check it out here. Cool
Good job! I remember having fun with that as well when I messed around with that idea a little more than a year ago. If you don't mind me suggesting it, the scrolling map would look better if you built a 128-character string and then displayed it instead of outputting one row at a time.
Interesting. I still need to figure out how to make my scrolling engine idea dynamic enough to work for pokemon...
I've been programming for about 2.5 years now and I just figured this mapping stuff out a couple weeks ago. Here's my output code, where P is the number of rows in the map and Q is the number of columns:


Code:
:1→A
:Repeat Z=45
:For(B,1,8
:Output(B,1,sub(Str0,A+QB-Q,16
:End
:Repeat Z
:getKey→Z
:A+(0≠fPart((A-Q+15)/Q))(Z=26)-(0≠fPart((A-1)/Q))(Z=24→A
:A+Q(A<PQ-8Q+1)(Z=34)-Q(A>Q)(Z=25→A
:End
:End


I explain everything in my tutorials.

Hmmm... I never thought about displaying a 128 char string... Output( does wrap... The map would be displayed quicker, but wouldn't the overall program speed be the same once you stored the 128 chars into another string and then output it?
It would look nicer Razz Atleast it will do it all at once, not partially
Yeah, the two methods don't differ to much, I guess. The downside to buffering like this is that you can't change the display's row size, nor can the graph screen be used as an alternative.

Just in case you choose to use the way of which I spoke, here's some possible code you could use (I'll bet you already know how, but I was bored Razz ):


Code:
:1→A
:Repeat Z=45
:sub(Str0,A,16
:For(B,2,8
:Ans+sub(Str0,A+QB-Q,16
:End
:Output(1,1,Ans
:Repeat Z
:getKey→Z
:A+fPart((A-Q+15)/Q)(Ans=26)-(Ans=24 and fPart(Q^-1(A-1→A
:A+Q((A<PQ-8Q+1)(Z=34)-(A>Q and Z=25→A
:End
:End
I usually do scrolling maps with a bunch of lines, and just change the x and y min and max values to move =/ im pathetic. lol. however im implementing it in my port of line rider to BASIC... dunno how fast itl run.
Did you use Dan and my's program for the characters, by any chance? Smile
I scoured ticalc.org for programs with the extra characters and I believe I used mostly this one. Sorry. Razz

I'm still looking for some of the characters displayed in this program, like the different cursors. And I'm pretty bad at assembly (no time to learn with school!), so I don't know where I can get them. Any ideas?

And also, I'm working on the row editor... lots of homework for the next few days, so I'll probably finish it this weekend.

EDIT: Woot! 75 posts... New Member!
Heh, took you long enough... Razz (0.29 posts per day)

Anyway, those can't be used in BASIC programs because there's no tokenized character for them. Sorry.
I added the row editor, so now everything is fully functional. Very Happy In the next version (which should be released within a few days), I will change the map outputting algorithm to something similar to what was suggested above. I will also do some optimizations to save memory and (hopefully) increase speed. You can download this latest version here. If you find any bugs or have any suggestions, please post them.
  
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