Hello, all. I’m using TADS3, and I’m still fairly new to it. I’m trying to create an exit to a room which is only accessible once an object in it is broken. I’ve successfully managed to send the offending object to location nil when dropped, and replace it with a broken version, but I’m having trouble making an exit open.
A tutorial (http://www.tads.org/t2doc/doc/tads-10.html) I read suggested I ought to be able to do something like this:
cave2: Room 'Dead End'
"It appears there's no way out. You're trapped."
north =
{
if (blueMarble.location = nil)
{
"You step through the newly revealed exit.";
return( cave3 );
}
else
{
return( nil );
}
}
;
But when compiling, I get the error message, “error: ‘=’ is not allowed with a method definition.” I tried using the exact code from the example (modified with my own rooms and objects, of course, to avoid referencing things that don’t exist), but got the same error.
It’s occurred to me that the tutorial was written for TADS2, and there may be differences in the way this works in TADS3. If this is the case, I’d appreciate it if someone could explain to me how to do the same thing in TADS3. If it’s just wrong, I’d be grateful for any advice about how to fix it, or what to do instead.
Thanks,
-Maika