Skip to content

FirstSeenEvent beta ​

Interface of @v12-engine/client

ts
export interface FirstSeenEvent

What was made the first time it was drawn (FirstSeen): a shader compiled (an effect Babylon had not made yet, for a material and a pass), or a model built (a unit's copy with its own skeleton, a shared mesh)

Members ​

at ​

ts
at: number;

When, on the page's clock (performance.now())

cause ​

ts
cause: string;

What made it: close-up (a unit of a crowd given its own skeleton up close), level (drawn at another level of detail), dress (its model put on), warm (a warm-up, client.warm), cut (a cinematic's transition), impostor (a picture of a model baked for the distance, between frames), or, where nothing said, loading (behind the loading screen, FirstSeen.loading: no frame the player sees) or the frame (frame)

color ​

ts
color?: string;

A model's player colour, as r,g,b

defines ​

ts
defines?: string;

A shader's defines, as the engine made it with them: what tells two variants of one material apart

first ​

ts
first: boolean;

Whether it was the first of its kind: a model's file and colour built before is not, a shader always is

frame ​

ts
frame: number;

The frame it was made in (FirstSeen.frame)

kind ​

ts
kind: 'shader' | 'model';

A shader compiled, or a model built

material ​

ts
material?: string;

The material it was compiled for, where a mesh drawn with it was found (the view's pass); a model's: none

mesh ​

ts
mesh?: string;

The mesh it was compiled for, where one was found, or a model's root

ms ​

ts
ms: number;

Milliseconds of the page's thread it took where it was made: the shader's code made and handed over, the model's copy built

name ​

ts
name: string;

A shader's effect by its shaders' names (default, pbr, shadowMap, depth, a pass of the picture's), or the model's file

readyMs ​

ts
readyMs?: number;

A shader's: milliseconds until it was compiled and ready to draw with, where it was not at once

unit ​

ts
unit?: string;

The unit type it is of, where the one who made it said (a unit's copy, a warm-up's)