Hoik

A hoik is a sawtooth series of sloped blocks, sometimes referred to as "teeth", which rapidly move entities across distances.

When a character sprite shares space with a sloped block, the character is immediately displaced a couple of tiles in a predictable direction. By chaining these glitches together with a line of strategically placed shaped blocks, entities can be moved in any direction. It becomes easy to achieve horizontal travel at 60 or 120 tiles per second and vertical travel at 180 tiles per second provided by legitimate means (aside from Teleporters or the ).

Hoiks are most commonly used as a method of fast travel, but also allow for the creation of mechanisms, such as fast binary counters that are not available with standard game features.

Since, hoiks are officially considered a "feature" by Re-Logic. As such, it is ensured their functionality remains in the game. They are not planned to be removed.

Hoiks are part of Terraria since version 1.2, which introduced sloped tiles. While there have been individual prototypical exploits of this feature, a by ZeroGravitas has made hoiks widely known. Much of the current knowledge presented in this article and standard applications of hoiks are based on his research.

Displacement in Terraria
Hoiks are based on the displacement system of the game. When an overlap of block and entity is detected, the entity is displaced, in order to resolve the overlap. For sloped blocks, the displacement direction is indicated by the location of the slope within the tile.

The game determines the displacement direction following these rules:
 * If the slope is facing upwards, move the entity straight upwards (provided there are no blocks directly above the head).
 * If the slope is facing downwards, move entity straight downwards (provided there are no blocks directly under the feet).
 * If either of the above are blocked (by blocks directly above or below, respectively), then move the entity sideways (in the direction the slope faces) ignoring any solid blocks to side.
 * Exception: Upward-displacement is always the first choice for blocks at foot height. Blocks directly above the head (or is held) negate this.

This behavior is visualized in the diagram on the right. The diagram was created by actuating a sloped block into existence behind the player's sprite, having started by standing in the middle of the 2 Glass Block base, in each case. Equally, the diagram shows the jump made by hammering a previously square tile into the depicted shape (while behind the player).


 * Complete displacements are helpful for hoiks:
 * Vertical displacement: = up 3 (tiles),  = up 2.
 * Horizontal displacement: = right 2,  = right 1,  = right 1,  = right 2.
 * Unhelpful instances show incomplete displacements, jams , no effect , or a single-tile rise which can not be strung onto further hoik steps.
 * Square blocks or half-tiles in any of the empty spaces behind the player, or to the sides, have no effects.

Terraria detects collision every tick.✅ Thus, stringing together a series of these displacements, with each jump landing the player on top of another sloped tile, creates a "track" which is capable of moving an entity at the speed of 1 displacement per tick, i.e. 60 displacements per second. This is the quintessence of a hoik.

Mounting a Hoik
A hoik is entered by positioning the (player) sprite in front of the first tooth. This can be achieved using the following methods:
 * Stepping up onto a square block or a platform hammered into "half" position.
 * Actuating the first tooth, positioning in front of it, and turning it back on.
 * Placing a sloped platform, sloped inactive block, or inactive platform against the upright edge of the first tooth. The game's collision detection then ignores the adjacent horizontal surface.
 * Teleporting onto the tooth.
 * Constructing another hoik which leaves the player in front of the tooth.
 * Grappling, in certain cases.

Upwards


Step-up mounted standard elevator. Jumps up 3 tiles per game tick.

Sloped platform mounted hoik elevator.

This elevator can be joined anywhere along its length. To bypass the sloped platforms (including avoiding fall damage), needs to be held while falling.

Inactive sloped tile mount.

Actuated first tooth mount.

Sectional elevator (up one section per click). For a two-way use in a two-block wide hellevator, all teeth need to be actuated. If used in a three-block wide shaft, only the first tooth at each mounting point needs to be actuated.

Tooth spacing variations: A single gap can be left (e.g. to help adjusting the exact starting/ending points). One-tile gaps can only be used on alternate teeth, otherwise the entity's head will jam against the third tooth.

Tooth width variants: Stepping up through entirely solid rows (up to two tiles thick) is possible, e.g. to hold water, lava, or NPCs in place.

This hoik is mounted by walking past the entrance or holding while walking left.

Downwards and Bi-directional



 * Downwards

Hold while walking slowly through the sloped platform. Continue holding over the edge (otherwise the player will step up on top of the mounting tooth).

Mid-run mounting. (There is no known way to walk through a down hoik, like in the diagram above, without actuating a tooth.)

Walk in from the left. The hoik uses inactive sloped block and ceiling. Like upward hoiks, every other downward tooth can have 1 vertical space, instead of 2, but the first gap must be 2 tiles high.

All tiles except the row directly below the each tooth can be filled in.

Actuated mount. The first tooth comes in as a block/platform directly underneath and is actuated out. Must be a one-tile gap beneath, otherwise the player will just step down.


 * Bi-directional

Activate the Switch to move upwards/downwards. Actuated upward teeth (and mounting teeth) allow two-directional travel through a two-tile wide shaft.

Standard three-tile wide up- and downward hoik. Hoiking downwards places the entity on the platform at the bottom.

A four-tile wide shaft allows up- and downward hoiks to be entirely independent.

Horizontal Hoik Examples
While all entities are moved from left to right here, the layout can be inverted to enable right-to-left transport. As soon as the entity is mounted, all tiles except the teeth are irrelevant. This allows a horizontal track through entirely solid ground.



Top (Against Ceiling)
All entities are moved along the ceiling, hence no floor is required. Actuated mounting variants are more space-efficient, thus shown first.

Waist-height teeth variant, 1 tile/tick.

Head-height variant, 2 tiles/tick. Actuated mount.

Head-height, 1 tile/tick. Sloped platform 1-step elevator mount.

Waist-height, 1 tile/tick. Step-up elevator mount. (An elevator section of any length can be used, provided the last step up puts the player's head directly under (against) the ceiling.

Bottom (Against Floor)
All entities are moved along the floor, hence no ceiling is required (except for specific mounting instances).

Foot-height variant, 2 tiles/tick. To mount, hold before reaching the sloped platform (will walk over the top otherwise).

Waist-height teeth, 1 tile/tick. Inactive sloped block mount. Just walking towards it to mount is sufficient, as the block above prevents stepping up.

Waist-height, 1 tile/tick. Actuated teeth mount variant. Waist-height is preferable over actuated foot-height which will push up the sprite (unless a ceiling is placed) and requires more precise positioning.

Bi-directional, foot-height, 2 tiles/tick. Automatic mounting in either direction, just walk towards it.

Bi-directional, foot-height, 2 tiles/tick. The absence of ceiling in the mounting area here requires to hold while mounting, otherwise the player will just walk straight over the top, in either direction.

Comparison to Alternatives

 * Hoiks have a higher top speed which is achieved immediately: 48.4 tiles/sec (regular Minecart); 60 or 120 tiles/sec (horizontal hoik).
 * The track of hoiks is much less flexible and not intrinsically two-way (possible, but more fiddly).
 * It is difficult to manually dismount a top hoik mid-run (but one can step out of the bottom hoik at any point, if there is no ceiling).


 * Hoiks have a higher top speed which is achieved immediately: 30.75 tiles/sec ascending, 38.25 tiles/sec descending (Rope); 180 tiles/sec (vertical hoik, both directions).
 * At this speed, however, it is hard to dismount at the right point without inserting gaps.
 * Mid-run entry and break points need to be engineered in.
 * A hoik's foreground blocks possibly obstruct open space.


 * Hoiks are free and available at all points of game progression.
 * Using a hoik does not despawn the player, which means NPCs will not be auto-relocated.
 * Hoiks do not require long wire routes that may interfere with other devices.
 * Teleporters are faster in nearly all cases.
 * Using a hoik discharges momentum, as each displacement counts as a collision with a tile, therefore running/Minecart speed cannot be carried over to the destination.
 * Constructing a hoik is far more fiddly for any significant distance, especially for bi-directional travel.
 * Hoiks are much less flexible.

Item Hoiks
Dropped items can be hoiked, i.e. displaced due to overlap with sloped blocks, as well. While item transport is more limited than player and NPC transport, there are numerous common use cases, such as more efficient farms (e.g. an automated Fallen Star farm) or a Heart/Mana Star extractor for event fights.

See the following forums thread for further reading: