Thanks for the help guys.

Code:
function readfile(STRING* filename){
	
	STRING* test_str = "###";

	int count;
	int eof = 0;
	var fhandle;
	
	if ( (fhandle = file_open_read(filename) ) == 0) {
		return NULL;
	}
	
	fhandle = file_open_read (filename); // Opening file
	
	count = 0;

	while(eof != -1){
		eof = file_str_read(fhandle, test_str);
		(dialog_file.pstring)[count] = test_str;
		//dialog[count] = test_str;
		count += 1;
	}
	
	node1a = (dialog_file.pstring)[1];
	file_close(fhandle);
}


Assume there is a text array for "dialog_file" defined already.

When I do the code above, when I call node1a, it's the same string (always the last string in the file), no matter what index I call from the text array. For the life of me I can't find where the kink is. The code above seems like it should work.

Last edited by silencer; 03/27/09 14:29.

AMD 64 x2 4400+ 2048mb DDR3200 NVidia 6800GS 256mb Soundblaster Audigy 2 A7 Commercial 7.07