
-----------------------------------
Hack.saw
Fri Jun 16, 2006 9:57 am

Reading Text Files
-----------------------------------
Hehe half my posts are me asking for help... Anyway I saw a game where every class of the RPG had its stats or w/e written down in text documents which turing read.  Sooo I set to reading the tutorial on it but all it did was give me a head ache  :(  I read it like 30 times over and tried to do exactly what it said but it still didnt work.  Anyways is there anyone here who could explain to me step by step how you would get info from a text doc for lets say... an item used in a game.

-----------------------------------
Delos
Fri Jun 16, 2006 11:47 am


-----------------------------------
Only 30?  That's no good.
Anyway, please post up your code so we know where to start.  It's not use anyone giving you 'step-by-step' instructions starting from the definition of a variable downwards if you already know that stuff.  Conversely, starting from the definition of an input stream might confuse you too - it all depends on how far you've progressed.  We'll only know this from your code.

As for the [url=http://www.compsci.ca/v2/viewtopic.php?t=5]Tut by Dan, I don't see anything wrong or confusing with that Tut.  It's about as step-by-step as you can get!

-----------------------------------
Hack.saw
Fri Jun 16, 2006 3:57 pm


-----------------------------------
LOL, just deleted all the code cause i figured i must have done something wrong a couldnt find, so i was gona try and start over from scratch, anywho his tut wasnt confusing andhad enough info  its just when I tried to do it i could never get it to work... This is basically what i had before:

var stremin :int 

open: stremin, "item", get 

loop 
      exit when eof (stremin) 
      get: stremin, nums%