Feel an Actor

I’ve been reading a thread from way back in 2014 that discusses overwriting the feelDesc on an Actor object. But I am not getting the expected results.

I copied the code from the LearningT3.pdf (an apple object) and all the overwrites work except the feelDesc. Is the feelDesc no longer available for the Actor object? If not, is there a workaround?

erik: Actor 'Erik; prince friendly man human strong ;person; him'
desc{
    if(palaceBedroom.isLit == true)
    "The person next to you is a young and handsome fella. ";
    else
    "In the absence of light, you can only make out a lump under the blanket. ";
}

feelDesc = "You poke the blanket, causing the person to flinch.<.reveal erik-bed> "
tasteDesc = "The apple tastes sweet at juicy. "
soundDesc = "The apple is obstinately silent. "
smellDesc = "There's the faintest sweet apple smell. "
specialDesc = nil
visibleInDark = true

;

I should also include the result of trying to feel the person.

>feel person
Erik doesn’t appreciate being touched.

Thank you in advance!

So, is Eric an uncontained SCP entity who possesses all the properties of an apple?

All jokes aside, I’ll take a look at this later and see if I can’t dig up something, assuming the other TADS wizards don’t beat me to the punch.

3 Likes

Adv3Lite assumes that an Actor won’t respond to being touched/felt like an inanimate object, and wouldn’t passively accept random people feeling them, or that the player character would normally go around feeling random people (hardly sociably acceptable, surely).

So on an Actor, the relevant property is called touchReponseMsg, on the basis that most people would respond to being touched. If you defined touchResponseMsg = feelDesc you’d see the expected response, but it would be more direct to define touchResponseMsg = "You poke the blanket, causing the person to flinch.<.reveal erik-bed> "

Since one might expect an Actor to respond to touch in different ways under different circumstances, you can also define at Actor’s response to being touched using a TouchTopic (ore a different TouchTopic under each ActorState, or with all the other things you can do with a TopicEntry).

So you could have:

errik:Actor 'Erik; prince.....'
  ...
;

+ TouchTopic
    "You poke the blanket, causing the person to flinch.<.reveal erik-bed> "
;

++ AltTopic
    "You hesitate to prod his highness a second time. "
     isActive = gRevealed('erik-bed')
;
4 Likes

For reasons not related to scientific research :wink: (touching an item for me means cheching its rigidity, flexibility &c and feeling means feeling its temperature and smoothness, for example) I separated TOUCH and FEEL, with this:

// separating, once and for all, the siamese FEEL and TOUCH 
//240911: you siamese idiots, should be fully separated now !!
modify grammar predicate (Feel):

    'feel'  dobjList
    : 
    verbPhrase = 'feel/feeling (what)'
    missingQ = 'what do you want to feel'
;

DefineTAction(Touch);

VerbRule(Touch)
        'touch' dobjList
        : VerbProduction
        action = Touch
        verbPhrase = 'touch/touching (what)'
        missingQ = 'what do you want to touch'
;

modify Thing
touchDesc = "Touching {the dobj}, {i} don't discover nothing new."
basicExamineTouch() {touchDesc;}

dobjFor(Touch)
    {
      /* Obviously, we have to be able to touch it */
      preCond = [touchObj]
      verify() { }
      action()
      {
        /* show our "touch" description */
        display(&touchDesc);
      }
	}
	;
;

modify Actor 
feelDesc = "feeling {dobj}, {i} don't discover nothing interesting."
basicExamineFeel() {feelDesc;}

dobjFor(Feel)
    {
      /* Obviously, we have to be able to touch it */
      preCond = [touchObj]
      verify() { }
      action()
      {
        /* show our "touch" description */
        display(&feelDesc);
      }
	}
	;
;

(notare il modify actor)

and my two major NPC have these two lines:

isKissable = true // being soulmates....
isFeelable = true // ditto

and lo and behold, TOUCHing and FEELing are now easily handled with touchDesc and FeelDesc !

HTH and
Best regards from Italy,
dott. Piergiorgio.

2 Likes

I believe it’s a long-standing convention in IF to treat TOUCH and FEEL as synonyms, although I agree there’s a semantic distinction in everyday English. I also suspect that many game authors won’t want to implement separate responses to TOUCH and FEEL, and many players may expect them both to work in the same way, besides which your proposal would break adv3Lite’s TouchTopic mechanism if implemented in the library as well as breaking compatibility with existing game code that uses TouchTopics or relies on TOUCH and FEEL doing the same thing, so I shan’t be implementing your suggestion in the library (although game authors are, of course, free to do what they wish in their own games).

To meet you halfway, I’ve nevertheless implemented separate FEEL and TOUCH verbs for the next release of adv3Lite, except that both verbs will do exactly the same thing: the library now defines:

   dobjFor(Touch) asDobjFor(Feel)

That preserves existing behaviour and backwards compatibility while also allowing game authors to override dobjFor(Touch) to do something different it they so wish. Thing also now defines a touchDesc property they can use for the purrpose, although it’s currently unused by any library code.

If you want to separate only a handful of TOUCH and FEEL responses using the new library set up, you’ll be able to do so without having to override dobjFor(Touch) by doing this kind of thing:

feelDesc = (gActionIs(Touch) ? 'She flinches from your touch. ' : 'She feels cold. ')

(Version 2.2 of adv3Lite will allow you to use feelDesc on an Actor in the way you might expect).

2 Likes

Discovering that you missed an important clue because you TOUCHed an object but didn’t FEEL it sounds even more annoying than missing something because you EXAMINEd it but didn’t SEARCH it (which is definitely an old-school distinction that goes over poorly these days).

2 Likes

Agree with Eric on the adding of a separate “synonym action” (lacking a better term…) which allow the use of the ternary operator in simple cases, as you demonstrate.

of course, when 2.2 came out I’ll do the usual test run :wink:

Best regards from Italy,
dott. Piergiorgio.