I've been writting a text adventure game and need help with array manipulation. My problem is that I have it so an item and/or monster will be specified to be placed in a certain sector within the array. Lets use a ghost and graveyard for the example....
I just want the program to understand that the graveyard is the
only place that the ghost can roam. How do I get it to understand that The Graveyard is where it can go, not...[0][1], [0][2], [0][3], [0][4],ect...............
How can the program read an array's text (char) information and not the action numbered sectores ([1][3])
To help understand......
My array is set up like so....
...
text[0][51][0] = "Dragon Fields";
text[1][51][0] = "Dragon Fields";
text[2][51][0] = "A pond";
text[3][51][0] = "Dragon Fields";
text[4][51][0] = "A old-looking tree";
text[5][51][0] = "A cabin";
text[6][51][0] = "Dragon Fields";
...
Once again, how can the program read I want a dragon roaming in sectors [0][51], [1][51], [3][51], and [6][51]. I just want to put in statment that will tell them that "Dragon Fields" is the only place they can roam. I would do it the other way but this is a 10,000 sector array and would take me forver to enter each sector. Thankyou for your time. Hope you can help.