Attaching a Cable (adv3lite)

Never mind – solved it after asking for help (as usual).

As an aid in scrutinizing this problem, here’s an entire test game file (create a new adv3lite game in Workbench and paste this into the code file):

[code]#charset “us-ascii”
#include <tads.h>
#include “advlite.h”

versionInfo: GameID
IFID = ‘c503fe59-6a7b-439c-9a62-e6e1cde5d98b’
name = ‘ConnectionTest’
;

gameMain: GameMainDef
initialPlayerChar = me
;

startroom: Room ‘The Starting Location’
"There’s a big heavy machine here. "
;

  • machine: Heavy ‘big machine’
    "It’s a big heavy machine. A cable dangles from one side. "
    ;

++ cable: Component, Attachable ‘cable’
"The cable is dangling from the side of the machine. "
allowableAttachments = phone
;

  • me: Thing ‘you’
    isFixed = true
    person = 2
    contType = Carrier
    ;

++ phone: PlugAttachable, Attachable ‘phone’
"It’s your cell phone. "
;[/code]
And here’s the humorous output. Note the use of “plug” and “unplug” in the library’s output, despite the fact that PlugInto doesn’t work:

Aarrggh!

I have changed the definition of the cable like this:

++ cable: Component, PlugAttachable, Attachable 'cable'
    "The cable is dangling from the side of the machine. "
;

And the definition of the phone like this:

++ phone: PlugAttachable, Attachable 'phone'
    "It's your cell phone. "
     allowableAttachments = cable
     reverseConnect(cable) { true; }
;

And here is a transcript illustrating both where this code goes right and where it goes wrong:

Progress?

[redacted]