Actions On an Object Not In Scope [SOLVED]

I’m trying to write a game that involves a kind of psychic power. What’s the best way to approach verbs that affect objects not in the room? I tried creating a TopicAction with gTopic.getBestMatch() as my direct object, and immediately got a “nil object reference” error. On the other hand, having a TAction with explicitly no preconditions did absolutely nothing; I still got “you see no (x) here”. Does anyone have any advice?

I don’t think the parser makes decisions about scope based on preCond – not sure about that, though.

I think you want to use getExtraScopeItems(actor). I’ve never used it, but I suspect it will do what you’re trying to do. It will bring actual in-game objects into scope.

Thanks for the tip; I’ll try it. :slight_smile:

ETA: It works! Thanks, Jim. :smiley: