path_endaction

Sets what to do when the instance reaches the end of the path.

语法:

path_endaction;


Returns: Constant.


描述

This variable can be used to get or to change the reaction of an instance when it reaches the end of the current path. Normally you would set this when you start the path using path_start but you may wish to change this behaviour depending on any number of events in your game. The available values are expressed using the following constants:


例如:

if path_endaction == path_action_stop
   {
   path_endaction = choose(path_action_restart, path_action_continue, path_action_reverse);
   }

The above code will check the path end action and if it's set to stop, then a new path end action will be selected randomly.


上一页:路径
下一页: path_start
© Copyright YoYo Games Ltd. 2018 All Rights Reserved