Scripting can be as complex or as simple as you make it.
With highly text scripts, it's a good idea to use code markers, for when your loading the script in. Best example might be rooms - how are you going to organise your rooms?. Well firstly it's fairly obvious that your not gonna print this stuff with code, that's far too fiddly - you want to enter your room descriptions freely in a script. So if you used \ to signify the end of a particular block of text, like room description, you could use that to highlight the start too. For example:
\room:garden_shed
This is a garden shed - or at least the text bit of it.
\
Then if you find a '\room', grab the room name and store it in a variable and the text in the script file is room description, which you could load into an array until it finds a '\'. Simply checking the first 7 characters for these '\room:' style commands, I use this for everything. My items are specified after room descriptions and have their positions set depending on what room they are after, there's a few tricks that make adventure writing more fun.
Even word replacements are handled in the script, like I have this bit of script:
\word:G
\also:GET
\also:TAKE
\also:GRAB
So when parsing the player input, I split it into words and store them all in an array. Then I run each word through a check that just compares the word with convertable words in the list, so GET, TAKE, and GRAB all get converted to a simple 'G'. I did this with a double string array, like WORD$(256,1) - where indice 0 is for the word, and indice 1 is for what it is converted to.
Consider how much coding a simple system like that will save in the long run, and it is like a steroid shot to your parser, things are so much neater when you can use minimal command strings like N for North, D for Down, G for Get, I for Inventory, even X for examine is a good one.
I also have a special character '#'. I use this to signify script code, not done to much with this yet, but it loads these in as if they were text and assigns them to their room number - so I just have that character and my own IF conditioning system, and specific special commands can be added to rooms too. I plan to write the whole thing in the script language, something I've never done is make a fully codable script system and text adventures can exist on minimal functions, so is a good project to try this on (already have DarkAI, like a lot of people I'm using this as a justification to write a text adventure
- something I've wanted to do again for years, but always disregard for whatever reason).
Aegrescit medendo