This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
platforms [2019/12/16 18:44] – justin | platforms [2019/12/16 20:56] – justin | ||
---|---|---|---|
Line 6: | Line 6: | ||
{{: | {{: | ||
- | To enable this functionality, | + | To enable this functionality, |
{{: | {{: | ||
Line 15: | Line 15: | ||
{{: | {{: | ||
- | To minimize the need for navigation | + | Whenever a platform leaves its current location, any current navigation paths to/from that tile will be disconnected. |
+ | |||
+ | For example, when the platform defined below is moved to its "Upper Floor" waypoint, a navigation path will be automatically connected from its new tile coordinate (8, -3, 16) to the adjacent tile coordinate (8, -4, 16) upon arrival, allowing the player character to step from the platform onto the adjacent tile. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | As you can see below, the navigation paths are automatically disconnected when the lily pad and wooden platform depart from their original locations, and navigation paths are connected after arriving at their destination waypoints, based on their defined "On Arrival" | ||
+ | |||
+ | {{: | ||
+ | |||
+ | <WRAP center round info 100%> | ||
+ | To enable the display of navigation paths in-game for testing purposes, you can enter "nav on" into the [[debug console]]. The command "nav off" will toggle the paths off. | ||
+ | </ | ||
=====Scripting===== | =====Scripting===== | ||
To move a platform to a specific waypoint during game time, you can use the [[Move Platform]] scripting function. For example, the script below will move the platform tile (with entity ID of " | To move a platform to a specific waypoint during game time, you can use the [[Move Platform]] scripting function. For example, the script below will move the platform tile (with entity ID of " | ||
+ | |||
<code python> | <code python> | ||
- | move_platform(entity[" | + | move_platform(entity[" |
</ | </ | ||
+ | |||
+ | The third argument, a [[Boolean]] value of true or false, instructs the game whether or not the current script should wait until the platform has reached its destination waypoint before proceeding. This argument is optional and defaults to false. | ||
~~NOTOC~~ | ~~NOTOC~~ | ||