Directional Adjacency Connections
Last updated
Last updated
Directional connections use the âDirectional Adjacency Connectorâ script. Directional connectables, unlike most connectables, have a distinct front side and back side (ex. modular seats). They can be manually rotated in the editor and game due to this directional nature. Their default rotations are set to ânorthâ. These directional shapes are defined below:
O - A variant with no connections.
Lin - An âLâ type variant which, according to its design, bends inward.
Lout - An âLâ type variant which, according to its design, bends outward.
I - A variant shaped like an âIâ but rotated 90°, with 2 connections, 1 to the east and 1 to the west.
Uright - A variant shaped like a âUâ but rotated so the only connection is to the east.
Uleft - A variant shaped like a âUâ but rotated so the only connection is to the west.
Chapel Pews are the basic version of directional connectables as they do not have any corner (âLâ shaped) pieces, in theory they could be added though.
The Diner Booth is an example of a more typical use of a directional connectable for modular seating as they include corner (âLâ shaped) pieces.
The Sofa is very similar to the Diner Booth, but itâs also a good example of adding style variants.
Style variants are simply a variant with an alternate art style. The Sofaâs example is the addition of armrests.
The armrests by their nature are only required on the end shapes of the sofa (âUleftâ and âUrightâ) and on the singular sofa shape (âOâ).
Other examples of directional connectables that are not fully realized yet may include things like railings and fences...
Directionals can't connect to more than two neighbors. Once they are connected, putting any new directionals near them won't update them, unless a neighbor is disconnected.
When removing a neighbor, a connection is free, and the directional will look for other adjacent directional to form an eventual second connection and change shape.
When a directional has to change shape and has multiple options (LIn, LOut, I), the directional will choose shape in the following order:
I shape
Lin shape
Lout shape
This order is arbitrary, but it's necessary to define one as some cases are not well defined without it.