Teleports
About
Sometimes you may want to teleport the skater to a new location.

Teleports can be any number of things. A doorway, a pad, a portal, or anything that's designed to warp the player to a new point. Setting these up in NXTools is easy, and is handled by a simple script preset.
Destination Setup
Each teleporter requires a destination for the player to teleport to. We can create a simple destination in the form of a Restart node. When the player triggers the teleport, they'll be transported immediately to this location.

In NXTools, find a location for your teleport destination.




Hold Shift and Right Click the location to place your restart. This places Blender's 3D Cursor.




Add a Restart object with Add > NXTools Objects > Restarts > Restart






Rotate and position the object as necessary. (Use the G and R keys to grab / rotate the restart.)


Teleporter Setup
In most cases, a teleporter will be a non-collidable trigger face that the player will jump or skate into in some way. We're going to create a flat, invisible plane to trigger our teleport script. If this setup doesn't suit your needs, skip below to the Script Assignment section.

In NXTools, create a flat plane or cube for the player to touch.




We want this object to be for collision only! It should not show in the scene or be visible.

Locate the NXTools Settings panel inside of the Object tab on the right.


In NXTools, select your teleporter object.

Find the NXTools Settings panel inside of the Object tab on the right.




Make sure that the Scene and Sky properties are disabled. We only want Collision.




This object functions as a trigger and has no other purpose. Our goal is to trigger a script when the player touches the object. They should be able to pass through the object at any time, and this should not restrict their movement. We need to mark the object's faces to account for this.

Enter edit mode using the TAB key. Press 3 to enter Face Select mode.




Press the A key to highlight and select all of the object's faces.




Faces in THAW's engine can be marked with various collision flags that decide certain behaviors. In our case, we want to mark all of the object's faces as Non-Collidable and Trigger. The latter is responsible for triggering the object's script when the skater touches its faces.

Press the N key to bring up the sidebar. Click the NXTools tab.

Locate the Geometry Flags section at the bottom of the panel.




The Geometry Flags section contains all valid flags that we can assign to the object's faces. We can assign flags by simply toggling the desired button(s) on or off.

With all faces selected, enable the Non-Collidable and Trigger flags.

Faces in the viewport are highlighted Yellow as a result of the Non-Collidable flag.

Faces in the viewport are highlighted Green as a result of the Trigger flag.




Our object's faces are marked with the appropriate flags, and we've indicated that this object should export only collision data. This is now a general-purpose trigger object. With the proper requirements in place, we need to tell the game what action this object should perform.
Script Assignment
Locate the NXTools Settings panel inside of the Object tab on the right.

Scroll down and locate the Script Settings dialog.




Set the object's Trigger Script preset to Teleport.




Touching or interacting with this object will now teleport the player to the Destination object.
Parameters
The Script Settings window contains various options that affect the teleporter.

Destination
The object to teleport the skater to. This should be a restart or other waypoint in the level.


Message
The on-screen message to show when teleporting the player. If empty, no message is shown.


Message Color
Affects the color of the on-screen message shown from the Message property.

This parameter is only used if the Custom Color box is active.


Message Style
Affects the general appearance / animation of the message.

Normal shows static text on the screen with no animation.

Death shows erratic text which stays on-screen, then falls.