Skip to content

1681-engine / index / AxisInput

Interface: AxisInput ​

Defined in: src/parallax/parallaxMath.ts:40

Properties ​

contentSize ​

ts
contentSize: number;

Defined in: src/parallax/parallaxMath.ts:53


contentStart ​

ts
contentStart: number;

Defined in: src/parallax/parallaxMath.ts:52

Where the content's bounds begin from the layer's position, and how long they are (axes that do not repeat).


factor ​

ts
factor: number;

Defined in: src/parallax/parallaxMath.ts:45


offset ​

ts
offset: number;

Defined in: src/parallax/parallaxMath.ts:47

Fixed offset plus whatever auto-scroll has added.


repeat ​

ts
repeat: boolean;

Defined in: src/parallax/parallaxMath.ts:48


scroll ​

ts
scroll: number;

Defined in: src/parallax/parallaxMath.ts:42

The camera's scroll on this axis (the world coordinate at the screen's edge).


snap ​

ts
snap: boolean;

Defined in: src/parallax/parallaxMath.ts:55

Land on whole world pixels.


tile ​

ts
tile: number;

Defined in: src/parallax/parallaxMath.ts:50

One tile's size on this axis (repeated axes).


view ​

ts
view: number;

Defined in: src/parallax/parallaxMath.ts:44

How much of the world the view shows on this axis: the screen's size over the camera's zoom.

Released under the MIT License.