Is there a difference between “print nothing” and “do nothing” - do nothing might remove the comma if I’m guessing correctly that “print nothing” means “show a blank” rather than “do nothing” which would seem to mean “don’t do the whole process” that includes the comma?
A printing-the-name rule cannot remove the comma in a list of objects. Once you’ve got as far as printing the name of the object, the list writer has already decided what the list contains and where to put the commas and "and"s.
To riff on Zarf’s suggestion, you can define Karl as “undescribed,” which will cause him to be left out of room descriptions (like scenery) but won’t change any of the responses.
You should be able to write “if the current action is not opening the door:”.
In this case, though, you really want to put the condition in the header of the rule. Otherwise the “After doing something” rule will always fire… and “After” rules by default cut off the processing of the action before you get to the Report rules, so this will cut off even the processing of your special action. You could write:
After doing something when the current action is not opening the door:
or much more succinctly
After doing something other than opening the door:
See Section 7.9 of Writing with Inform. (Also, you might want to put some other restriction on the rule, because I’m not sure you’d really want this to happen when someone does absolutely anything other than opening the door in the entire game.)
Don’t put an After rule inside an Every turn rule. Those are two separate kinds of rule.
Using “After” and “continue the action” should accomplish what you want. “After” runs after the action so it’ll run for every action when the player accomplishes something other than opening the door.
Though it doesn’t run when the action gets cut off by an Instead rule, or a Check or Before rule that fails, so it won’t run absolutely every turn. If you want something that runs even on those failed actions, you could try this:
Every turn when the player is in the Lab: [you really want a specific room name here instead of "when the player is in room"]
if the current action is not opening the door:
now the relay is switched off.