Core Concepts

Fundamentals

Welcome to Flexalon! In Flexalon, gameObjects are positioned, rotated, and sized by different Flexalon components that you add your gameObjects and their parents. Each of these components hooks into a different stage of the Flexalon Pipeline, the series of steps which computes the final state of the gameObject.

Flexalon Singleton Component

The Flexalon Singleton Component stores the runtime state of all objects managed by Flexalon. If you accidentally delete it in edit mode, you may need to re-open Unity.

Flexalon Singleton Component

By default, the Flexalon Component is configured to automatically update all layout in the scene when you change properties on your gameObjects. You can change this by unchecking the "Update in Edit Mode" and "Update in Play Mode" options. If these are unchecked, an Update button will appear to manually update layout for the scene.

In some edge cases, Flexalon may not detect that layout needs to run again. Use "Force Update" to force Flexalon to recalculate layout for the entire scene.

Flexalon Objects

The Flexalon Object component manages how an individual gameObject's position, rotation, and size are calculated.

Flexalon Object Component

Use this component to:

- Configure the width, height, and depth

- Add offset, rotation, and scale

- Add margins and padding

Layouts

A Layout component determines the position, rotation, and available size for its children. Flexalon comes with the following layouts:

Flexible Layout: A linear series of objects with optional wrapping.

Flexible Layout

Grid Layout: An evenly spaced grid of objects.

Grid Layout

Circle / Spiral Layout: A circle or spiral of objects.

Circle Layout

Curve Layout: A bezier curve of objects.

Curve Layout

Random Layout: Randomize positions, rotations, or scales for objects.

Random Layout

Align Layout: Align position child objects to the parent along selected axes.

Align Layout

Shape Layout: Shape position child objects to the parent along selected axes.

Shape Layout

You can also create your own Custom Layouts.

Constraints

The Flexalon Constraint component allows your to position one gameObject relative to another. The two gameObjects don't have to be in the same hierarchy.

Animators

Use animators to create smooth transitions and motions between layout positions.

Curve animator

Lerp animator

Rigid Body animator

Interactions

Use Flexalon Interactable to easily create user interactions for clicking and dragging objects between layouts.

Interactable

Drag Target

Custom Input Provider

Data Binding

Generate child objects with a cloner and bind them to a data source.

Data Binding Example

Cloner: Generate child objects from prefabs.

Data Binding: Learn how to create a data source and bind it to child objects.

API

Extend the Flexalon Pipeline with your own layouts, animators, and adapters.

Flexalon Pipeline.

Custom Layouts

Custom Animators

Adapters