main program never goes into those cases; it checks for that case before ever calling my function.
Doesn't that mean the exception is useless?
Do I actually have to do the exception part?
inBounds member function like a Grid has?
inBounds function; you will need to check the index manually yourself using if/else statements.
You can ask for the size of any vector, including a vector that is nested inside of another vector.
If you are certain that you do not have infinite recursion, it is possible that there are just too many calls on the call stack because you are filling a very large area of the screen. If you tried to fill the whole screen with the same color, it might crash with a "stack overflow" even if your algorithm is correct. This would not be your fault.
Map store?
stringSplit function. Print lots of debug messages to make sure that your split calls are doing what you think they are.
trim function to remove surrounding whitespace from strings.
string instead of reassigning it.