@dcl/protocol 1.0.0-4789401842.commit-c29e991 → 1.0.0-4799189990.commit-8494b7b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/out-js/decentraland/sdk/components/common/loading_state.gen.d.ts +11 -0
- package/out-js/decentraland/sdk/components/common/loading_state.gen.js +57 -0
- package/out-js/decentraland/sdk/components/common/loading_state.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/engine_info.gen.d.ts +57 -0
- package/out-js/decentraland/sdk/components/engine_info.gen.js +88 -0
- package/out-js/decentraland/sdk/components/engine_info.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/gltf_container_loading_state.gen.d.ts +43 -0
- package/out-js/decentraland/sdk/components/gltf_container_loading_state.gen.js +63 -0
- package/out-js/decentraland/sdk/components/gltf_container_loading_state.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/pointer_events_result.gen.d.ts +7 -1
- package/out-js/decentraland/sdk/components/pointer_events_result.gen.js +14 -2
- package/out-js/decentraland/sdk/components/pointer_events_result.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/raycast_result.gen.d.ts +6 -0
- package/out-js/decentraland/sdk/components/raycast_result.gen.js +14 -2
- package/out-js/decentraland/sdk/components/raycast_result.gen.js.map +1 -1
- package/out-ts/decentraland/sdk/components/common/loading_state.gen.ts +54 -0
- package/out-ts/decentraland/sdk/components/engine_info.gen.ts +119 -0
- package/out-ts/decentraland/sdk/components/gltf_container_loading_state.gen.ts +85 -0
- package/out-ts/decentraland/sdk/components/pointer_events_result.gen.ts +20 -3
- package/out-ts/decentraland/sdk/components/raycast_result.gen.ts +16 -1
- package/package.json +2 -2
- package/proto/decentraland/sdk/components/common/loading_state.proto +10 -0
- package/proto/decentraland/sdk/components/engine_info.proto +15 -0
- package/proto/decentraland/sdk/components/gltf_container_loading_state.proto +13 -0
- package/proto/decentraland/sdk/components/pointer_events_result.proto +2 -1
- package/proto/decentraland/sdk/components/raycast_result.proto +1 -0
- package/public/sdk-components.proto +20 -18
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const protobufPackage = "decentraland.sdk.components.common";
|
|
2
|
+
export declare enum LoadingState {
|
|
3
|
+
UNKNOWN = 0,
|
|
4
|
+
LOADING = 1,
|
|
5
|
+
NOT_FOUND = 2,
|
|
6
|
+
FINISHED_WITH_ERROR = 3,
|
|
7
|
+
FINISHED = 4,
|
|
8
|
+
UNRECOGNIZED = -1
|
|
9
|
+
}
|
|
10
|
+
export declare function loadingStateFromJSON(object: any): LoadingState;
|
|
11
|
+
export declare function loadingStateToJSON(object: LoadingState): string;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.loadingStateToJSON = exports.loadingStateFromJSON = exports.LoadingState = exports.protobufPackage = void 0;
|
|
5
|
+
exports.protobufPackage = "decentraland.sdk.components.common";
|
|
6
|
+
var LoadingState;
|
|
7
|
+
(function (LoadingState) {
|
|
8
|
+
LoadingState[LoadingState["UNKNOWN"] = 0] = "UNKNOWN";
|
|
9
|
+
LoadingState[LoadingState["LOADING"] = 1] = "LOADING";
|
|
10
|
+
LoadingState[LoadingState["NOT_FOUND"] = 2] = "NOT_FOUND";
|
|
11
|
+
LoadingState[LoadingState["FINISHED_WITH_ERROR"] = 3] = "FINISHED_WITH_ERROR";
|
|
12
|
+
LoadingState[LoadingState["FINISHED"] = 4] = "FINISHED";
|
|
13
|
+
LoadingState[LoadingState["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
14
|
+
})(LoadingState = exports.LoadingState || (exports.LoadingState = {}));
|
|
15
|
+
function loadingStateFromJSON(object) {
|
|
16
|
+
switch (object) {
|
|
17
|
+
case 0:
|
|
18
|
+
case "UNKNOWN":
|
|
19
|
+
return LoadingState.UNKNOWN;
|
|
20
|
+
case 1:
|
|
21
|
+
case "LOADING":
|
|
22
|
+
return LoadingState.LOADING;
|
|
23
|
+
case 2:
|
|
24
|
+
case "NOT_FOUND":
|
|
25
|
+
return LoadingState.NOT_FOUND;
|
|
26
|
+
case 3:
|
|
27
|
+
case "FINISHED_WITH_ERROR":
|
|
28
|
+
return LoadingState.FINISHED_WITH_ERROR;
|
|
29
|
+
case 4:
|
|
30
|
+
case "FINISHED":
|
|
31
|
+
return LoadingState.FINISHED;
|
|
32
|
+
case -1:
|
|
33
|
+
case "UNRECOGNIZED":
|
|
34
|
+
default:
|
|
35
|
+
return LoadingState.UNRECOGNIZED;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
exports.loadingStateFromJSON = loadingStateFromJSON;
|
|
39
|
+
function loadingStateToJSON(object) {
|
|
40
|
+
switch (object) {
|
|
41
|
+
case LoadingState.UNKNOWN:
|
|
42
|
+
return "UNKNOWN";
|
|
43
|
+
case LoadingState.LOADING:
|
|
44
|
+
return "LOADING";
|
|
45
|
+
case LoadingState.NOT_FOUND:
|
|
46
|
+
return "NOT_FOUND";
|
|
47
|
+
case LoadingState.FINISHED_WITH_ERROR:
|
|
48
|
+
return "FINISHED_WITH_ERROR";
|
|
49
|
+
case LoadingState.FINISHED:
|
|
50
|
+
return "FINISHED";
|
|
51
|
+
case LoadingState.UNRECOGNIZED:
|
|
52
|
+
default:
|
|
53
|
+
return "UNRECOGNIZED";
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
exports.loadingStateToJSON = loadingStateToJSON;
|
|
57
|
+
//# sourceMappingURL=loading_state.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loading_state.gen.js","sourceRoot":"","sources":["../../../../../out-ts/decentraland/sdk/components/common/loading_state.gen.ts"],"names":[],"mappings":";AAAA,oBAAoB;;;AAEP,QAAA,eAAe,GAAG,oCAAoC,CAAC;AAEpE,IAAY,YAOX;AAPD,WAAY,YAAY;IACtB,qDAAW,CAAA;IACX,qDAAW,CAAA;IACX,yD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entraland.sdk.components";
|
|
3
|
+
/**
|
|
4
|
+
* EngineInfo provides information about the graphics engine running the scene.
|
|
5
|
+
* The values of this component are written at the "physics" stage of the ADR-148. Meaning
|
|
6
|
+
* the tick_number and frame_number of the same frame could be used as correlation numbers
|
|
7
|
+
* for timestamps in other components.
|
|
8
|
+
*/
|
|
9
|
+
export interface PBEngineInfo {
|
|
10
|
+
/** frame counter of the engine */
|
|
11
|
+
frameNumber: number;
|
|
12
|
+
/** total runtime of this scene in seconds */
|
|
13
|
+
totalRuntime: number;
|
|
14
|
+
/** tick counter of the scene as per ADR-148 */
|
|
15
|
+
tickNumber: number;
|
|
16
|
+
}
|
|
17
|
+
export declare const PBEngineInfo: {
|
|
18
|
+
encode(message: PBEngineInfo, writer?: _m0.Writer): _m0.Writer;
|
|
19
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): PBEngineInfo;
|
|
20
|
+
fromJSON(object: any): PBEngineInfo;
|
|
21
|
+
toJSON(message: PBEngineInfo): unknown;
|
|
22
|
+
create<I extends {
|
|
23
|
+
frameNumber?: number | undefined;
|
|
24
|
+
totalRuntime?: number | undefined;
|
|
25
|
+
tickNumber?: number | undefined;
|
|
26
|
+
} & {
|
|
27
|
+
frameNumber?: number | undefined;
|
|
28
|
+
totalRuntime?: number | undefined;
|
|
29
|
+
tickNumber?: number | undefined;
|
|
30
|
+
} & { [K in Exclude<keyof I, keyof PBEngineInfo>]: never; }>(base?: I | undefined): PBEngineInfo;
|
|
31
|
+
fromPartial<I_1 extends {
|
|
32
|
+
frameNumber?: number | undefined;
|
|
33
|
+
totalRuntime?: number | undefined;
|
|
34
|
+
tickNumber?: number | undefined;
|
|
35
|
+
} & {
|
|
36
|
+
frameNumber?: number | undefined;
|
|
37
|
+
totalRuntime?: number | undefined;
|
|
38
|
+
tickNumber?: number | undefined;
|
|
39
|
+
} & { [K_1 in Exclude<keyof I_1, keyof PBEngineInfo>]: never; }>(object: I_1): PBEngineInfo;
|
|
40
|
+
};
|
|
41
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
42
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {
|
|
43
|
+
$case: string;
|
|
44
|
+
} ? {
|
|
45
|
+
[K in keyof Omit<T, "$case">]?: DeepPartial<T[K]>;
|
|
46
|
+
} & {
|
|
47
|
+
$case: T["$case"];
|
|
48
|
+
} : T extends {} ? {
|
|
49
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
50
|
+
} : Partial<T>;
|
|
51
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
52
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
53
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
54
|
+
} & {
|
|
55
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
56
|
+
};
|
|
57
|
+
export {};
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.PBEngineInfo = exports.protobufPackage = void 0;
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
const minimal_1 = __importDefault(require("protobufjs/minimal"));
|
|
9
|
+
exports.protobufPackage = "decentraland.sdk.components";
|
|
10
|
+
function createBasePBEngineInfo() {
|
|
11
|
+
return { frameNumber: 0, totalRuntime: 0, tickNumber: 0 };
|
|
12
|
+
}
|
|
13
|
+
exports.PBEngineInfo = {
|
|
14
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
15
|
+
if (message.frameNumber !== 0) {
|
|
16
|
+
writer.uint32(8).uint32(message.frameNumber);
|
|
17
|
+
}
|
|
18
|
+
if (message.totalRuntime !== 0) {
|
|
19
|
+
writer.uint32(21).float(message.totalRuntime);
|
|
20
|
+
}
|
|
21
|
+
if (message.tickNumber !== 0) {
|
|
22
|
+
writer.uint32(24).uint32(message.tickNumber);
|
|
23
|
+
}
|
|
24
|
+
return writer;
|
|
25
|
+
},
|
|
26
|
+
decode(input, length) {
|
|
27
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
28
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
29
|
+
const message = createBasePBEngineInfo();
|
|
30
|
+
while (reader.pos < end) {
|
|
31
|
+
const tag = reader.uint32();
|
|
32
|
+
switch (tag >>> 3) {
|
|
33
|
+
case 1:
|
|
34
|
+
if (tag != 8) {
|
|
35
|
+
break;
|
|
36
|
+
}
|
|
37
|
+
message.frameNumber = reader.uint32();
|
|
38
|
+
continue;
|
|
39
|
+
case 2:
|
|
40
|
+
if (tag != 21) {
|
|
41
|
+
break;
|
|
42
|
+
}
|
|
43
|
+
message.totalRuntime = reader.float();
|
|
44
|
+
continue;
|
|
45
|
+
case 3:
|
|
46
|
+
if (tag != 24) {
|
|
47
|
+
break;
|
|
48
|
+
}
|
|
49
|
+
message.tickNumber = reader.uint32();
|
|
50
|
+
continue;
|
|
51
|
+
}
|
|
52
|
+
if ((tag & 7) == 4 || tag == 0) {
|
|
53
|
+
break;
|
|
54
|
+
}
|
|
55
|
+
reader.skipType(tag & 7);
|
|
56
|
+
}
|
|
57
|
+
return message;
|
|
58
|
+
},
|
|
59
|
+
fromJSON(object) {
|
|
60
|
+
return {
|
|
61
|
+
frameNumber: isSet(object.frameNumber) ? Number(object.frameNumber) : 0,
|
|
62
|
+
totalRuntime: isSet(object.totalRuntime) ? Number(object.totalRuntime) : 0,
|
|
63
|
+
tickNumber: isSet(object.tickNumber) ? Number(object.tickNumber) : 0,
|
|
64
|
+
};
|
|
65
|
+
},
|
|
66
|
+
toJSON(message) {
|
|
67
|
+
const obj = {};
|
|
68
|
+
message.frameNumber !== undefined && (obj.frameNumber = Math.round(message.frameNumber));
|
|
69
|
+
message.totalRuntime !== undefined && (obj.totalRuntime = message.totalRuntime);
|
|
70
|
+
message.tickNumber !== undefined && (obj.tickNumber = Math.round(message.tickNumber));
|
|
71
|
+
return obj;
|
|
72
|
+
},
|
|
73
|
+
create(base) {
|
|
74
|
+
return exports.PBEngineInfo.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
75
|
+
},
|
|
76
|
+
fromPartial(object) {
|
|
77
|
+
var _a, _b, _c;
|
|
78
|
+
const message = createBasePBEngineInfo();
|
|
79
|
+
message.frameNumber = (_a = object.frameNumber) !== null && _a !== void 0 ? _a : 0;
|
|
80
|
+
message.totalRuntime = (_b = object.totalRuntime) !== null && _b !== void 0 ? _b : 0;
|
|
81
|
+
message.tickNumber = (_c = object.tickNumber) !== null && _c !== void 0 ? _c : 0;
|
|
82
|
+
return message;
|
|
83
|
+
},
|
|
84
|
+
};
|
|
85
|
+
function isSet(value) {
|
|
86
|
+
return value !== null && value !== undefined;
|
|
87
|
+
}
|
|
88
|
+
//# sourceMappingURL=engine_info.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"engine_info.gen.js","sourceRoot":"","sources":["../../../../out-ts/decentraland/sdk/components/engine_info.gen.ts"],"names":[],"mappings":";;;;;;AAAA,oBAAoB;AACpB,iEAAqC;AAExB,QAAA,eAAe,GAAG,6BAA6B,CAAC;AAiB7D,SAAS,sBAAsB;IAC7B,OAAO,EAAE,WAAW,EAAE,CAAC,EAAE,YAAY,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAE,CAAC;AAC5D,CAAC;AAEY,QAAA,YAAY,GAAG;IAC1B,MAAM,CAAC,OAAqB,EAAE,SAAqB,iBAAG,CAAC,MAAM,CAAC,MAAM,EAAE;QACpE,IAAI,OAAO,CAAC,WAAW,KAAK,CAAC,EAAE;YAC7B,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC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,IAAQ;QAC5D,OAAO,oBAAY,CAAC,WAAW,CAAC,IAAI,aAAJ,IAAI,cAAJ,IAAI,GAAI,EAAE,CAAC,CAAC;IAC9C,CAAC;IAED,WAAW,CAAgD,MAAS;;QAClE,MAAM,OAAO,GAAG,sBAAsB,EAAE,CAAC;QACzC,OAAO,CAAC,WAAW,GAAG,MAAA,MAAM,CAAC,WAAW,mCAAI,CAAC,CAAC;QAC9C,OAAO,CAAC,YAAY,GAAG,MAAA,MAAM,CAAC,YAAY,mCAAI,CAAC,CAAC;QAChD,OAAO,CAAC,UAAU,GAAG,MAAA,MAAM,CAAC,UAAU,mCAAI,CAAC,CAAC;QAC5C,OAAO,OAAO,CAAC;IACjB,CAAC;CACF,CAAC;AAcF,SAAS,KAAK,CAAC,KAAU;IACvB,OAAO,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,CAAC;AAC/C,CAAC"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import _m0 from "protobufjs/minimal";
|
|
2
|
+
import { LoadingState } from "./common/loading_state.gen";
|
|
3
|
+
export declare const protobufPackage = "decentraland.sdk.components";
|
|
4
|
+
/**
|
|
5
|
+
* GltfContainerLoadingState is set by the engine and provides information about
|
|
6
|
+
* the current state of the GltfContainer of an entity.
|
|
7
|
+
*/
|
|
8
|
+
export interface PBGltfContainerLoadingState {
|
|
9
|
+
currentState: LoadingState;
|
|
10
|
+
}
|
|
11
|
+
export declare const PBGltfContainerLoadingState: {
|
|
12
|
+
encode(message: PBGltfContainerLoadingState, writer?: _m0.Writer): _m0.Writer;
|
|
13
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): PBGltfContainerLoadingState;
|
|
14
|
+
fromJSON(object: any): PBGltfContainerLoadingState;
|
|
15
|
+
toJSON(message: PBGltfContainerLoadingState): unknown;
|
|
16
|
+
create<I extends {
|
|
17
|
+
currentState?: LoadingState | undefined;
|
|
18
|
+
} & {
|
|
19
|
+
currentState?: LoadingState | undefined;
|
|
20
|
+
} & { [K in Exclude<keyof I, "currentState">]: never; }>(base?: I | undefined): PBGltfContainerLoadingState;
|
|
21
|
+
fromPartial<I_1 extends {
|
|
22
|
+
currentState?: LoadingState | undefined;
|
|
23
|
+
} & {
|
|
24
|
+
currentState?: LoadingState | undefined;
|
|
25
|
+
} & { [K_1 in Exclude<keyof I_1, "currentState">]: never; }>(object: I_1): PBGltfContainerLoadingState;
|
|
26
|
+
};
|
|
27
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
28
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {
|
|
29
|
+
$case: string;
|
|
30
|
+
} ? {
|
|
31
|
+
[K in keyof Omit<T, "$case">]?: DeepPartial<T[K]>;
|
|
32
|
+
} & {
|
|
33
|
+
$case: T["$case"];
|
|
34
|
+
} : T extends {} ? {
|
|
35
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
36
|
+
} : Partial<T>;
|
|
37
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
38
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
39
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
40
|
+
} & {
|
|
41
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
42
|
+
};
|
|
43
|
+
export {};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.PBGltfContainerLoadingState = exports.protobufPackage = void 0;
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
const minimal_1 = __importDefault(require("protobufjs/minimal"));
|
|
9
|
+
const loading_state_gen_1 = require("./common/loading_state.gen");
|
|
10
|
+
exports.protobufPackage = "decentraland.sdk.components";
|
|
11
|
+
function createBasePBGltfContainerLoadingState() {
|
|
12
|
+
return { currentState: 0 };
|
|
13
|
+
}
|
|
14
|
+
exports.PBGltfContainerLoadingState = {
|
|
15
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
16
|
+
if (message.currentState !== 0) {
|
|
17
|
+
writer.uint32(8).int32(message.currentState);
|
|
18
|
+
}
|
|
19
|
+
return writer;
|
|
20
|
+
},
|
|
21
|
+
decode(input, length) {
|
|
22
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
23
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
24
|
+
const message = createBasePBGltfContainerLoadingState();
|
|
25
|
+
while (reader.pos < end) {
|
|
26
|
+
const tag = reader.uint32();
|
|
27
|
+
switch (tag >>> 3) {
|
|
28
|
+
case 1:
|
|
29
|
+
if (tag != 8) {
|
|
30
|
+
break;
|
|
31
|
+
}
|
|
32
|
+
message.currentState = reader.int32();
|
|
33
|
+
continue;
|
|
34
|
+
}
|
|
35
|
+
if ((tag & 7) == 4 || tag == 0) {
|
|
36
|
+
break;
|
|
37
|
+
}
|
|
38
|
+
reader.skipType(tag & 7);
|
|
39
|
+
}
|
|
40
|
+
return message;
|
|
41
|
+
},
|
|
42
|
+
fromJSON(object) {
|
|
43
|
+
return { currentState: isSet(object.currentState) ? (0, loading_state_gen_1.loadingStateFromJSON)(object.currentState) : 0 };
|
|
44
|
+
},
|
|
45
|
+
toJSON(message) {
|
|
46
|
+
const obj = {};
|
|
47
|
+
message.currentState !== undefined && (obj.currentState = (0, loading_state_gen_1.loadingStateToJSON)(message.currentState));
|
|
48
|
+
return obj;
|
|
49
|
+
},
|
|
50
|
+
create(base) {
|
|
51
|
+
return exports.PBGltfContainerLoadingState.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
52
|
+
},
|
|
53
|
+
fromPartial(object) {
|
|
54
|
+
var _a;
|
|
55
|
+
const message = createBasePBGltfContainerLoadingState();
|
|
56
|
+
message.currentState = (_a = object.currentState) !== null && _a !== void 0 ? _a : 0;
|
|
57
|
+
return message;
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
function isSet(value) {
|
|
61
|
+
return value !== null && value !== undefined;
|
|
62
|
+
}
|
|
63
|
+
//# sourceMappingURL=gltf_container_loading_state.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gltf_container_loading_state.gen.js","sourceRoot":"","sources":["../../../../out-ts/decentraland/sdk/components/gltf_container_loading_state.gen.ts"],"names":[],"mappings":";;;;;;AAAA,oBAAoB;AACpB,iEAAqC;AACrC,kEAAoG;AAEvF,QAAA,eAAe,GAAG,6BAA6B,CAAC;AAU7D,SAAS,qCAAqC;IAC5C,OAAO,EAAE,YAAY,EAAE,CAAC,EAAE,CAAC;AAC7B,CAAC;AAEY,QAAA,2BAA2B,GAAG;IACzC,MAAM,CAAC,OAAoC,EAAE,SAAqB,iBAAG,CAAC,MAAM,CAAC,MAAM,EAAE;QACnF,IAAI,OAAO,CAAC,YAAY,KAAK,CAAC,EAAE;YAC9B,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC;SAC9C;QACD,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,MAAM,CAAC,KAA8B,EAAE,MAAe;QACpD,MAAM,MAAM,GAAG,KAAK,YAAY,iBAAG,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,iBAAG,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QAC9E,IAAI,GAAG,GAAG,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,GAAG,MAAM,CAAC;QAClE,MAAM,OAAO,GAAG,qCAAqC,EAAE,CAAC;QACxD,OAAO,MA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CAAC;AAcF,SAAS,KAAK,CAAC,KAAU;IACvB,OAAO,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,CAAC;AAC/C,CAAC"}
|
|
@@ -8,10 +8,12 @@ export interface PBPointerEventsResult {
|
|
|
8
8
|
button: InputAction;
|
|
9
9
|
hit: RaycastHit | undefined;
|
|
10
10
|
state: PointerEventType;
|
|
11
|
-
/**
|
|
11
|
+
/** monotonic counter */
|
|
12
12
|
timestamp: number;
|
|
13
13
|
/** if the input is analog then we store it here */
|
|
14
14
|
analog?: number | undefined;
|
|
15
|
+
/** number of tick in which the event was produced, equals to EngineInfo.tick_number */
|
|
16
|
+
tickNumber: number;
|
|
15
17
|
}
|
|
16
18
|
export declare const PBPointerEventsResult: {
|
|
17
19
|
encode(message: PBPointerEventsResult, writer?: _m0.Writer): _m0.Writer;
|
|
@@ -48,6 +50,7 @@ export declare const PBPointerEventsResult: {
|
|
|
48
50
|
state?: PointerEventType | undefined;
|
|
49
51
|
timestamp?: number | undefined;
|
|
50
52
|
analog?: number | undefined;
|
|
53
|
+
tickNumber?: number | undefined;
|
|
51
54
|
} & {
|
|
52
55
|
button?: InputAction | undefined;
|
|
53
56
|
hit?: ({
|
|
@@ -118,6 +121,7 @@ export declare const PBPointerEventsResult: {
|
|
|
118
121
|
state?: PointerEventType | undefined;
|
|
119
122
|
timestamp?: number | undefined;
|
|
120
123
|
analog?: number | undefined;
|
|
124
|
+
tickNumber?: number | undefined;
|
|
121
125
|
} & { [K_5 in Exclude<keyof I, keyof PBPointerEventsResult>]: never; }>(base?: I | undefined): PBPointerEventsResult;
|
|
122
126
|
fromPartial<I_1 extends {
|
|
123
127
|
button?: InputAction | undefined;
|
|
@@ -149,6 +153,7 @@ export declare const PBPointerEventsResult: {
|
|
|
149
153
|
state?: PointerEventType | undefined;
|
|
150
154
|
timestamp?: number | undefined;
|
|
151
155
|
analog?: number | undefined;
|
|
156
|
+
tickNumber?: number | undefined;
|
|
152
157
|
} & {
|
|
153
158
|
button?: InputAction | undefined;
|
|
154
159
|
hit?: ({
|
|
@@ -219,6 +224,7 @@ export declare const PBPointerEventsResult: {
|
|
|
219
224
|
state?: PointerEventType | undefined;
|
|
220
225
|
timestamp?: number | undefined;
|
|
221
226
|
analog?: number | undefined;
|
|
227
|
+
tickNumber?: number | undefined;
|
|
222
228
|
} & { [K_11 in Exclude<keyof I_1, keyof PBPointerEventsResult>]: never; }>(object: I_1): PBPointerEventsResult;
|
|
223
229
|
};
|
|
224
230
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
@@ -10,7 +10,7 @@ const input_action_gen_1 = require("./common/input_action.gen");
|
|
|
10
10
|
const raycast_hit_gen_1 = require("./common/raycast_hit.gen");
|
|
11
11
|
exports.protobufPackage = "decentraland.sdk.components";
|
|
12
12
|
function createBasePBPointerEventsResult() {
|
|
13
|
-
return { button: 0, hit: undefined, state: 0, timestamp: 0, analog: undefined };
|
|
13
|
+
return { button: 0, hit: undefined, state: 0, timestamp: 0, analog: undefined, tickNumber: 0 };
|
|
14
14
|
}
|
|
15
15
|
exports.PBPointerEventsResult = {
|
|
16
16
|
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
@@ -29,6 +29,9 @@ exports.PBPointerEventsResult = {
|
|
|
29
29
|
if (message.analog !== undefined) {
|
|
30
30
|
writer.uint32(53).float(message.analog);
|
|
31
31
|
}
|
|
32
|
+
if (message.tickNumber !== 0) {
|
|
33
|
+
writer.uint32(56).uint32(message.tickNumber);
|
|
34
|
+
}
|
|
32
35
|
return writer;
|
|
33
36
|
},
|
|
34
37
|
decode(input, length) {
|
|
@@ -68,6 +71,12 @@ exports.PBPointerEventsResult = {
|
|
|
68
71
|
}
|
|
69
72
|
message.analog = reader.float();
|
|
70
73
|
continue;
|
|
74
|
+
case 7:
|
|
75
|
+
if (tag != 56) {
|
|
76
|
+
break;
|
|
77
|
+
}
|
|
78
|
+
message.tickNumber = reader.uint32();
|
|
79
|
+
continue;
|
|
71
80
|
}
|
|
72
81
|
if ((tag & 7) == 4 || tag == 0) {
|
|
73
82
|
break;
|
|
@@ -83,6 +92,7 @@ exports.PBPointerEventsResult = {
|
|
|
83
92
|
state: isSet(object.state) ? (0, input_action_gen_1.pointerEventTypeFromJSON)(object.state) : 0,
|
|
84
93
|
timestamp: isSet(object.timestamp) ? Number(object.timestamp) : 0,
|
|
85
94
|
analog: isSet(object.analog) ? Number(object.analog) : undefined,
|
|
95
|
+
tickNumber: isSet(object.tickNumber) ? Number(object.tickNumber) : 0,
|
|
86
96
|
};
|
|
87
97
|
},
|
|
88
98
|
toJSON(message) {
|
|
@@ -92,19 +102,21 @@ exports.PBPointerEventsResult = {
|
|
|
92
102
|
message.state !== undefined && (obj.state = (0, input_action_gen_1.pointerEventTypeToJSON)(message.state));
|
|
93
103
|
message.timestamp !== undefined && (obj.timestamp = Math.round(message.timestamp));
|
|
94
104
|
message.analog !== undefined && (obj.analog = message.analog);
|
|
105
|
+
message.tickNumber !== undefined && (obj.tickNumber = Math.round(message.tickNumber));
|
|
95
106
|
return obj;
|
|
96
107
|
},
|
|
97
108
|
create(base) {
|
|
98
109
|
return exports.PBPointerEventsResult.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
99
110
|
},
|
|
100
111
|
fromPartial(object) {
|
|
101
|
-
var _a, _b, _c, _d;
|
|
112
|
+
var _a, _b, _c, _d, _e;
|
|
102
113
|
const message = createBasePBPointerEventsResult();
|
|
103
114
|
message.button = (_a = object.button) !== null && _a !== void 0 ? _a : 0;
|
|
104
115
|
message.hit = (object.hit !== undefined && object.hit !== null) ? raycast_hit_gen_1.RaycastHit.fromPartial(object.hit) : undefined;
|
|
105
116
|
message.state = (_b = object.state) !== null && _b !== void 0 ? _b : 0;
|
|
106
117
|
message.timestamp = (_c = object.timestamp) !== null && _c !== void 0 ? _c : 0;
|
|
107
118
|
message.analog = (_d = object.analog) !== null && _d !== void 0 ? _d : undefined;
|
|
119
|
+
message.tickNumber = (_e = object.tickNumber) !== null && _e !== void 0 ? _e : 0;
|
|
108
120
|
return message;
|
|
109
121
|
},
|
|
110
122
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pointer_events_result.gen.js","sourceRoot":"","sources":["../../../../out-ts/decentraland/sdk/components/pointer_events_result.gen.ts"],"names":[],"mappings":";;;;;;AAAA,oBAAoB;AACpB,iEAAqC;AACrC,gEAOmC;AACnC,8DAAsD;AAEzC,QAAA,eAAe,GAAG,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"pointer_events_result.gen.js","sourceRoot":"","sources":["../../../../out-ts/decentraland/sdk/components/pointer_events_result.gen.ts"],"names":[],"mappings":";;;;;;AAAA,oBAAoB;AACpB,iEAAqC;AACrC,gEAOmC;AACnC,8DAAsD;AAEzC,QAAA,eAAe,GAAG,6BAA6B,CAAC;AAkB7D,SAAS,+BAA+B;IACtC,OAAO,EAAE,MAAM,EAAE,CAAC,EAAE,GAAG,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,UAAU,EAAE,CAAC,EAAE,CAAC;AACjG,CAAC;AAEY,QAAA,qBAAqB,GAAG;IACnC,MAAM,CAAC,OAA8B,EAAE,SAAqB,iBAAG,CAAC,MAAM,CAAC,MAAM,EAAE;QAC7E,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE;YACxB,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;SACxC;QACD,IAAI,OAAO,CAAC,GAAG,KAAK,SAAS,EAAE;YAC7B,4BAAU,CAAC,MAAM,CAAC,OAAO,CAAC,GAAG,EAAE,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC;SACnE;QACD,IAAI,OAAO,CAAC,KAAK,KAAK,CAAC,EAAE;YACvB,MAAM,CAAC,MAAM,CAAC,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18,8 @@ export interface PBRaycastResult {
|
|
|
18
18
|
direction: Vector3 | undefined;
|
|
19
19
|
/** zero or more hits */
|
|
20
20
|
hits: RaycastHit[];
|
|
21
|
+
/** number of tick in which the event was produced, equals to EngineInfo.tick_number */
|
|
22
|
+
tickNumber: number;
|
|
21
23
|
}
|
|
22
24
|
export declare const PBRaycastResult: {
|
|
23
25
|
encode(message: PBRaycastResult, writer?: _m0.Writer): _m0.Writer;
|
|
@@ -61,6 +63,7 @@ export declare const PBRaycastResult: {
|
|
|
61
63
|
meshName?: string | undefined;
|
|
62
64
|
entityId?: number | undefined;
|
|
63
65
|
}[] | undefined;
|
|
66
|
+
tickNumber?: number | undefined;
|
|
64
67
|
} & {
|
|
65
68
|
timestamp?: number | undefined;
|
|
66
69
|
globalOrigin?: ({
|
|
@@ -194,6 +197,7 @@ export declare const PBRaycastResult: {
|
|
|
194
197
|
meshName?: string | undefined;
|
|
195
198
|
entityId?: number | undefined;
|
|
196
199
|
}[]>]: never; }) | undefined;
|
|
200
|
+
tickNumber?: number | undefined;
|
|
197
201
|
} & { [K_8 in Exclude<keyof I, keyof PBRaycastResult>]: never; }>(base?: I | undefined): PBRaycastResult;
|
|
198
202
|
fromPartial<I_1 extends {
|
|
199
203
|
timestamp?: number | undefined;
|
|
@@ -232,6 +236,7 @@ export declare const PBRaycastResult: {
|
|
|
232
236
|
meshName?: string | undefined;
|
|
233
237
|
entityId?: number | undefined;
|
|
234
238
|
}[] | undefined;
|
|
239
|
+
tickNumber?: number | undefined;
|
|
235
240
|
} & {
|
|
236
241
|
timestamp?: number | undefined;
|
|
237
242
|
globalOrigin?: ({
|
|
@@ -365,6 +370,7 @@ export declare const PBRaycastResult: {
|
|
|
365
370
|
meshName?: string | undefined;
|
|
366
371
|
entityId?: number | undefined;
|
|
367
372
|
}[]>]: never; }) | undefined;
|
|
373
|
+
tickNumber?: number | undefined;
|
|
368
374
|
} & { [K_17 in Exclude<keyof I_1, keyof PBRaycastResult>]: never; }>(object: I_1): PBRaycastResult;
|
|
369
375
|
};
|
|
370
376
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
@@ -10,7 +10,7 @@ const vectors_gen_1 = require("../../common/vectors.gen");
|
|
|
10
10
|
const raycast_hit_gen_1 = require("./common/raycast_hit.gen");
|
|
11
11
|
exports.protobufPackage = "decentraland.sdk.components";
|
|
12
12
|
function createBasePBRaycastResult() {
|
|
13
|
-
return { timestamp: undefined, globalOrigin: undefined, direction: undefined, hits: [] };
|
|
13
|
+
return { timestamp: undefined, globalOrigin: undefined, direction: undefined, hits: [], tickNumber: 0 };
|
|
14
14
|
}
|
|
15
15
|
exports.PBRaycastResult = {
|
|
16
16
|
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
@@ -26,6 +26,9 @@ exports.PBRaycastResult = {
|
|
|
26
26
|
for (const v of message.hits) {
|
|
27
27
|
raycast_hit_gen_1.RaycastHit.encode(v, writer.uint32(34).fork()).ldelim();
|
|
28
28
|
}
|
|
29
|
+
if (message.tickNumber !== 0) {
|
|
30
|
+
writer.uint32(40).uint32(message.tickNumber);
|
|
31
|
+
}
|
|
29
32
|
return writer;
|
|
30
33
|
},
|
|
31
34
|
decode(input, length) {
|
|
@@ -59,6 +62,12 @@ exports.PBRaycastResult = {
|
|
|
59
62
|
}
|
|
60
63
|
message.hits.push(raycast_hit_gen_1.RaycastHit.decode(reader, reader.uint32()));
|
|
61
64
|
continue;
|
|
65
|
+
case 5:
|
|
66
|
+
if (tag != 40) {
|
|
67
|
+
break;
|
|
68
|
+
}
|
|
69
|
+
message.tickNumber = reader.uint32();
|
|
70
|
+
continue;
|
|
62
71
|
}
|
|
63
72
|
if ((tag & 7) == 4 || tag == 0) {
|
|
64
73
|
break;
|
|
@@ -73,6 +82,7 @@ exports.PBRaycastResult = {
|
|
|
73
82
|
globalOrigin: isSet(object.globalOrigin) ? vectors_gen_1.Vector3.fromJSON(object.globalOrigin) : undefined,
|
|
74
83
|
direction: isSet(object.direction) ? vectors_gen_1.Vector3.fromJSON(object.direction) : undefined,
|
|
75
84
|
hits: Array.isArray(object === null || object === void 0 ? void 0 : object.hits) ? object.hits.map((e) => raycast_hit_gen_1.RaycastHit.fromJSON(e)) : [],
|
|
85
|
+
tickNumber: isSet(object.tickNumber) ? Number(object.tickNumber) : 0,
|
|
76
86
|
};
|
|
77
87
|
},
|
|
78
88
|
toJSON(message) {
|
|
@@ -88,13 +98,14 @@ exports.PBRaycastResult = {
|
|
|
88
98
|
else {
|
|
89
99
|
obj.hits = [];
|
|
90
100
|
}
|
|
101
|
+
message.tickNumber !== undefined && (obj.tickNumber = Math.round(message.tickNumber));
|
|
91
102
|
return obj;
|
|
92
103
|
},
|
|
93
104
|
create(base) {
|
|
94
105
|
return exports.PBRaycastResult.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
95
106
|
},
|
|
96
107
|
fromPartial(object) {
|
|
97
|
-
var _a, _b;
|
|
108
|
+
var _a, _b, _c;
|
|
98
109
|
const message = createBasePBRaycastResult();
|
|
99
110
|
message.timestamp = (_a = object.timestamp) !== null && _a !== void 0 ? _a : undefined;
|
|
100
111
|
message.globalOrigin = (object.globalOrigin !== undefined && object.globalOrigin !== null)
|
|
@@ -104,6 +115,7 @@ exports.PBRaycastResult = {
|
|
|
104
115
|
? vectors_gen_1.Vector3.fromPartial(object.direction)
|
|
105
116
|
: undefined;
|
|
106
117
|
message.hits = ((_b = object.hits) === null || _b === void 0 ? void 0 : _b.map((e) => raycast_hit_gen_1.RaycastHit.fromPartial(e))) || [];
|
|
118
|
+
message.tickNumber = (_c = object.tickNumber) !== null && _c !== void 0 ? _c : 0;
|
|
107
119
|
return message;
|
|
108
120
|
},
|
|
109
121
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"raycast_result.gen.js","sourceRoot":"","sources":["../../../../out-ts/decentraland/sdk/components/raycast_result.gen.ts"],"names":[],"mappings":";;;;;;AAAA,oBAAoB;AACpB,iEAAqC;AACrC,0DAAmD;AACnD,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|
+
export enum LoadingState {
|
|
6
|
+
UNKNOWN = 0,
|
|
7
|
+
LOADING = 1,
|
|
8
|
+
NOT_FOUND = 2,
|
|
9
|
+
FINISHED_WITH_ERROR = 3,
|
|
10
|
+
FINISHED = 4,
|
|
11
|
+
UNRECOGNIZED = -1,
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export function loadingStateFromJSON(object: any): LoadingState {
|
|
15
|
+
switch (object) {
|
|
16
|
+
case 0:
|
|
17
|
+
case "UNKNOWN":
|
|
18
|
+
return LoadingState.UNKNOWN;
|
|
19
|
+
case 1:
|
|
20
|
+
case "LOADING":
|
|
21
|
+
return LoadingState.LOADING;
|
|
22
|
+
case 2:
|
|
23
|
+
case "NOT_FOUND":
|
|
24
|
+
return LoadingState.NOT_FOUND;
|
|
25
|
+
case 3:
|
|
26
|
+
case "FINISHED_WITH_ERROR":
|
|
27
|
+
return LoadingState.FINISHED_WITH_ERROR;
|
|
28
|
+
case 4:
|
|
29
|
+
case "FINISHED":
|
|
30
|
+
return LoadingState.FINISHED;
|
|
31
|
+
case -1:
|
|
32
|
+
case "UNRECOGNIZED":
|
|
33
|
+
default:
|
|
34
|
+
return LoadingState.UNRECOGNIZED;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function loadingStateToJSON(object: LoadingState): string {
|
|
39
|
+
switch (object) {
|
|
40
|
+
case LoadingState.UNKNOWN:
|
|
41
|
+
return "UNKNOWN";
|
|
42
|
+
case LoadingState.LOADING:
|
|
43
|
+
return "LOADING";
|
|
44
|
+
case LoadingState.NOT_FOUND:
|
|
45
|
+
return "NOT_FOUND";
|
|
46
|
+
case LoadingState.FINISHED_WITH_ERROR:
|
|
47
|
+
return "FINISHED_WITH_ERROR";
|
|
48
|
+
case LoadingState.FINISHED:
|
|
49
|
+
return "FINISHED";
|
|
50
|
+
case LoadingState.UNRECOGNIZED:
|
|
51
|
+
default:
|
|
52
|
+
return "UNRECOGNIZED";
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import _m0 from "protobufjs/minimal";
|
|
3
|
+
|
|
4
|
+
export const protobufPackage = "decentraland.sdk.components";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* EngineInfo provides information about the graphics engine running the scene.
|
|
8
|
+
* The values of this component are written at the "physics" stage of the ADR-148. Meaning
|
|
9
|
+
* the tick_number and frame_number of the same frame could be used as correlation numbers
|
|
10
|
+
* for timestamps in other components.
|
|
11
|
+
*/
|
|
12
|
+
export interface PBEngineInfo {
|
|
13
|
+
/** frame counter of the engine */
|
|
14
|
+
frameNumber: number;
|
|
15
|
+
/** total runtime of this scene in seconds */
|
|
16
|
+
totalRuntime: number;
|
|
17
|
+
/** tick counter of the scene as per ADR-148 */
|
|
18
|
+
tickNumber: number;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
function createBasePBEngineInfo(): PBEngineInfo {
|
|
22
|
+
return { frameNumber: 0, totalRuntime: 0, tickNumber: 0 };
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export const PBEngineInfo = {
|
|
26
|
+
encode(message: PBEngineInfo, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
27
|
+
if (message.frameNumber !== 0) {
|
|
28
|
+
writer.uint32(8).uint32(message.frameNumber);
|
|
29
|
+
}
|
|
30
|
+
if (message.totalRuntime !== 0) {
|
|
31
|
+
writer.uint32(21).float(message.totalRuntime);
|
|
32
|
+
}
|
|
33
|
+
if (message.tickNumber !== 0) {
|
|
34
|
+
writer.uint32(24).uint32(message.tickNumber);
|
|
35
|
+
}
|
|
36
|
+
return writer;
|
|
37
|
+
},
|
|
38
|
+
|
|
39
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): PBEngineInfo {
|
|
40
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
41
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
42
|
+
const message = createBasePBEngineInfo();
|
|
43
|
+
while (reader.pos < end) {
|
|
44
|
+
const tag = reader.uint32();
|
|
45
|
+
switch (tag >>> 3) {
|
|
46
|
+
case 1:
|
|
47
|
+
if (tag != 8) {
|
|
48
|
+
break;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
message.frameNumber = reader.uint32();
|
|
52
|
+
continue;
|
|
53
|
+
case 2:
|
|
54
|
+
if (tag != 21) {
|
|
55
|
+
break;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
message.totalRuntime = reader.float();
|
|
59
|
+
continue;
|
|
60
|
+
case 3:
|
|
61
|
+
if (tag != 24) {
|
|
62
|
+
break;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
message.tickNumber = reader.uint32();
|
|
66
|
+
continue;
|
|
67
|
+
}
|
|
68
|
+
if ((tag & 7) == 4 || tag == 0) {
|
|
69
|
+
break;
|
|
70
|
+
}
|
|
71
|
+
reader.skipType(tag & 7);
|
|
72
|
+
}
|
|
73
|
+
return message;
|
|
74
|
+
},
|
|
75
|
+
|
|
76
|
+
fromJSON(object: any): PBEngineInfo {
|
|
77
|
+
return {
|
|
78
|
+
frameNumber: isSet(object.frameNumber) ? Number(object.frameNumber) : 0,
|
|
79
|
+
totalRuntime: isSet(object.totalRuntime) ? Number(object.totalRuntime) : 0,
|
|
80
|
+
tickNumber: isSet(object.tickNumber) ? Number(object.tickNumber) : 0,
|
|
81
|
+
};
|
|
82
|
+
},
|
|
83
|
+
|
|
84
|
+
toJSON(message: PBEngineInfo): unknown {
|
|
85
|
+
const obj: any = {};
|
|
86
|
+
message.frameNumber !== undefined && (obj.frameNumber = Math.round(message.frameNumber));
|
|
87
|
+
message.totalRuntime !== undefined && (obj.totalRuntime = message.totalRuntime);
|
|
88
|
+
message.tickNumber !== undefined && (obj.tickNumber = Math.round(message.tickNumber));
|
|
89
|
+
return obj;
|
|
90
|
+
},
|
|
91
|
+
|
|
92
|
+
create<I extends Exact<DeepPartial<PBEngineInfo>, I>>(base?: I): PBEngineInfo {
|
|
93
|
+
return PBEngineInfo.fromPartial(base ?? {});
|
|
94
|
+
},
|
|
95
|
+
|
|
96
|
+
fromPartial<I extends Exact<DeepPartial<PBEngineInfo>, I>>(object: I): PBEngineInfo {
|
|
97
|
+
const message = createBasePBEngineInfo();
|
|
98
|
+
message.frameNumber = object.frameNumber ?? 0;
|
|
99
|
+
message.totalRuntime = object.totalRuntime ?? 0;
|
|
100
|
+
message.tickNumber = object.tickNumber ?? 0;
|
|
101
|
+
return message;
|
|
102
|
+
},
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
106
|
+
|
|
107
|
+
export type DeepPartial<T> = T extends Builtin ? T
|
|
108
|
+
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
109
|
+
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
110
|
+
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
111
|
+
: Partial<T>;
|
|
112
|
+
|
|
113
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
114
|
+
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
115
|
+
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
116
|
+
|
|
117
|
+
function isSet(value: any): boolean {
|
|
118
|
+
return value !== null && value !== undefined;
|
|
119
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import _m0 from "protobufjs/minimal";
|
|
3
|
+
import { LoadingState, loadingStateFromJSON, loadingStateToJSON } from "./common/loading_state.gen";
|
|
4
|
+
|
|
5
|
+
export const protobufPackage = "decentraland.sdk.components";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* GltfContainerLoadingState is set by the engine and provides information about
|
|
9
|
+
* the current state of the GltfContainer of an entity.
|
|
10
|
+
*/
|
|
11
|
+
export interface PBGltfContainerLoadingState {
|
|
12
|
+
currentState: LoadingState;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
function createBasePBGltfContainerLoadingState(): PBGltfContainerLoadingState {
|
|
16
|
+
return { currentState: 0 };
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export const PBGltfContainerLoadingState = {
|
|
20
|
+
encode(message: PBGltfContainerLoadingState, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
21
|
+
if (message.currentState !== 0) {
|
|
22
|
+
writer.uint32(8).int32(message.currentState);
|
|
23
|
+
}
|
|
24
|
+
return writer;
|
|
25
|
+
},
|
|
26
|
+
|
|
27
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): PBGltfContainerLoadingState {
|
|
28
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
29
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
30
|
+
const message = createBasePBGltfContainerLoadingState();
|
|
31
|
+
while (reader.pos < end) {
|
|
32
|
+
const tag = reader.uint32();
|
|
33
|
+
switch (tag >>> 3) {
|
|
34
|
+
case 1:
|
|
35
|
+
if (tag != 8) {
|
|
36
|
+
break;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
message.currentState = reader.int32() as any;
|
|
40
|
+
continue;
|
|
41
|
+
}
|
|
42
|
+
if ((tag & 7) == 4 || tag == 0) {
|
|
43
|
+
break;
|
|
44
|
+
}
|
|
45
|
+
reader.skipType(tag & 7);
|
|
46
|
+
}
|
|
47
|
+
return message;
|
|
48
|
+
},
|
|
49
|
+
|
|
50
|
+
fromJSON(object: any): PBGltfContainerLoadingState {
|
|
51
|
+
return { currentState: isSet(object.currentState) ? loadingStateFromJSON(object.currentState) : 0 };
|
|
52
|
+
},
|
|
53
|
+
|
|
54
|
+
toJSON(message: PBGltfContainerLoadingState): unknown {
|
|
55
|
+
const obj: any = {};
|
|
56
|
+
message.currentState !== undefined && (obj.currentState = loadingStateToJSON(message.currentState));
|
|
57
|
+
return obj;
|
|
58
|
+
},
|
|
59
|
+
|
|
60
|
+
create<I extends Exact<DeepPartial<PBGltfContainerLoadingState>, I>>(base?: I): PBGltfContainerLoadingState {
|
|
61
|
+
return PBGltfContainerLoadingState.fromPartial(base ?? {});
|
|
62
|
+
},
|
|
63
|
+
|
|
64
|
+
fromPartial<I extends Exact<DeepPartial<PBGltfContainerLoadingState>, I>>(object: I): PBGltfContainerLoadingState {
|
|
65
|
+
const message = createBasePBGltfContainerLoadingState();
|
|
66
|
+
message.currentState = object.currentState ?? 0;
|
|
67
|
+
return message;
|
|
68
|
+
},
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
72
|
+
|
|
73
|
+
export type DeepPartial<T> = T extends Builtin ? T
|
|
74
|
+
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
75
|
+
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
76
|
+
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
77
|
+
: Partial<T>;
|
|
78
|
+
|
|
79
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
80
|
+
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
81
|
+
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
82
|
+
|
|
83
|
+
function isSet(value: any): boolean {
|
|
84
|
+
return value !== null && value !== undefined;
|
|
85
|
+
}
|
|
@@ -18,14 +18,18 @@ export interface PBPointerEventsResult {
|
|
|
18
18
|
button: InputAction;
|
|
19
19
|
hit: RaycastHit | undefined;
|
|
20
20
|
state: PointerEventType;
|
|
21
|
-
/**
|
|
21
|
+
/** monotonic counter */
|
|
22
22
|
timestamp: number;
|
|
23
23
|
/** if the input is analog then we store it here */
|
|
24
|
-
analog?:
|
|
24
|
+
analog?:
|
|
25
|
+
| number
|
|
26
|
+
| undefined;
|
|
27
|
+
/** number of tick in which the event was produced, equals to EngineInfo.tick_number */
|
|
28
|
+
tickNumber: number;
|
|
25
29
|
}
|
|
26
30
|
|
|
27
31
|
function createBasePBPointerEventsResult(): PBPointerEventsResult {
|
|
28
|
-
return { button: 0, hit: undefined, state: 0, timestamp: 0, analog: undefined };
|
|
32
|
+
return { button: 0, hit: undefined, state: 0, timestamp: 0, analog: undefined, tickNumber: 0 };
|
|
29
33
|
}
|
|
30
34
|
|
|
31
35
|
export const PBPointerEventsResult = {
|
|
@@ -45,6 +49,9 @@ export const PBPointerEventsResult = {
|
|
|
45
49
|
if (message.analog !== undefined) {
|
|
46
50
|
writer.uint32(53).float(message.analog);
|
|
47
51
|
}
|
|
52
|
+
if (message.tickNumber !== 0) {
|
|
53
|
+
writer.uint32(56).uint32(message.tickNumber);
|
|
54
|
+
}
|
|
48
55
|
return writer;
|
|
49
56
|
},
|
|
50
57
|
|
|
@@ -90,6 +97,13 @@ export const PBPointerEventsResult = {
|
|
|
90
97
|
|
|
91
98
|
message.analog = reader.float();
|
|
92
99
|
continue;
|
|
100
|
+
case 7:
|
|
101
|
+
if (tag != 56) {
|
|
102
|
+
break;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
message.tickNumber = reader.uint32();
|
|
106
|
+
continue;
|
|
93
107
|
}
|
|
94
108
|
if ((tag & 7) == 4 || tag == 0) {
|
|
95
109
|
break;
|
|
@@ -106,6 +120,7 @@ export const PBPointerEventsResult = {
|
|
|
106
120
|
state: isSet(object.state) ? pointerEventTypeFromJSON(object.state) : 0,
|
|
107
121
|
timestamp: isSet(object.timestamp) ? Number(object.timestamp) : 0,
|
|
108
122
|
analog: isSet(object.analog) ? Number(object.analog) : undefined,
|
|
123
|
+
tickNumber: isSet(object.tickNumber) ? Number(object.tickNumber) : 0,
|
|
109
124
|
};
|
|
110
125
|
},
|
|
111
126
|
|
|
@@ -116,6 +131,7 @@ export const PBPointerEventsResult = {
|
|
|
116
131
|
message.state !== undefined && (obj.state = pointerEventTypeToJSON(message.state));
|
|
117
132
|
message.timestamp !== undefined && (obj.timestamp = Math.round(message.timestamp));
|
|
118
133
|
message.analog !== undefined && (obj.analog = message.analog);
|
|
134
|
+
message.tickNumber !== undefined && (obj.tickNumber = Math.round(message.tickNumber));
|
|
119
135
|
return obj;
|
|
120
136
|
},
|
|
121
137
|
|
|
@@ -130,6 +146,7 @@ export const PBPointerEventsResult = {
|
|
|
130
146
|
message.state = object.state ?? 0;
|
|
131
147
|
message.timestamp = object.timestamp ?? 0;
|
|
132
148
|
message.analog = object.analog ?? undefined;
|
|
149
|
+
message.tickNumber = object.tickNumber ?? 0;
|
|
133
150
|
return message;
|
|
134
151
|
},
|
|
135
152
|
};
|
|
@@ -27,10 +27,12 @@ export interface PBRaycastResult {
|
|
|
27
27
|
| undefined;
|
|
28
28
|
/** zero or more hits */
|
|
29
29
|
hits: RaycastHit[];
|
|
30
|
+
/** number of tick in which the event was produced, equals to EngineInfo.tick_number */
|
|
31
|
+
tickNumber: number;
|
|
30
32
|
}
|
|
31
33
|
|
|
32
34
|
function createBasePBRaycastResult(): PBRaycastResult {
|
|
33
|
-
return { timestamp: undefined, globalOrigin: undefined, direction: undefined, hits: [] };
|
|
35
|
+
return { timestamp: undefined, globalOrigin: undefined, direction: undefined, hits: [], tickNumber: 0 };
|
|
34
36
|
}
|
|
35
37
|
|
|
36
38
|
export const PBRaycastResult = {
|
|
@@ -47,6 +49,9 @@ export const PBRaycastResult = {
|
|
|
47
49
|
for (const v of message.hits) {
|
|
48
50
|
RaycastHit.encode(v!, writer.uint32(34).fork()).ldelim();
|
|
49
51
|
}
|
|
52
|
+
if (message.tickNumber !== 0) {
|
|
53
|
+
writer.uint32(40).uint32(message.tickNumber);
|
|
54
|
+
}
|
|
50
55
|
return writer;
|
|
51
56
|
},
|
|
52
57
|
|
|
@@ -85,6 +90,13 @@ export const PBRaycastResult = {
|
|
|
85
90
|
|
|
86
91
|
message.hits.push(RaycastHit.decode(reader, reader.uint32()));
|
|
87
92
|
continue;
|
|
93
|
+
case 5:
|
|
94
|
+
if (tag != 40) {
|
|
95
|
+
break;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
message.tickNumber = reader.uint32();
|
|
99
|
+
continue;
|
|
88
100
|
}
|
|
89
101
|
if ((tag & 7) == 4 || tag == 0) {
|
|
90
102
|
break;
|
|
@@ -100,6 +112,7 @@ export const PBRaycastResult = {
|
|
|
100
112
|
globalOrigin: isSet(object.globalOrigin) ? Vector3.fromJSON(object.globalOrigin) : undefined,
|
|
101
113
|
direction: isSet(object.direction) ? Vector3.fromJSON(object.direction) : undefined,
|
|
102
114
|
hits: Array.isArray(object?.hits) ? object.hits.map((e: any) => RaycastHit.fromJSON(e)) : [],
|
|
115
|
+
tickNumber: isSet(object.tickNumber) ? Number(object.tickNumber) : 0,
|
|
103
116
|
};
|
|
104
117
|
},
|
|
105
118
|
|
|
@@ -115,6 +128,7 @@ export const PBRaycastResult = {
|
|
|
115
128
|
} else {
|
|
116
129
|
obj.hits = [];
|
|
117
130
|
}
|
|
131
|
+
message.tickNumber !== undefined && (obj.tickNumber = Math.round(message.tickNumber));
|
|
118
132
|
return obj;
|
|
119
133
|
},
|
|
120
134
|
|
|
@@ -132,6 +146,7 @@ export const PBRaycastResult = {
|
|
|
132
146
|
? Vector3.fromPartial(object.direction)
|
|
133
147
|
: undefined;
|
|
134
148
|
message.hits = object.hits?.map((e) => RaycastHit.fromPartial(e)) || [];
|
|
149
|
+
message.tickNumber = object.tickNumber ?? 0;
|
|
135
150
|
return message;
|
|
136
151
|
},
|
|
137
152
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dcl/protocol",
|
|
3
|
-
"version": "1.0.0-
|
|
3
|
+
"version": "1.0.0-4799189990.commit-8494b7b",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -26,5 +26,5 @@
|
|
|
26
26
|
"out-js",
|
|
27
27
|
"public"
|
|
28
28
|
],
|
|
29
|
-
"commit": "
|
|
29
|
+
"commit": "8494b7b7907af2d6276133b5c65e678c502e06af"
|
|
30
30
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
syntax = "proto3";
|
|
2
|
+
package decentraland.sdk.components;
|
|
3
|
+
|
|
4
|
+
import "decentraland/sdk/components/common/id.proto";
|
|
5
|
+
option (common.ecs_component_id) = 1048;
|
|
6
|
+
|
|
7
|
+
// EngineInfo provides information about the graphics engine running the scene.
|
|
8
|
+
// The values of this component are written at the "physics" stage of the ADR-148. Meaning
|
|
9
|
+
// the tick_number and frame_number of the same frame could be used as correlation numbers
|
|
10
|
+
// for timestamps in other components.
|
|
11
|
+
message PBEngineInfo {
|
|
12
|
+
uint32 frame_number = 1; // frame counter of the engine
|
|
13
|
+
float total_runtime = 2; // total runtime of this scene in seconds
|
|
14
|
+
uint32 tick_number = 3; // tick counter of the scene as per ADR-148
|
|
15
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
syntax = "proto3";
|
|
2
|
+
package decentraland.sdk.components;
|
|
3
|
+
|
|
4
|
+
import "decentraland/sdk/components/common/id.proto";
|
|
5
|
+
option (common.ecs_component_id) = 1049;
|
|
6
|
+
|
|
7
|
+
import "decentraland/sdk/components/common/loading_state.proto";
|
|
8
|
+
|
|
9
|
+
// GltfContainerLoadingState is set by the engine and provides information about
|
|
10
|
+
// the current state of the GltfContainer of an entity.
|
|
11
|
+
message PBGltfContainerLoadingState {
|
|
12
|
+
common.LoadingState current_state = 1;
|
|
13
|
+
}
|
|
@@ -13,6 +13,7 @@ message PBPointerEventsResult {
|
|
|
13
13
|
common.InputAction button = 1; // identifier of the input
|
|
14
14
|
common.RaycastHit hit = 2;
|
|
15
15
|
common.PointerEventType state = 4;
|
|
16
|
-
uint32 timestamp = 5; //
|
|
16
|
+
uint32 timestamp = 5; // monotonic counter
|
|
17
17
|
optional float analog = 6; // if the input is analog then we store it here
|
|
18
|
+
uint32 tick_number = 7; // number of tick in which the event was produced, equals to EngineInfo.tick_number
|
|
18
19
|
}
|
|
@@ -17,4 +17,5 @@ message PBRaycastResult {
|
|
|
17
17
|
decentraland.common.Vector3 global_origin = 2; // the starting point of the ray in global coordinates
|
|
18
18
|
decentraland.common.Vector3 direction = 3; // the direction vector of the ray in global coordinates
|
|
19
19
|
repeated decentraland.sdk.components.common.RaycastHit hits = 4; // zero or more hits
|
|
20
|
+
uint32 tick_number = 5; // number of tick in which the event was produced, equals to EngineInfo.tick_number
|
|
20
21
|
}
|
|
@@ -3,31 +3,33 @@ syntax = "proto3";
|
|
|
3
3
|
package decentraland.sdk.components;
|
|
4
4
|
|
|
5
5
|
import public "decentraland/sdk/components/animator.proto";
|
|
6
|
-
import public "decentraland/sdk/components/material.proto";
|
|
7
|
-
import public "decentraland/sdk/components/ui_background.proto";
|
|
8
6
|
import public "decentraland/sdk/components/audio_source.proto";
|
|
9
|
-
import public "decentraland/sdk/components/mesh_collider.proto";
|
|
10
|
-
import public "decentraland/sdk/components/ui_dropdown.proto";
|
|
11
7
|
import public "decentraland/sdk/components/audio_stream.proto";
|
|
12
|
-
import public "decentraland/sdk/components/mesh_renderer.proto";
|
|
13
|
-
import public "decentraland/sdk/components/ui_dropdown_result.proto";
|
|
14
8
|
import public "decentraland/sdk/components/avatar_attach.proto";
|
|
15
|
-
import public "decentraland/sdk/components/nft_shape.proto";
|
|
16
|
-
import public "decentraland/sdk/components/ui_input.proto";
|
|
17
9
|
import public "decentraland/sdk/components/avatar_modifier_area.proto";
|
|
18
|
-
import public "decentraland/sdk/components/pointer_events.proto";
|
|
19
|
-
import public "decentraland/sdk/components/ui_input_result.proto";
|
|
20
10
|
import public "decentraland/sdk/components/avatar_shape.proto";
|
|
21
|
-
import public "decentraland/sdk/components/pointer_events_result.proto";
|
|
22
|
-
import public "decentraland/sdk/components/ui_text.proto";
|
|
23
11
|
import public "decentraland/sdk/components/billboard.proto";
|
|
24
|
-
import public "decentraland/sdk/components/
|
|
25
|
-
import public "decentraland/sdk/components/ui_transform.proto";
|
|
12
|
+
import public "decentraland/sdk/components/camera_mode_area.proto";
|
|
26
13
|
import public "decentraland/sdk/components/camera_mode.proto";
|
|
14
|
+
import public "decentraland/sdk/components/engine_info.proto";
|
|
15
|
+
import public "decentraland/sdk/components/gltf_container.proto";
|
|
16
|
+
import public "decentraland/sdk/components/gltf_container_loading_state.proto";
|
|
17
|
+
import public "decentraland/sdk/components/material.proto";
|
|
18
|
+
import public "decentraland/sdk/components/mesh_collider.proto";
|
|
19
|
+
import public "decentraland/sdk/components/mesh_renderer.proto";
|
|
20
|
+
import public "decentraland/sdk/components/nft_shape.proto";
|
|
21
|
+
import public "decentraland/sdk/components/pointer_events_result.proto";
|
|
22
|
+
import public "decentraland/sdk/components/pointer_events.proto";
|
|
23
|
+
import public "decentraland/sdk/components/pointer_lock.proto";
|
|
24
|
+
import public "decentraland/sdk/components/raycast_result.proto";
|
|
27
25
|
import public "decentraland/sdk/components/raycast.proto";
|
|
26
|
+
import public "decentraland/sdk/components/text_shape.proto";
|
|
27
|
+
import public "decentraland/sdk/components/ui_background.proto";
|
|
28
|
+
import public "decentraland/sdk/components/ui_dropdown_result.proto";
|
|
29
|
+
import public "decentraland/sdk/components/ui_dropdown.proto";
|
|
30
|
+
import public "decentraland/sdk/components/ui_input_result.proto";
|
|
31
|
+
import public "decentraland/sdk/components/ui_input.proto";
|
|
32
|
+
import public "decentraland/sdk/components/ui_text.proto";
|
|
33
|
+
import public "decentraland/sdk/components/ui_transform.proto";
|
|
28
34
|
import public "decentraland/sdk/components/video_player.proto";
|
|
29
|
-
import public "decentraland/sdk/components/camera_mode_area.proto";
|
|
30
|
-
import public "decentraland/sdk/components/raycast_result.proto";
|
|
31
35
|
import public "decentraland/sdk/components/visibility_component.proto";
|
|
32
|
-
import public "decentraland/sdk/components/gltf_container.proto";
|
|
33
|
-
import public "decentraland/sdk/components/text_shape.proto";
|