From 227b3273af8bf935fa078952fb61cf63c76ca882 Mon Sep 17 00:00:00 2001 From: Alejandro Alvarez Melucci <163010988+AlejandroAlvarezMelucciDCL@users.noreply.github.com> Date: Mon, 2 Sep 2024 14:13:35 -0300 Subject: [PATCH] feat: block player movement (#215) * Initial proposed structure for new component PBAvatarFreezeMovement * Added EMOTE value to just block player emotes * Added missing package * Added proto-squad suggested approach to player freeze. Orinal or this one will be deleted after testing and choosing one. * Fixed typo * test adding optional and default value for StandardMovement * removed default value since it's not supported on proto3 * Added disable_jog * Removed avatar_movement_movement component. Renamed player_input_movement component to input_modifier * Removed option to disable camera, that's out of scope of this component --- .../sdk/components/input_modifier.proto | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 proto/decentraland/sdk/components/input_modifier.proto diff --git a/proto/decentraland/sdk/components/input_modifier.proto b/proto/decentraland/sdk/components/input_modifier.proto new file mode 100644 index 00000000..5bd978c6 --- /dev/null +++ b/proto/decentraland/sdk/components/input_modifier.proto @@ -0,0 +1,20 @@ +syntax = "proto3"; +package decentraland.sdk.components; +import "decentraland/sdk/components/common/id.proto"; +option (common.ecs_component_id) = 1078; + +message PBInputModifier { + // when a boolean = false (default) the message is ignored and doesn't consume bandwidth + message StandardInput { + optional bool disable_all = 1; + optional bool disable_walk = 2; + optional bool disable_jog = 3; + optional bool disable_run = 4; + optional bool disable_jump = 5; + optional bool disable_emote = 6; + } + + oneof mode { + StandardInput standard = 1; + } +}