Subject: :my_huh

From: [email-masked] (Edward L. Wallace)
Date: Sat, 23 Jan 1993 13:40:04 -0800

Using 1.7.0 and the latest core, we've been developing a MOO.

We're trying to stay away from modding the core too much, so we've got a
new player class (naturally) for our stuff.  We added :my_huh to it, and
now features _work_ but :my_huh also returns 'I don't understand that'.

(even a :my_huh of pass(@args); does this...)

Any ideas?

-- 
Ted Wallace '93 - Consultant, Computer Resource Center
Dartmouth College, department of Physics and Astronomy
---
"All science is either physics, or stamp collecting" - Rutherford
"I don't like it, and I'm sorry I had anything to do with it!" - Schroedinger

---

From: Pavel Curtis <[email-masked]>
Date: Sat, 23 Jan 1993 21:57:31 -0800

> Date:	Sat, 23 Jan 1993 13:40:04 -0800
> From:	[email-masked] (Edward L. Wallace)
> 

The huh-processing code (in $room:huh and, mostly, in $command_utils:do_huh)
checks the returned value of player:my_huh; if it's true, then it assumes
:my_huh handled the command and otherwise it assumes :my_huh *didn't* handle
it.  Thus, your :my_huh code should have this form:

	if ( <this command is one that this code is supposed to handle> )
	  <handle it>;
	  return 1;
	else
	  return pass(@args);
	endif

That way, if your code handles the command then the huh-processing will not try
any other interpretations and if your code *doesn't* handle it, you still give
the default :my_huh a chance *and* you let the generic huh-processing code know
whether or not the default :my_huh handled it.

	Pavel/Haakon