kts.GetFacing

Name

kts.GetFacing – return the current facing direction of a creature

Synopsis

result = kts.GetFacing(creature)

Description

The input must be a Creature userdata object, or nil.

In the former case, the output will be a string representing the current facing direction of the creature.

In the latter case, the output is nil.

Return Value

The return value is either nil, or one of the strings "north", "south", "east" or "west".

Errors

If the input is neither nil nor a valid Creature, then an error is raised.