@dcl/protocol 1.0.0-33676972450.commit-882d4ee → 1.0.0-33861349213.commit-76445a6
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/common/texture.gen.d.ts +0 -18
- package/out-js/decentraland/common/texture.gen.js +4 -104
- package/out-js/decentraland/common/texture.gen.js.map +1 -1
- package/out-js/decentraland/kernel/apis/restricted_actions.gen.d.ts +4 -125
- package/out-js/decentraland/kernel/apis/restricted_actions.gen.js +6 -408
- package/out-js/decentraland/kernel/apis/restricted_actions.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/avatar_equipped_data.gen.d.ts +0 -2
- package/out-js/decentraland/sdk/components/avatar_equipped_data.gen.js +2 -19
- package/out-js/decentraland/sdk/components/avatar_equipped_data.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/avatar_modifier_area.gen.d.ts +0 -2
- package/out-js/decentraland/sdk/components/avatar_modifier_area.gen.js +2 -14
- package/out-js/decentraland/sdk/components/avatar_modifier_area.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/avatar_nametag.gen.d.ts +58 -0
- package/out-js/decentraland/sdk/components/avatar_nametag.gen.js +117 -0
- package/out-js/decentraland/sdk/components/avatar_nametag.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/avatar_shape.gen.d.ts +0 -2
- package/out-js/decentraland/sdk/components/avatar_shape.gen.js +1 -19
- package/out-js/decentraland/sdk/components/avatar_shape.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/camera_mode_area.gen.d.ts +0 -2
- package/out-js/decentraland/sdk/components/camera_mode_area.gen.js +2 -14
- package/out-js/decentraland/sdk/components/camera_mode_area.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/common/input_action.gen.d.ts +0 -3
- package/out-js/decentraland/sdk/components/common/input_action.gen.js +0 -18
- package/out-js/decentraland/sdk/components/common/input_action.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/gltf_container_loading_state.gen.d.ts +0 -19
- package/out-js/decentraland/sdk/components/gltf_container_loading_state.gen.js +3 -90
- package/out-js/decentraland/sdk/components/gltf_container_loading_state.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/material.gen.d.ts +0 -20
- package/out-js/decentraland/sdk/components/material.gen.js +2 -86
- package/out-js/decentraland/sdk/components/material.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/mesh_collider.gen.d.ts +0 -18
- package/out-js/decentraland/sdk/components/mesh_collider.gen.js +4 -90
- package/out-js/decentraland/sdk/components/mesh_collider.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/mesh_renderer.gen.d.ts +3 -19
- package/out-js/decentraland/sdk/components/mesh_renderer.gen.js +4 -90
- package/out-js/decentraland/sdk/components/mesh_renderer.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/pointer_events.gen.d.ts +16 -11
- package/out-js/decentraland/sdk/components/pointer_events.gen.js +14 -1
- package/out-js/decentraland/sdk/components/pointer_events.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/raycast.gen.d.ts +0 -13
- package/out-js/decentraland/sdk/components/raycast.gen.js +2 -64
- package/out-js/decentraland/sdk/components/raycast.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/ui_input.gen.d.ts +0 -4
- package/out-js/decentraland/sdk/components/ui_input.gen.js +1 -27
- package/out-js/decentraland/sdk/components/ui_input.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/ui_transform.gen.d.ts +0 -33
- package/out-js/decentraland/sdk/components/ui_transform.gen.js +3 -176
- package/out-js/decentraland/sdk/components/ui_transform.gen.js.map +1 -1
- package/out-ts/decentraland/common/texture.gen.ts +4 -119
- package/out-ts/decentraland/kernel/apis/restricted_actions.gen.ts +6 -445
- package/out-ts/decentraland/sdk/components/avatar_equipped_data.gen.ts +1 -20
- package/out-ts/decentraland/sdk/components/avatar_modifier_area.gen.ts +1 -16
- package/out-ts/decentraland/sdk/components/avatar_nametag.gen.ts +162 -0
- package/out-ts/decentraland/sdk/components/avatar_shape.gen.ts +1 -23
- package/out-ts/decentraland/sdk/components/camera_mode_area.gen.ts +1 -16
- package/out-ts/decentraland/sdk/components/common/input_action.gen.ts +0 -18
- package/out-ts/decentraland/sdk/components/gltf_container_loading_state.gen.ts +2 -108
- package/out-ts/decentraland/sdk/components/material.gen.ts +1 -102
- package/out-ts/decentraland/sdk/components/mesh_collider.gen.ts +0 -99
- package/out-ts/decentraland/sdk/components/mesh_renderer.gen.ts +3 -100
- package/out-ts/decentraland/sdk/components/pointer_events.gen.ts +33 -12
- package/out-ts/decentraland/sdk/components/raycast.gen.ts +1 -73
- package/out-ts/decentraland/sdk/components/ui_input.gen.ts +1 -37
- package/out-ts/decentraland/sdk/components/ui_transform.gen.ts +0 -193
- package/package.json +2 -2
- package/proto/decentraland/common/texture.proto +1 -8
- package/proto/decentraland/kernel/apis/restricted_actions.proto +1 -45
- package/proto/decentraland/pulse/pulse_client.proto +27 -8
- package/proto/decentraland/sdk/components/avatar_equipped_data.proto +1 -2
- package/proto/decentraland/sdk/components/avatar_modifier_area.proto +0 -1
- package/proto/decentraland/sdk/components/avatar_nametag.proto +33 -0
- package/proto/decentraland/sdk/components/avatar_shape.proto +0 -1
- package/proto/decentraland/sdk/components/camera_mode_area.proto +0 -1
- package/proto/decentraland/sdk/components/common/input_action.proto +0 -3
- package/proto/decentraland/sdk/components/gltf_container_loading_state.proto +0 -13
- package/proto/decentraland/sdk/components/material.proto +1 -13
- package/proto/decentraland/sdk/components/mesh_collider.proto +0 -7
- package/proto/decentraland/sdk/components/mesh_renderer.proto +3 -8
- package/proto/decentraland/sdk/components/pointer_events.proto +15 -11
- package/proto/decentraland/sdk/components/primary_pointer_info.proto +0 -5
- package/proto/decentraland/sdk/components/raycast.proto +0 -13
- package/proto/decentraland/sdk/components/ui_input.proto +0 -2
- package/proto/decentraland/sdk/components/ui_transform.proto +0 -20
- package/public/sdk-components.proto +1 -10
- package/out-js/decentraland/sdk/components/avatar_locomotion_settings.gen.d.ts +0 -51
- package/out-js/decentraland/sdk/components/avatar_locomotion_settings.gen.js +0 -177
- package/out-js/decentraland/sdk/components/avatar_locomotion_settings.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/avatar_movement.gen.d.ts +0 -71
- package/out-js/decentraland/sdk/components/avatar_movement.gen.js +0 -303
- package/out-js/decentraland/sdk/components/avatar_movement.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/avatar_movement_info.gen.d.ts +0 -79
- package/out-js/decentraland/sdk/components/avatar_movement_info.gen.js +0 -357
- package/out-js/decentraland/sdk/components/avatar_movement_info.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/camera_layer.gen.d.ts +0 -46
- package/out-js/decentraland/sdk/components/camera_layer.gen.js +0 -162
- package/out-js/decentraland/sdk/components/camera_layer.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/camera_layers.gen.d.ts +0 -30
- package/out-js/decentraland/sdk/components/camera_layers.gen.js +0 -80
- package/out-js/decentraland/sdk/components/camera_layers.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/global_light.gen.d.ts +0 -50
- package/out-js/decentraland/sdk/components/global_light.gen.js +0 -103
- package/out-js/decentraland/sdk/components/global_light.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/gltf_node.gen.d.ts +0 -66
- package/out-js/decentraland/sdk/components/gltf_node.gen.js +0 -69
- package/out-js/decentraland/sdk/components/gltf_node.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/gltf_node_state.gen.d.ts +0 -43
- package/out-js/decentraland/sdk/components/gltf_node_state.gen.js +0 -122
- package/out-js/decentraland/sdk/components/gltf_node_state.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/input_modifier.gen.d.ts +0 -52
- package/out-js/decentraland/sdk/components/input_modifier.gen.js +0 -233
- package/out-js/decentraland/sdk/components/input_modifier.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/texture_camera.gen.d.ts +0 -86
- package/out-js/decentraland/sdk/components/texture_camera.gen.js +0 -296
- package/out-js/decentraland/sdk/components/texture_camera.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/ui_canvas.gen.d.ts +0 -35
- package/out-js/decentraland/sdk/components/ui_canvas.gen.js +0 -98
- package/out-js/decentraland/sdk/components/ui_canvas.gen.js.map +0 -1
- package/out-js/decentraland/sdk/components/ui_scroll_result.gen.d.ts +0 -31
- package/out-js/decentraland/sdk/components/ui_scroll_result.gen.js +0 -71
- package/out-js/decentraland/sdk/components/ui_scroll_result.gen.js.map +0 -1
- package/out-ts/decentraland/sdk/components/avatar_locomotion_settings.gen.ts +0 -237
- package/out-ts/decentraland/sdk/components/avatar_movement.gen.ts +0 -372
- package/out-ts/decentraland/sdk/components/avatar_movement_info.gen.ts +0 -432
- package/out-ts/decentraland/sdk/components/camera_layer.gen.ts +0 -202
- package/out-ts/decentraland/sdk/components/camera_layers.gen.ts +0 -92
- package/out-ts/decentraland/sdk/components/global_light.gen.ts +0 -138
- package/out-ts/decentraland/sdk/components/gltf_node.gen.ts +0 -116
- package/out-ts/decentraland/sdk/components/gltf_node_state.gen.ts +0 -139
- package/out-ts/decentraland/sdk/components/input_modifier.gen.ts +0 -265
- package/out-ts/decentraland/sdk/components/texture_camera.gen.ts +0 -362
- package/out-ts/decentraland/sdk/components/ui_canvas.gen.ts +0 -115
- package/out-ts/decentraland/sdk/components/ui_scroll_result.gen.ts +0 -83
- package/proto/decentraland/sdk/components/avatar_movement.proto +0 -62
- package/proto/decentraland/sdk/components/avatar_movement_info.proto +0 -36
- package/proto/decentraland/sdk/components/camera_layer.proto +0 -30
- package/proto/decentraland/sdk/components/camera_layers.proto +0 -11
- package/proto/decentraland/sdk/components/global_light.proto +0 -22
- package/proto/decentraland/sdk/components/gltf_node.proto +0 -42
- package/proto/decentraland/sdk/components/gltf_node_state.proto +0 -20
- package/proto/decentraland/sdk/components/texture_camera.proto +0 -46
- package/proto/decentraland/sdk/components/ui_canvas.proto +0 -16
- package/proto/decentraland/sdk/components/ui_scroll_result.proto +0 -12
|
@@ -1,372 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import _m0 from "protobufjs/minimal";
|
|
3
|
-
import { Vector3 } from "../../common/vectors.gen";
|
|
4
|
-
|
|
5
|
-
export const protobufPackage = "decentraland.sdk.components";
|
|
6
|
-
|
|
7
|
-
export interface PBAvatarMovement {
|
|
8
|
-
velocity:
|
|
9
|
-
| Vector3
|
|
10
|
-
| undefined;
|
|
11
|
-
/** 0-360, yaw only; this is the authoritative facing (other clients read it, and physics treats the avatar as upright). Lean is expressed separately via tilt_pitch/tilt_roll. */
|
|
12
|
-
orientation: number;
|
|
13
|
-
groundDirection?:
|
|
14
|
-
| Vector3
|
|
15
|
-
| undefined;
|
|
16
|
-
/** set for one frame when a walk_target ends: true = reached target, false = failed; absent = in progress or no walk */
|
|
17
|
-
walkSuccess?:
|
|
18
|
-
| boolean
|
|
19
|
-
| undefined;
|
|
20
|
-
/** if set, the engine plays this animation instead of selecting one from velocity heuristics */
|
|
21
|
-
animation?:
|
|
22
|
-
| MovementAnimation
|
|
23
|
-
| undefined;
|
|
24
|
-
/** render-only forward/back lean in degrees, applied on top of `orientation` (rotation about the avatar's local X axis). Does not affect the physics capsule (stays upright) or the facing other clients read. Defaults to 0. */
|
|
25
|
-
tiltPitch?:
|
|
26
|
-
| number
|
|
27
|
-
| undefined;
|
|
28
|
-
/** render-only sideways lean in degrees, applied on top of `orientation` (rotation about the avatar's local Z axis). Same constraints as tilt_pitch. Useful e.g. for glider banking. Defaults to 0. */
|
|
29
|
-
tiltRoll?: number | undefined;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
/**
|
|
33
|
-
* Describes the animation the movement scene wants the avatar to play.
|
|
34
|
-
* One GLB = one clip (following the scene-emote convention: single clip, or a clip named with `_Avatar` suffix).
|
|
35
|
-
* When absent the engine falls back to its built-in velocity-based selection (walk/run/jump/idle).
|
|
36
|
-
*/
|
|
37
|
-
export interface MovementAnimation {
|
|
38
|
-
/** scene-relative path to the gltf/glb asset (resolved via the scene content map) */
|
|
39
|
-
src: string;
|
|
40
|
-
/** whether the clip repeats once it reaches the end */
|
|
41
|
-
loop: boolean;
|
|
42
|
-
/** playback speed multiplier (1.0 = clip's native rate) */
|
|
43
|
-
speed: number;
|
|
44
|
-
/** true: a triggerSceneEmote may take over; false: emotes are suppressed while this animation plays */
|
|
45
|
-
idle: boolean;
|
|
46
|
-
/** cross-fade duration when `src` changes; defaults to 0.2 when unset. Not applied to loop/speed/idle changes. */
|
|
47
|
-
transitionSeconds?:
|
|
48
|
-
| number
|
|
49
|
-
| undefined;
|
|
50
|
-
/** if set, the engine seeks to this position (in seconds) this frame. Clear on subsequent frames to allow normal playback. The scene can read `AvatarAnimationState.playback_time` first to decide. */
|
|
51
|
-
playbackTime?:
|
|
52
|
-
| number
|
|
53
|
-
| undefined;
|
|
54
|
-
/** scene-relative paths to audio clips (.mp3/.ogg) to play this frame on the avatar audio bus. Fire-and-forget: each listed clip plays once per frame it appears; leaving a clip set for multiple frames re-triggers it. No stop mechanism. Use `AvatarAnimationState.playback_time` to trigger sounds at the right point in the clip (e.g. foot plants). */
|
|
55
|
-
sounds: string[];
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
function createBasePBAvatarMovement(): PBAvatarMovement {
|
|
59
|
-
return {
|
|
60
|
-
velocity: undefined,
|
|
61
|
-
orientation: 0,
|
|
62
|
-
groundDirection: undefined,
|
|
63
|
-
walkSuccess: undefined,
|
|
64
|
-
animation: undefined,
|
|
65
|
-
tiltPitch: undefined,
|
|
66
|
-
tiltRoll: undefined,
|
|
67
|
-
};
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
export namespace PBAvatarMovement {
|
|
71
|
-
export function encode(message: PBAvatarMovement, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
72
|
-
if (message.velocity !== undefined) {
|
|
73
|
-
Vector3.encode(message.velocity, writer.uint32(10).fork()).ldelim();
|
|
74
|
-
}
|
|
75
|
-
if (message.orientation !== 0) {
|
|
76
|
-
writer.uint32(21).float(message.orientation);
|
|
77
|
-
}
|
|
78
|
-
if (message.groundDirection !== undefined) {
|
|
79
|
-
Vector3.encode(message.groundDirection, writer.uint32(26).fork()).ldelim();
|
|
80
|
-
}
|
|
81
|
-
if (message.walkSuccess !== undefined) {
|
|
82
|
-
writer.uint32(32).bool(message.walkSuccess);
|
|
83
|
-
}
|
|
84
|
-
if (message.animation !== undefined) {
|
|
85
|
-
MovementAnimation.encode(message.animation, writer.uint32(42).fork()).ldelim();
|
|
86
|
-
}
|
|
87
|
-
if (message.tiltPitch !== undefined) {
|
|
88
|
-
writer.uint32(53).float(message.tiltPitch);
|
|
89
|
-
}
|
|
90
|
-
if (message.tiltRoll !== undefined) {
|
|
91
|
-
writer.uint32(61).float(message.tiltRoll);
|
|
92
|
-
}
|
|
93
|
-
return writer;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): PBAvatarMovement {
|
|
97
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
98
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
99
|
-
const message = createBasePBAvatarMovement();
|
|
100
|
-
while (reader.pos < end) {
|
|
101
|
-
const tag = reader.uint32();
|
|
102
|
-
switch (tag >>> 3) {
|
|
103
|
-
case 1:
|
|
104
|
-
if (tag !== 10) {
|
|
105
|
-
break;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
message.velocity = Vector3.decode(reader, reader.uint32());
|
|
109
|
-
continue;
|
|
110
|
-
case 2:
|
|
111
|
-
if (tag !== 21) {
|
|
112
|
-
break;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
message.orientation = reader.float();
|
|
116
|
-
continue;
|
|
117
|
-
case 3:
|
|
118
|
-
if (tag !== 26) {
|
|
119
|
-
break;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
message.groundDirection = Vector3.decode(reader, reader.uint32());
|
|
123
|
-
continue;
|
|
124
|
-
case 4:
|
|
125
|
-
if (tag !== 32) {
|
|
126
|
-
break;
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
message.walkSuccess = reader.bool();
|
|
130
|
-
continue;
|
|
131
|
-
case 5:
|
|
132
|
-
if (tag !== 42) {
|
|
133
|
-
break;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
message.animation = MovementAnimation.decode(reader, reader.uint32());
|
|
137
|
-
continue;
|
|
138
|
-
case 6:
|
|
139
|
-
if (tag !== 53) {
|
|
140
|
-
break;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
message.tiltPitch = reader.float();
|
|
144
|
-
continue;
|
|
145
|
-
case 7:
|
|
146
|
-
if (tag !== 61) {
|
|
147
|
-
break;
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
message.tiltRoll = reader.float();
|
|
151
|
-
continue;
|
|
152
|
-
}
|
|
153
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
154
|
-
break;
|
|
155
|
-
}
|
|
156
|
-
reader.skipType(tag & 7);
|
|
157
|
-
}
|
|
158
|
-
return message;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
export function fromJSON(object: any): PBAvatarMovement {
|
|
162
|
-
return {
|
|
163
|
-
velocity: isSet(object.velocity) ? Vector3.fromJSON(object.velocity) : undefined,
|
|
164
|
-
orientation: isSet(object.orientation) ? Number(object.orientation) : 0,
|
|
165
|
-
groundDirection: isSet(object.groundDirection) ? Vector3.fromJSON(object.groundDirection) : undefined,
|
|
166
|
-
walkSuccess: isSet(object.walkSuccess) ? Boolean(object.walkSuccess) : undefined,
|
|
167
|
-
animation: isSet(object.animation) ? MovementAnimation.fromJSON(object.animation) : undefined,
|
|
168
|
-
tiltPitch: isSet(object.tiltPitch) ? Number(object.tiltPitch) : undefined,
|
|
169
|
-
tiltRoll: isSet(object.tiltRoll) ? Number(object.tiltRoll) : undefined,
|
|
170
|
-
};
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
export function toJSON(message: PBAvatarMovement): unknown {
|
|
174
|
-
const obj: any = {};
|
|
175
|
-
message.velocity !== undefined && (obj.velocity = message.velocity ? Vector3.toJSON(message.velocity) : undefined);
|
|
176
|
-
message.orientation !== undefined && (obj.orientation = message.orientation);
|
|
177
|
-
message.groundDirection !== undefined &&
|
|
178
|
-
(obj.groundDirection = message.groundDirection ? Vector3.toJSON(message.groundDirection) : undefined);
|
|
179
|
-
message.walkSuccess !== undefined && (obj.walkSuccess = message.walkSuccess);
|
|
180
|
-
message.animation !== undefined &&
|
|
181
|
-
(obj.animation = message.animation ? MovementAnimation.toJSON(message.animation) : undefined);
|
|
182
|
-
message.tiltPitch !== undefined && (obj.tiltPitch = message.tiltPitch);
|
|
183
|
-
message.tiltRoll !== undefined && (obj.tiltRoll = message.tiltRoll);
|
|
184
|
-
return obj;
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
export function create<I extends Exact<DeepPartial<PBAvatarMovement>, I>>(base?: I): PBAvatarMovement {
|
|
188
|
-
return PBAvatarMovement.fromPartial(base ?? {});
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
export function fromPartial<I extends Exact<DeepPartial<PBAvatarMovement>, I>>(object: I): PBAvatarMovement {
|
|
192
|
-
const message = createBasePBAvatarMovement();
|
|
193
|
-
message.velocity = (object.velocity !== undefined && object.velocity !== null)
|
|
194
|
-
? Vector3.fromPartial(object.velocity)
|
|
195
|
-
: undefined;
|
|
196
|
-
message.orientation = object.orientation ?? 0;
|
|
197
|
-
message.groundDirection = (object.groundDirection !== undefined && object.groundDirection !== null)
|
|
198
|
-
? Vector3.fromPartial(object.groundDirection)
|
|
199
|
-
: undefined;
|
|
200
|
-
message.walkSuccess = object.walkSuccess ?? undefined;
|
|
201
|
-
message.animation = (object.animation !== undefined && object.animation !== null)
|
|
202
|
-
? MovementAnimation.fromPartial(object.animation)
|
|
203
|
-
: undefined;
|
|
204
|
-
message.tiltPitch = object.tiltPitch ?? undefined;
|
|
205
|
-
message.tiltRoll = object.tiltRoll ?? undefined;
|
|
206
|
-
return message;
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
function createBaseMovementAnimation(): MovementAnimation {
|
|
211
|
-
return {
|
|
212
|
-
src: "",
|
|
213
|
-
loop: false,
|
|
214
|
-
speed: 0,
|
|
215
|
-
idle: false,
|
|
216
|
-
transitionSeconds: undefined,
|
|
217
|
-
playbackTime: undefined,
|
|
218
|
-
sounds: [],
|
|
219
|
-
};
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
export namespace MovementAnimation {
|
|
223
|
-
export function encode(message: MovementAnimation, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
224
|
-
if (message.src !== "") {
|
|
225
|
-
writer.uint32(10).string(message.src);
|
|
226
|
-
}
|
|
227
|
-
if (message.loop === true) {
|
|
228
|
-
writer.uint32(16).bool(message.loop);
|
|
229
|
-
}
|
|
230
|
-
if (message.speed !== 0) {
|
|
231
|
-
writer.uint32(29).float(message.speed);
|
|
232
|
-
}
|
|
233
|
-
if (message.idle === true) {
|
|
234
|
-
writer.uint32(32).bool(message.idle);
|
|
235
|
-
}
|
|
236
|
-
if (message.transitionSeconds !== undefined) {
|
|
237
|
-
writer.uint32(45).float(message.transitionSeconds);
|
|
238
|
-
}
|
|
239
|
-
if (message.playbackTime !== undefined) {
|
|
240
|
-
writer.uint32(53).float(message.playbackTime);
|
|
241
|
-
}
|
|
242
|
-
for (const v of message.sounds) {
|
|
243
|
-
writer.uint32(58).string(v!);
|
|
244
|
-
}
|
|
245
|
-
return writer;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): MovementAnimation {
|
|
249
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
250
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
251
|
-
const message = createBaseMovementAnimation();
|
|
252
|
-
while (reader.pos < end) {
|
|
253
|
-
const tag = reader.uint32();
|
|
254
|
-
switch (tag >>> 3) {
|
|
255
|
-
case 1:
|
|
256
|
-
if (tag !== 10) {
|
|
257
|
-
break;
|
|
258
|
-
}
|
|
259
|
-
|
|
260
|
-
message.src = reader.string();
|
|
261
|
-
continue;
|
|
262
|
-
case 2:
|
|
263
|
-
if (tag !== 16) {
|
|
264
|
-
break;
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
message.loop = reader.bool();
|
|
268
|
-
continue;
|
|
269
|
-
case 3:
|
|
270
|
-
if (tag !== 29) {
|
|
271
|
-
break;
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
message.speed = reader.float();
|
|
275
|
-
continue;
|
|
276
|
-
case 4:
|
|
277
|
-
if (tag !== 32) {
|
|
278
|
-
break;
|
|
279
|
-
}
|
|
280
|
-
|
|
281
|
-
message.idle = reader.bool();
|
|
282
|
-
continue;
|
|
283
|
-
case 5:
|
|
284
|
-
if (tag !== 45) {
|
|
285
|
-
break;
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
message.transitionSeconds = reader.float();
|
|
289
|
-
continue;
|
|
290
|
-
case 6:
|
|
291
|
-
if (tag !== 53) {
|
|
292
|
-
break;
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
message.playbackTime = reader.float();
|
|
296
|
-
continue;
|
|
297
|
-
case 7:
|
|
298
|
-
if (tag !== 58) {
|
|
299
|
-
break;
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
message.sounds.push(reader.string());
|
|
303
|
-
continue;
|
|
304
|
-
}
|
|
305
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
306
|
-
break;
|
|
307
|
-
}
|
|
308
|
-
reader.skipType(tag & 7);
|
|
309
|
-
}
|
|
310
|
-
return message;
|
|
311
|
-
}
|
|
312
|
-
|
|
313
|
-
export function fromJSON(object: any): MovementAnimation {
|
|
314
|
-
return {
|
|
315
|
-
src: isSet(object.src) ? String(object.src) : "",
|
|
316
|
-
loop: isSet(object.loop) ? Boolean(object.loop) : false,
|
|
317
|
-
speed: isSet(object.speed) ? Number(object.speed) : 0,
|
|
318
|
-
idle: isSet(object.idle) ? Boolean(object.idle) : false,
|
|
319
|
-
transitionSeconds: isSet(object.transitionSeconds) ? Number(object.transitionSeconds) : undefined,
|
|
320
|
-
playbackTime: isSet(object.playbackTime) ? Number(object.playbackTime) : undefined,
|
|
321
|
-
sounds: Array.isArray(object?.sounds) ? object.sounds.map((e: any) => String(e)) : [],
|
|
322
|
-
};
|
|
323
|
-
}
|
|
324
|
-
|
|
325
|
-
export function toJSON(message: MovementAnimation): unknown {
|
|
326
|
-
const obj: any = {};
|
|
327
|
-
message.src !== undefined && (obj.src = message.src);
|
|
328
|
-
message.loop !== undefined && (obj.loop = message.loop);
|
|
329
|
-
message.speed !== undefined && (obj.speed = message.speed);
|
|
330
|
-
message.idle !== undefined && (obj.idle = message.idle);
|
|
331
|
-
message.transitionSeconds !== undefined && (obj.transitionSeconds = message.transitionSeconds);
|
|
332
|
-
message.playbackTime !== undefined && (obj.playbackTime = message.playbackTime);
|
|
333
|
-
if (message.sounds) {
|
|
334
|
-
obj.sounds = message.sounds.map((e) => e);
|
|
335
|
-
} else {
|
|
336
|
-
obj.sounds = [];
|
|
337
|
-
}
|
|
338
|
-
return obj;
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
export function create<I extends Exact<DeepPartial<MovementAnimation>, I>>(base?: I): MovementAnimation {
|
|
342
|
-
return MovementAnimation.fromPartial(base ?? {});
|
|
343
|
-
}
|
|
344
|
-
|
|
345
|
-
export function fromPartial<I extends Exact<DeepPartial<MovementAnimation>, I>>(object: I): MovementAnimation {
|
|
346
|
-
const message = createBaseMovementAnimation();
|
|
347
|
-
message.src = object.src ?? "";
|
|
348
|
-
message.loop = object.loop ?? false;
|
|
349
|
-
message.speed = object.speed ?? 0;
|
|
350
|
-
message.idle = object.idle ?? false;
|
|
351
|
-
message.transitionSeconds = object.transitionSeconds ?? undefined;
|
|
352
|
-
message.playbackTime = object.playbackTime ?? undefined;
|
|
353
|
-
message.sounds = object.sounds?.map((e) => e) || [];
|
|
354
|
-
return message;
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
|
|
358
|
-
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
359
|
-
|
|
360
|
-
export type DeepPartial<T> = T extends Builtin ? T
|
|
361
|
-
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
362
|
-
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
363
|
-
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
364
|
-
: Partial<T>;
|
|
365
|
-
|
|
366
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
367
|
-
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
368
|
-
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
369
|
-
|
|
370
|
-
function isSet(value: any): boolean {
|
|
371
|
-
return value !== null && value !== undefined;
|
|
372
|
-
}
|