This is an archived, read-only copy of the United-TI subforum , including posts and topic from May 2003 to April 2012. If you would like to discuss any of the topics in this forum, you can visit Cemetech's TI-BASIC subforum. Some of these topics may also be directly-linked to active Cemetech topics. If you are a Cemetech member with a linked United-TI account, you can link United-TI topics here with your current Cemetech topics.

This forum is locked: you cannot post, reply to, or edit topics. TI-Basic => TI-BASIC
Author Message
Raylin


Newbie


Joined: 05 May 2008
Posts: 15

Posted: 26 May 2009 09:38:36 am    Post subject:

Yo!

I need help.
I was wondering, with all these RPG's on the calculator scene right now, how do you efficiently store multiple monsters?
Like Pokemon, you got 151 unique Pokemon to choose from!
And you only have 24K RAM / 1.5M ARCHIVE to stuff them in.

How do you do it?
Back to top
dxfan101010


Member


Joined: 31 Mar 2008
Posts: 194

Posted: 26 May 2009 09:45:57 am    Post subject:

they us strings and list and have subprograms that are archived and unarchived

Last edited by Guest on 26 May 2009 09:46:28 am; edited 1 time in total
Back to top
Raylin


Newbie


Joined: 05 May 2008
Posts: 15

Posted: 26 May 2009 09:48:11 am    Post subject:

Can anyone of higher experience give me an answer?
Back to top
Eeems


Advanced Member


Joined: 25 Jan 2009
Posts: 277

Posted: 26 May 2009 09:59:16 am    Post subject:

you can use lists and strings to store it. The best way would be to have a program fill a list depending on what monster you are using and then the battle program would interpret it.
BTW that last comment was rude and I think you should apologize. Even if he isn't that experienced doesn't mean you have to bash him about it with comments like that
Back to top
Mapar007


Advanced Member


Joined: 04 Oct 2008
Posts: 365

Posted: 26 May 2009 10:02:02 am    Post subject:

postcount is not equivalent to experience...

I'd use asm to store into compressed appvars for the database, and use Eeems advice for the interpretation.
Back to top
Eeems


Advanced Member


Joined: 25 Jan 2009
Posts: 277

Posted: 26 May 2009 10:28:34 am    Post subject:

it's true that post count does not count as your experience, because you never know, this may be their first time on this forum but not others, for instance I only have 52 posts here, but I have over 596 posts in total on all the forums I am on. I have just started on UTI, but I mainly am on Cemetech and recently on Omnimaga.

Last edited by Guest on 26 May 2009 10:29:04 am; edited 1 time in total
Back to top
Galandros


Active Member


Joined: 29 Aug 2008
Posts: 565

Posted: 26 May 2009 11:52:30 am    Post subject:

Raylin wrote:
Yo!

I need help.
I was wondering, with all these RPG's on the calculator scene right now, how do you efficiently store multiple monsters?
Like Pokemon, you got 151 unique Pokemon to choose from!
And you only have 24K RAM / 1.5M ARCHIVE to stuff them in.

How do you do it?

Ever heard about CelticIII?

It can store and read data from programs... It stores in some kind of string. I don't know how it works.
I never used read all documentation or used but I do know it has interesting features for that.
Back to top
Mapar007


Advanced Member


Joined: 04 Oct 2008
Posts: 365

Posted: 26 May 2009 01:09:36 pm    Post subject:

Well indeed, you could get some program (de)compressor (I think you can find some on ticalc.org) and use celtic for reading the files.
Back to top
Raylin


Newbie


Joined: 05 May 2008
Posts: 15

Posted: 26 May 2009 01:23:46 pm    Post subject:

You guys are overreacting about my last post. Jesus.

I didn't mean no harm.
I just meant someone like DarkerLine or Weregoose to comment.
(If you haven't noticed, I have 12 posts.) Neutral
Take it easy.

In any case, yeah. The program idea sounds good.
Any others?
Back to top
dxfan101010


Member


Joined: 31 Mar 2008
Posts: 194

Posted: 26 May 2009 02:10:10 pm    Post subject:

no offence taken i was and am at school so i answered quickley>(teachers dont like forums) and i just said how i knew they did it.I am not very good with list yet so yeah.
Back to top
ticalcnoah


Member


Joined: 28 Oct 2007
Posts: 153

Posted: 26 May 2009 02:29:46 pm    Post subject:

I would suggest using celticIII's det(5 command it reads lines from the program and if you combine it with lists you can create massive ways to store data.
Back to top
simplethinker
snjwffl


Active Member


Joined: 25 Jul 2006
Posts: 700

Posted: 26 May 2009 03:18:29 pm    Post subject:

Raylin wrote:
Yo!

I need help.
I was wondering, with all these RPG's on the calculator scene right now, how do you efficiently store multiple monsters?
Like Pokemon, you got 151 unique Pokemon to choose from!
And you only have 24K RAM / 1.5M ARCHIVE to stuff them in.

How do you do it?

Right now I'm working on a project (using Celtic III, but most of the methods can be used by xLIB with some tweaks) where my estimates for overall data size will be ~160KB (though it's not for monsters). There are two types of data that comprise the majority of that figure: map/level data and text.

Here's how I store the map/level data: I need to store the map data (most will be 2048 character-long strings), starting position (two two-digit integers), number of chips (three-digit integer), and time limit (three-digit integer). This is all stored in two strings that's placed inside of a program. The first line is XXYYCCCTTT (where XX is the x-position, YY is the y-position, etc...) and the second line is the map string. Overall, the data (in storage) for one level takes up 2060 bytes, so I group the data for five levels into one program.

Accessing map/level data: Based on the level number, I decide which program to read from and which lines to get. I then use Celtic III's det(5 command (LineRead) to get the line containing the numbers as integers. I just use the normal sub( and expr( commands to get/store the correct values to the relevant variables. I then read the next line (holding the map data) and convert it to the relevant format (I'm currently using Celtic III's real(2 command which needs matrices).

Storing text: The text itself as well as a two-digit number and the number of lines (one-digit) need to be saved. As with the level data, I put them in a string of the form AAN and place it on the first line. The next four lines will contain the text, and if the text isn't four lines long I just leave the lines blank. One program contains the data for 10 levels.

Accessing text: Again, based on the level number I determine which program and which line the data is in. I extract the two numbers and draw the relevant boxes and stuff, then read and display the relevant number of lines.


These methods could be easily adapted for storing monster data or whatever. If you want to see the actual code for this, here's a link to the latest demo. That version uses a different system for map/level data, but in programs CHIPWAIT and ZTIPS you can see it used for the text. (As I look over my post, the process for the map/level and text data are actually basically the same).

Hope this helps Very Happy


Last edited by Guest on 11 Jul 2010 03:18:56 pm; edited 1 time in total
Back to top
Display posts from previous:   
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
    »
» View previous topic :: View next topic  
Page 1 of 1 » All times are UTC - 5 Hours

 

Advertisement