Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


A could-be speed/performance issue...


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
5 replies to this topic

#1 3DNeophyte   Members   -  Reputation: 122

Like
Likes
Like

Posted 07 February 2002 - 01:57 AM

In my text-RPG for Visual Basic, I''m using a class called "Location" that stores all the text-based information for an area of the game. So far, that should work. Well, I''m wanting the program to initialize all the zones in the game upon startup. I''m thinking of having the entire initialization process contained within the main form (which would result in a mile or so of zone information in my code due to having all the text stored there...), but I''m also thinking of another option where the intialization procedure accesses a text file from which zonal information is passed along to my location objects. So my question is this: Which would be more optimal for the program - to have all the information processed within the program only, or to have the program fill in all the object information from a text file? If anyone can offer their advice, I would appreciate it greatly. If I''m not being completely specific in my information, I''ll add some pseudo source code to illustrate my problem. Thank you ''''Math is useless'''' - who the hell has ever said that!?

Sponsor:

#2 DaJoostMan   Members   -  Reputation: 122

Like
Likes
Like

Posted 07 February 2002 - 03:10 AM

Well including the text in ur program would be faster but considering u are using a text based rpg and using vb i''d say speed is not the issue here.
Including ur text in a file has the benefit of easy editing. If u later want to change something u wont need to recompile everything.
There is also the security. Do u want users to be able to easily read and/or edit ur story. If u use a text file that will be very easy to do. including it in ur program will eliminate that.

Hope i helped,
good luck

#3 3DNeophyte   Members   -  Reputation: 122

Like
Likes
Like

Posted 07 February 2002 - 04:40 AM

Thanks for the reply. I''m leaning towards the text-file route. Concerning security of the file, isn''t there a way to prevent people from easily accessing a textfile, like encryption or something? I''ll look into it; but if you or anyone else knows how to do it, please tell me - it''ll save me some time

#4 EvilCrap   Members   -  Reputation: 134

Like
Likes
Like

Posted 07 February 2002 - 06:33 PM

textfile, all the way. if you have ''miles'' of text hard coded in your program, you get problems, here are some i can think of:
1) compile-time editing only.
2) Program size : a HUGE program loaded into memory all at once...

#5 3DNeophyte   Members   -  Reputation: 122

Like
Likes
Like

Posted 07 February 2002 - 11:36 PM

Thanks for reinforcing my decision, Evil. I don''t know if it will be "miles" as I previously said, but it sure will be a lot - think of Dungeons and Dragons'' Faerun in the Forgotten Realms converted completely into text. I''m implementing file reading functions in my program right now, so text-files it is. Thanks

#6 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

Likes

Posted 12 February 2002 - 05:36 PM

Isn''t this the Size vs speed issue? Choose one.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS