From the NannyMUD documentation

LAST CHANGE

 2001-07-09 

NAME

          interior  - The interior room of a transport. 

INHERITS

 /std/water_room 

LOCATION

 /std/special/transport/exterior 

FUNCTIONS

SETUP FUNCTIONS

	set_internal_leavemsg
	set_internal_route_leavemsg
	set_external_leavemsg
	set_external_route_leavemsg
	set_internal_arrivemsg
	set_external_arrivemsg
	set_external_route_arrivemsg
	set_travelmsg
	set_failmsg_travelling
	set_failmsg_here
	set_failmsg_unknown

	add_travelcmd

	set_disembarktime
	set_disembarkedmsg
	set_failmsg_disembarking

	set_use_route
	set_route_interval
	set_no_route_enter
	set_no_route_leave

	set_start
	set_exterior
	set_controller
  

QUERY FUNCTIONS

	query_destination
	query_state	
	query_portname
	query_where	
	query_busy
	query_time_left
  

DESCRIPTION

   This is the room inside the transport. 

SEE ALSO

        transport in std/transport/transport

SEE ALSO

        exterior in std/transport/exterior

FUNCTION

 

NAME

          set_internal/external_leavemsg  - Set the transport leave messages. 

LOCATION

 /std/special/transport/interior 

SYNTAX

	void set_internal_leavemsg(string msg)
	void set_external_leavemsg(string msg)
 

DESCRIPTION

  	These functions set the messages displayed when leaving a port. 
	The message will be displayed to everyone in the room.
	$N will be replaced by the name of the port.
  

NOTE

 There are default messages if no message is set. 

NOTE

 msg = 0 will disable the message. 

EXAMPLE

	set_internal_leavemsg("The sailor says: We set sail for $N.\n");
	set_external_leavemsg("The ship leaves.\n");
  

FUNCTION

 

NAME

          set_internal/external_arrivemsg  - Set the transport arrive messages. 

LOCATION

 /std/special/transport/interior 

SYNTAX

	void set_internal_arrivemsg(string msg)
	void set_external_arrivemsg(string msg)
 

DESCRIPTION

  	These functions set the messages displayed when arriving at a port. 
	The message will be displayed to everyone in the room.
	$N will be replaced by the name of the port.
  

NOTE

 There are default messages if no message is set. 

NOTE

 msg = 0 will disable the message. 

EXAMPLE

	set_internal_arrivemsg("The sailor says: We have arrived at $N.\n");
	set_external_arrivemsg("A ship arrives.\n");
  

FUNCTION

 

NAME

          Route messages  - Set the transport route messages. 

LOCATION

 /std/special/transport/interior 

SYNTAX

	void set_internal_route_leavemsg(string msg);
	void set_external_route_leavemsg(string msg);
	void set_external_route_arrivemsg(string msg);
 

DESCRIPTION

  	These functions set the messages that are used by transports
	travelling a route, when leaving/arriving in a new room.
	$D will be replaced by the direction the transport is leaving to
	or arriving from.
  

NOTE

	There is no internal_route_arrivemsg. 
	When a transport using a route leaves/arrives at a port, 
	internal_leavemsg and internal_arrivemsg are displayed as well.
	External_leavemsg and external_arrivemsg are not used.
  

EXAMPLE

	set_internal_route_leavemsg("The coach leaves $D.\n");
	set_external_route_leavemsg("The coach rolls away $D.\n");
	set_external_route_arrivemsg("A coach arrives from the $D.\n");
  

FUNCTION

 

NAME

          set_travelmsg  - Message when a travel command is successful. 

SYNTAX

 void set_travelmsg(string msg); 

DESCRIPTION

  	This funstion sets the message displayed when a player uses a
	travel command. The message is run through std/msg and all
	occurances of $N are replaced by the name of the destination.
  

EXAMPLE

	set_travelmsg("\bPRON ask\b$ the captain to sail to $N.\n");
  

FUNCTION

 

NAME

          set_failmsg_disembarking/here/travelling/unknown  - Messages when a travel command fails. 

LOCATION

 /std/special/transport/interior 

SYNTAX

	void set_failmsg_disembarking(string msg);
	void set_failmsg_here(string msg);
	void set_failmsg_travelling(string msg);
	void set_failmsg_unknown(string msg);
  

DESCRIPTION

  	These functions set the messages displayed when a player uses a 
	travel command, but the transport is either disembarking, already
	here, travelling or if the destination is unknown. The 
	messages are run through std/msg and all occurrances of $N are 
	replaced by the name of the destination port. 
  

EXAMPLE

	set_failmsg_disembarking("The sailor says: " + 
	                         "People are still disembarking!\n");
	set_failmsg_here("The sailor says: We are already here!\n");
	set_failmsg_travelling("The sailor says: But we are already " +
	                       "sailing!\n");
	set_failmsg_unknown("The sailor says: I don't know where that is!\n");
  

FUNCTION

 

NAME

          add_travelcmd  - Command to use for travelling. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void add_travelcmd(string command); 

DESCRIPTION

  	This function adds a command that can be used to travel to another 
	port. One transport can have several different commands.
  

EXAMPLE

 add_travelcmd("sail"); 

EXAMPLE

 add_travelcmd("sail to"); 

FUNCTION

 

NAME

          set_disembarktime  - Set time the transport must stay in port. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_disembarktime(int time); 

DESCRIPTION

  	This functions sets the delay when a transport has arrived at a 
	port before it can be used again. The argument is the length of
	the delay in seconds.
	If the delay is not specified or set to 0, then there will be 
	no disembarking, and the transport can leave immediately after
	arrival.
  

FUNCTION

 

NAME

          set_disembarkedmsg  - Message when transport is done disembarking. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_disembarkedmsg(string msg); 

DESCRIPTION

  	The function sets the message displayed when the transport has 
	disembarked and is ready to leave.
  

FUNCTION

 

NAME

          set_use_route  - The transport will use routes. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_use_route(); 

DESCRIPTION

  	This function sets the transport to travel along a route.
	The route to use is set in the ports.
  

FUNCTION

 

NAME

          set_route_interval  - Delay between tranport moves. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_route_interval(int time); 

DESCRIPTION

  	This function sets the period of time the transport stops in each
	room along the route.
  

FUNCTION

 

NAME

          set_no_route_enter/leave  - Prevent players from moving while en route. 

LOCATION

 /std/special/transport/interior 

SYNTAX

	void set_no_route_enter();
	void set_no_route_leave();
 

DESCRIPTION

  	These functions specifies that players should not be able to enter
	or leave the transport while it is moving along the route.
  

FUNCTION

 

NAME

          set_controller  - Specify transport controller. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_controller(string filename); 

DESCRIPTION

  	Specifies which controller daemon the transport belongs to. The 
	argument is the filename of the controller object.
  

FUNCTION

 

NAME

          set_exterior  - Specify transport exterior. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_exterior(string filename) 

DESCRIPTION

  	Specifies the exterior object for the transport. The argument is the
	filename of the object.
  

FUNCTION

 

NAME

          set_start  - Specify default port. 

LOCATION

 /std/special/transport/interior 

SYNTAX

 void set_start(string filename); 

DESCRIPTION

  	Sets the default port for the transport. The argument is the 
	filename of the port.
  

FUNCTION

 

NAME

          query_busy  - Is transport ready to leave? 

LOCATION

 /std/special/transport/interior 

SYNTAX

 status query_busy(); 

DESCRIPTION

   Returns 0 if the transport is ready to leave. 1 otherwise. 

FUNCTION

 

NAME

          query_destination  - Which port are we going to? 

LOCATION

 /std/special/transport/interior 

SYNTAX

 string query_destination(); 

DESCRIPTION

  	Returns the filename of the port to which the transport is heading.
	If the transport is not moving, 0 is returned.
  

FUNCTION

 

NAME

          query_portname  - Which port are we in? 

LOCATION

 /std/special/transport/interior 

SYNTAX

 string query_portname(); 

DESCRIPTION

  	Returns the portname of the port the transport is currently in.
	If the transport is moving, 0 is returned.
  

FUNCTION

 

NAME

          query_where  - Which room are we in now? 

LOCATION

 /std/special/transport/interior 

SYNTAX

 string query_where(); 

DESCRIPTION

  	Returns the filename of the room the transport is currently in.
	For routes, it is the filename of the current room.
	For "normal" transports, it is the filename of the current port, and
	if it is moving, the filename of the controller is returned.
  

FUNCTION

 

NAME

          query_state  - What is the transport doing? 

LOCATION

 /std/special/transport/interior 

SYNTAX

 string query_state() 

DESCRIPTION

  	Returns the current state of the transport. It is one of
	"initializing", "stopped", "travelling" and "disembarking".
  

FUNCTION

 

NAME

          query_time_left  - When will we arrive? 

LOCATION

 /std/special/transport/interior 

SYNTAX

 int query_time_left() 

DESCRIPTION

  	Returns the number of seconds left until the transport arrives at
	its destination.