Character.FaceObject(Object* object, optional BlockingStyle)
Similar to the FaceCharacter function, except that this faces the character
to object OBJECT in the current room.
If the character has Turning enabled (ie. the "Characters turn to face direction" game
option is turned on, and the character does not have the "Do not turn before walking"
option checked), then the character will turn on the spot in order to face the new direction.
In this case, the BlockingStyle parameter determines whether the script waits for the
character to finish turning (eBlock, the default) or whether the script continues immediately
and the character finishes turning later on (eNoBlock).
If the character does not have Turning enabled, he will immediately turn to face the
new direction and the BlockingStyle parameter has no effect. In this case, the screen
will not be refreshed straight away -- if you want to see the character facing his new direction
immediately, call Wait(1);
Example:
player.FaceObject(object[2]);
will make the player character face object 2.
See Also: Character.FaceCharacter
|