Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 2 additions & 13 deletions proto/decentraland/kernel/apis/restricted_actions.proto
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package decentraland.kernel.apis;

import "decentraland/common/vectors.proto";
import "decentraland/sdk/components/common/avatar_mask.proto";
import "decentraland/sdk/components/common/explorer_ui.proto";

message MovePlayerToRequest {
decentraland.common.Vector3 new_relative_position = 1;
Expand Down Expand Up @@ -65,18 +66,6 @@ message EmptyResponse { }

message StopEmoteRequest { }

// Identifies which fullscreen explorer panel OpenExplorerUi targets.
// EU_SETTINGS holds 0 so an unset `ui` field defaults to the least-intrusive panel.
enum ExplorerUi {
EU_SETTINGS = 0;
EU_MAP = 1;
EU_BACKPACK = 2;
EU_CAMERA_REEL = 3;
EU_COMMUNITIES = 4;
EU_PLACES = 5;
EU_EVENTS = 6;
}

// Verdict of an OpenExplorerUi request (enum rather than a bool so new outcomes stay expressible).
enum OpenExplorerUiResult {
UNSPECIFIED = 0;
Expand All @@ -88,7 +77,7 @@ enum OpenExplorerUiResult {
}

message OpenExplorerUiRequest {
ExplorerUi ui = 1;
decentraland.sdk.components.common.ExplorerUi ui = 1;

// Extension point for future per-panel parameters, as a oneof so each panel gets its
// own optional param message without touching existing fields.
Expand Down
14 changes: 14 additions & 0 deletions proto/decentraland/sdk/components/common/explorer_ui.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
syntax = "proto3";
package decentraland.sdk.components.common;

// Identifies which fullscreen explorer panel OpenExplorerUi targets.
// EU_SETTINGS holds 0 so an unset `ui` field defaults to the least-intrusive panel.
enum ExplorerUi {
EU_SETTINGS = 0;
EU_MAP = 1;
EU_BACKPACK = 2;
EU_CAMERA_REEL = 3;
EU_COMMUNITIES = 4;
EU_PLACES = 5;
EU_EVENTS = 6;
}
31 changes: 31 additions & 0 deletions proto/decentraland/sdk/components/explorer_ui_events_result.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
syntax = "proto3";
package decentraland.sdk.components;

import "decentraland/sdk/components/common/id.proto";
import "decentraland/sdk/components/common/explorer_ui.proto";

option (common.ecs_component_id) = 1220;

// PBExplorerUiEventsResult transports the lifecycle events of fullscreen explorer panels — a panel was
// opened, a panel was closed. It is a grow only value set appended to the scene root entity, so every
// event of a tick is delivered and none overwrites another.
message PBExplorerUiEventsResult {
// Emitted when a fullscreen explorer panel is opened.
message UiOpened {}

// Emitted when a fullscreen explorer panel is closed.
message UiClosed {}

decentraland.sdk.components.common.ExplorerUi ui = 1; // The panel that the event refers to
uint32 timestamp = 2; // The scene tick when the event occurred

// Extension point, deliberately narrow: a variant belongs here only if it is meaningful for every
// value of `ui`, because `ui` and `event` are independent axes and every combination of the two is
// representable. An event that belongs to one panel alone (an item was worn in the backpack, a photo
// was taken in the camera reel) is not added here — it gets its own result component, where the
// component identity carries the panel and no contradictory pair can be expressed at all.
oneof event {
UiOpened opened = 10;
UiClosed closed = 11;
}
}
1 change: 1 addition & 0 deletions public/sdk-components.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import public "decentraland/sdk/components/billboard.proto";
import public "decentraland/sdk/components/camera_mode_area.proto";
import public "decentraland/sdk/components/camera_mode.proto";
import public "decentraland/sdk/components/engine_info.proto";
import public "decentraland/sdk/components/explorer_ui_events_result.proto";
import public "decentraland/sdk/components/gltf_container.proto";
import public "decentraland/sdk/components/gltf_node_modifiers.proto";
import public "decentraland/sdk/components/gltf_container_loading_state.proto";
Expand Down
Loading