I’m working on a project that models talking to NPCs on the radio so the player can instruct characters in another location to do things. The idea I had was to allow for some commands to start and stop radioing another character (similar to the section on telephones in the Inform documentation), and then whenever the player is having a conversation with someone, they can type normal commands and they will be interpreted as instructions for the character they are talking to.
Here’s how I imagine it to work:
>radio john
You tap on the mic and lean in. "John, this is HQ, do you copy?" After a few moments his response is picked up by the receiver. "This is John, go ahead HQ."
>l
"Can you tell me what you're seeing John?"
"I'm over by the old public docks near the cove. The beach runs along to the north, and I can barely see the tree line to the east from the water. I've got the Jeep parked in the lot to the south."
"The weather is beautiful out here today, by the way," he adds. "I'm glad I'm not cooped up in the office like you." You wrinkle your nose as you hear him chuckle.
>x docks
"They're run down as ever; I think a couple more boards have fallen off into the ocean since I was last here. We really need to rope off this area."
I thought of a couple different ways of doing this, but there are drawbacks to each and I’m just wondering what people think would be best (I’m not particularly experienced with writing IF):
- Use an “After reading command” rule to change the command to “[the person being radioied], [the player’s command]”. This literally turns each typed command into an ask action. Issues are I have to untransform any meta-radioing commands (like hanging up) since I can’t tell what they are before they’re parsed, and I’m not sure what happens when someone types a command that is already an ask action (so it ends up as “John, Kate, x trees”). This is what I have now and it seems to work but I feel like I’m going to hit unforseen issues. Positives are that I can easily write report rules for NPC actions with whatever conditions I want, and everything goes through persuasion rules in case I want to use those.
- Parsing the action and then changing the person asked to the person being radioied in a “before doing anything” rule. The nice thing about this is that I can run an activity from that rule so that I can distinguish between the player radioing someone to do something and the player asking in person or the NPC doing stuff on their own. I couldn’t really get this to work all that well though…
- Just forget all of this try asking trying doing something stuff and switch the viewpoint character to the person being radioed. Changing action reporting makes it seem to the player like you’re talking with this character on the radio, but the game just interprets your commands normally because you’re actually that other character. I also don’t have to worry about changing scope, although I think I’ve figured that out at this point anyway. This might be easiest in the end, but I wanted to give the more “true to the story” approach a shot.
Any ideas on this one? Thanks for your help!