diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7b87e34f3..ec8acdee3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,6 +32,8 @@ jobs: - name: install livekit deps run: sudo apt update -y; sudo apt install -y libssl-dev libx11-dev libgl1-mesa-dev libxext-dev - uses: actions/checkout@v2 + with: + submodules: true - uses: actions-rs/cargo@v1 with: command: check @@ -63,6 +65,8 @@ jobs: - name: install livekit deps run: sudo apt update -y; sudo apt install -y libssl-dev libx11-dev libgl1-mesa-dev libxext-dev - uses: actions/checkout@v2 + with: + submodules: true - name: Test Scenes continue-on-error: true run: | @@ -77,6 +81,14 @@ jobs: runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v2 + with: + submodules: true + - name: Set Windows git config + if: runner.os == 'windows' + shell: cmd + run: | + del crates\dcl_component\src\proto + mklink /j crates\dcl_component\src\proto protocol\proto - uses: actions-rs/toolchain@v1 with: profile: minimal @@ -139,6 +151,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + with: + submodules: true - uses: actions-rs/toolchain@v1 with: profile: minimal @@ -164,6 +178,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + with: + submodules: true - uses: actions-rs/toolchain@v1 with: profile: minimal @@ -191,6 +207,7 @@ jobs: - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 with: persist-credentials: false + submodules: true - name: Install taplo run: curl -fsSL https://github.com/tamasfe/taplo/releases/download/0.10.0/taplo-linux-x86_64.gz | gzip -d - | install -m 755 /dev/stdin /usr/local/bin/taplo - name: Run Taplo @@ -216,6 +233,8 @@ jobs: steps: - uses: actions/checkout@v4 + with: + submodules: true - name: Use Node.js uses: actions/setup-node@v4 with: diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index 35e45f62d..2565fafbe 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -14,6 +14,8 @@ jobs: steps: - name: Clone repo uses: actions/checkout@v3 + with: + submodules: true - name: Get current time with underscores uses: 1466587594/get-current-time@v2.1.1 @@ -61,6 +63,8 @@ jobs: steps: - name: Clone repo uses: actions/checkout@v3 + with: + submodules: true - uses: actions-rs/toolchain@v1 with: diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 000000000..ada78a542 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,4 @@ +[submodule "protocol"] + path = protocol + url = https://github.com/decentraland/protocol + branch = protocol-squad diff --git a/crates/comms/src/broadcast_position.rs b/crates/comms/src/broadcast_position.rs index d9cd400af..a2bbf9db6 100644 --- a/crates/comms/src/broadcast_position.rs +++ b/crates/comms/src/broadcast_position.rs @@ -123,6 +123,9 @@ fn broadcast_position( is_long_fall: movement_compressed.temporal.long_falling(), is_falling: movement_compressed.temporal.falling(), is_stunned: movement_compressed.temporal.stunned(), + is_instant: Default::default(), + // TODO + // is_instant: movement_compressed.temporal.instant(), is_emoting: dynamics.move_kind == MoveKind::Emote, }; diff --git a/crates/dcl_component/build.rs b/crates/dcl_component/build.rs index b03c4dccf..3c80af739 100644 --- a/crates/dcl_component/build.rs +++ b/crates/dcl_component/build.rs @@ -74,7 +74,7 @@ fn gen_sdk_components() -> Result<()> { sources.push("src/proto/decentraland/kernel/comms/rfc5/ws_comms.proto".into()); sources.push("src/proto/decentraland/kernel/comms/rfc4/comms.proto".into()); sources.push("src/proto/decentraland/kernel/comms/v3/archipelago.proto".into()); - sources.push("src/proto/decentraland/social/friendships/friendships.proto".into()); + sources.push("src/proto/decentraland/social_service/v1/social_service_v1.proto".into()); let mut config = prost_build::Config::new(); config.type_attribute( @@ -133,7 +133,7 @@ fn gen_social_service() -> Result<()> { conf.service_generator(Box::new(dcl_rpc::codegen::RPCServiceGenerator::new())); conf.type_attribute("*", "#[derive(Debug)]"); conf.compile_protos( - &["src/proto/decentraland/social/friendships/friendships.proto"], + &["src/proto/decentraland/social_service/v1/social_service_v1.proto"], &["src/proto"], )?; Ok(()) diff --git a/crates/dcl_component/src/proto b/crates/dcl_component/src/proto new file mode 120000 index 000000000..f2bf7e016 --- /dev/null +++ b/crates/dcl_component/src/proto @@ -0,0 +1 @@ +../../../protocol/proto \ No newline at end of file diff --git a/crates/dcl_component/src/proto/buf.yaml b/crates/dcl_component/src/proto/buf.yaml deleted file mode 100644 index 9adade37b..000000000 --- a/crates/dcl_component/src/proto/buf.yaml +++ /dev/null @@ -1,47 +0,0 @@ -version: v1 -breaking: - use: - - WIRE_JSON - ignore: - - google -lint: - use: - - DIRECTORY_SAME_PACKAGE - - PACKAGE_DEFINED - - PACKAGE_DIRECTORY_MATCH - - PACKAGE_SAME_DIRECTORY - - ENUM_PASCAL_CASE - - ENUM_VALUE_UPPER_SNAKE_CASE - - FIELD_LOWER_SNAKE_CASE - - MESSAGE_PASCAL_CASE - - ONEOF_LOWER_SNAKE_CASE - - PACKAGE_LOWER_SNAKE_CASE - - RPC_PASCAL_CASE - - SERVICE_PASCAL_CASE - - PACKAGE_SAME_CSHARP_NAMESPACE - - PACKAGE_SAME_GO_PACKAGE - - PACKAGE_SAME_JAVA_MULTIPLE_FILES - - PACKAGE_SAME_JAVA_PACKAGE - - PACKAGE_SAME_PHP_NAMESPACE - - PACKAGE_SAME_RUBY_PACKAGE - - PACKAGE_SAME_SWIFT_PREFIX - - ENUM_FIRST_VALUE_ZERO - - ENUM_NO_ALLOW_ALIAS - - IMPORT_NO_WEAK - - IMPORT_NO_PUBLIC - - IMPORT_USED - - FILE_LOWER_SNAKE_CASE - # Ignored:the default value is used - # - ENUM_ZERO_VALUE_SUFFIX - # Ignored: if a prefix is needed in the target language, implement a preprocessor - # - ENUM_VALUE_PREFIX - # Not wished - # - PACKAGE_VERSION_SUFFIX - # TODO: See if this needs to be added - # - RPC_REQUEST_RESPONSE_UNIQUE - # - RPC_REQUEST_STANDARD_NAME - # - RPC_RESPONSE_STANDARD_NAME - # - SERVICE_SUFFIX - ignore: - - google - - decentraland/renderer/engine_interface.proto \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/common/border_rect.proto b/crates/dcl_component/src/proto/decentraland/common/border_rect.proto deleted file mode 100644 index 14260d5de..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/border_rect.proto +++ /dev/null @@ -1,18 +0,0 @@ -syntax = "proto3"; -package decentraland.common; - -// Defines indents from respective edges -message BorderRect { - float top = 1; - float left = 2; - float right = 3; - float bottom = 4; -} - -// Defines a rect with x, y, width and height -message Rect { - float x = 1; - float y = 2; - float width = 3; - float height = 4; -} diff --git a/crates/dcl_component/src/proto/decentraland/common/colors.proto b/crates/dcl_component/src/proto/decentraland/common/colors.proto deleted file mode 100644 index ed69b5ae1..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/colors.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package decentraland.common; - -message Color3 { - float r = 1; - float g = 2; - float b = 3; -} - -message Color4 { - float r = 1; - float g = 2; - float b = 3; - float a = 4; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/common/content_mapping.proto b/crates/dcl_component/src/proto/decentraland/common/content_mapping.proto deleted file mode 100644 index bcca44783..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/content_mapping.proto +++ /dev/null @@ -1,7 +0,0 @@ -syntax = "proto3"; -package decentraland.common; - -message ContentMapping { - string file = 1; - string hash = 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/common/entity.proto b/crates/dcl_component/src/proto/decentraland/common/entity.proto deleted file mode 100644 index 4a6a1463e..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/entity.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package decentraland.common; -import "decentraland/common/content_mapping.proto"; - -// Entity schema compliant with https://rfc.decentraland.org/adr/ADR-80 - -message Entity { - string id = 1; - repeated string pointers = 2; - string metadata = 3; - uint32 timestamp = 4; - repeated ContentMapping content = 5; -} diff --git a/crates/dcl_component/src/proto/decentraland/common/sdk/user_data.proto b/crates/dcl_component/src/proto/decentraland/common/sdk/user_data.proto deleted file mode 100644 index c67daa15d..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/sdk/user_data.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package decentraland.common.sdk; - -message Snapshots { - string face256 = 1; - string body = 2; -} - -message AvatarForUserData { - string body_shape = 1; - string skin_color = 2; - string hair_color = 3; - string eye_color = 4; - repeated string wearables = 5; - Snapshots snapshots = 6; -} - -message UserData { - string display_name = 1; - optional string public_key = 2; - bool has_connected_web3 = 3; - string user_id = 4; - int32 version = 5; - AvatarForUserData avatar = 6; -} diff --git a/crates/dcl_component/src/proto/decentraland/common/texture.proto b/crates/dcl_component/src/proto/decentraland/common/texture.proto deleted file mode 100644 index a667355f6..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/texture.proto +++ /dev/null @@ -1,52 +0,0 @@ -syntax = "proto3"; -package decentraland.common; -import "decentraland/common/vectors.proto"; - -enum TextureWrapMode { - TWM_REPEAT = 0; - TWM_CLAMP = 1; - TWM_MIRROR = 2; -} - -enum TextureFilterMode { - TFM_POINT = 0; - TFM_BILINEAR = 1; - TFM_TRILINEAR = 2; -} - -message Texture { - string src = 1; - optional TextureWrapMode wrap_mode = 2; // default = TextureWrapMode.Clamp - optional TextureFilterMode filter_mode = 3; // default = FilterMode.Bilinear - - // Final uv = offset + (input_uv * tiling) - optional Vector2 offset = 4; // default = Vector2.Zero; Offset for texture positioning, only works for the texture property in PbrMaterial or UnlitMaterial. - optional Vector2 tiling = 5; // default = Vector2.One; Tiling multiplier for texture repetition, only works for the texture property in PbrMaterial or UnlitMaterial. -} - -message AvatarTexture { - string user_id = 1; - optional TextureWrapMode wrap_mode = 2; // default = TextureWrapMode.Clamp - optional TextureFilterMode filter_mode = 3; // default = FilterMode.Bilinear -} - -message VideoTexture { - uint32 video_player_entity = 1; - optional TextureWrapMode wrap_mode = 2; // default = TextureWrapMode.Clamp - optional TextureFilterMode filter_mode = 3; // default = FilterMode.Bilinear -} - -message UiCanvasTexture { - uint32 ui_canvas_entity = 1; - optional TextureWrapMode wrap_mode = 2; // default = TextureWrapMode.Clamp - optional TextureFilterMode filter_mode = 3; // default = FilterMode.Bilinear -} - -message TextureUnion { - oneof tex { - Texture texture = 1; // default = null - AvatarTexture avatar_texture = 2; // default = null - VideoTexture video_texture = 3; // default = null - UiCanvasTexture ui_texture = 4; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/common/vectors.proto b/crates/dcl_component/src/proto/decentraland/common/vectors.proto deleted file mode 100644 index 27b19e070..000000000 --- a/crates/dcl_component/src/proto/decentraland/common/vectors.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; -package decentraland.common; - -message Position { - float x = 1; - float y = 2; - float z = 3; -} - -message Vector3 { - float x = 1; - float y = 2; - float z = 3; -} - -message Vector2 { - float x = 1; - float y = 2; -} - -message Quaternion { - float x = 1; - float y = 2; - float z = 3; - float w = 4; -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/comms_api.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/comms_api.proto deleted file mode 100644 index 4288fe71a..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/comms_api.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -enum VideoTrackSourceType { - VTST_UNKNOWN = 0; - VTST_CAMERA = 1; - VTST_SCREEN_SHARE = 2; -} - -message VideoTracksActiveStreamsRequest { -} - -message VideoTracksActiveStreamsResponse { - repeated VideoTracksActiveStreamsData streams = 1; -} - -message VideoTracksActiveStreamsData { - string identity = 1; - string track_sid = 2; - VideoTrackSourceType source_type = 3; -} - -service CommsApiService { - rpc GetActiveVideoStreams(VideoTracksActiveStreamsRequest) returns (VideoTracksActiveStreamsResponse) {} -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/communications_controller.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/communications_controller.proto deleted file mode 100644 index ee2f3722a..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/communications_controller.proto +++ /dev/null @@ -1,23 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message RealSendRequest { - string message = 1; -} - -message RealSendResponse {} - -message SendBinaryRequest { - repeated bytes data = 1; -} - -message SendBinaryResponse { - repeated bytes data = 1; -} - -service CommunicationsControllerService { - // @deprecated - This API should use a bidirectional binary stream in sdk7 - // https://github.com/decentraland/sdk/issues/582 - rpc Send(RealSendRequest) returns (RealSendResponse) {} - rpc SendBinary(SendBinaryRequest) returns (SendBinaryResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/dev_tools.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/dev_tools.proto deleted file mode 100644 index 5aa66e1e5..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/dev_tools.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message DevToolsBody { - string type = 1; - string json_payload = 2; -} - -message EventResponse {} - -// @deprecated -service DevToolsService { - // @deprecated - rpc Event(DevToolsBody) returns (EventResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/engine_api.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/engine_api.proto deleted file mode 100644 index d5207f983..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/engine_api.proto +++ /dev/null @@ -1,118 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.apis; - -import "decentraland/sdk/ecs6/engine_interface_ecs6.proto"; - -message ManyEntityAction { - repeated decentraland.sdk.ecs6.EntityAction actions = 1; -} - -message SendBatchResponse { - repeated EventData events = 1; -} - -message UnsubscribeRequest { - string event_id = 1; -} -message SubscribeRequest { - string event_id = 1; -} -message SubscribeResponse {} -message UnsubscribeResponse {} - -// Events -enum EventDataType { - EDT_GENERIC = 0; - EDT_POSITION_CHANGED = 1; - EDT_ROTATION_CHANGED = 2; -} - -message GenericPayload { - string event_id = 3; - string event_data = 4; -} - -message ReadOnlyVector3 { - float x = 1; - float y = 2; - float z = 3; -} - -message ReadOnlyQuaternion { - float x = 1; - float y = 2; - float z = 3; - float w = 4; -} - -message PositionChangedPayload { - ReadOnlyVector3 position = 1; - ReadOnlyVector3 camera_position = 2; - float player_height = 3; -} - -message RotationChangedPayload { - ReadOnlyVector3 rotation = 1; - ReadOnlyQuaternion quaternion = 2; -} - -message EventData { - EventDataType type = 1; - optional GenericPayload generic = 2; - optional PositionChangedPayload position_changed = 3; - optional RotationChangedPayload rotation_changed = 4; -} - -message CrdtSendToRendererRequest { - bytes data = 1; -} - -message CrdtSendToResponse { - // list of CRDT messages coming back from the renderer - repeated bytes data = 1; -} - -message CrdtGetStateRequest {} -message CrdtGetStateResponse { - // returns true if the returned state has scene-created entities - bool has_entities = 1; - // static entities data (root entity, camera, etc) and scene-created entities - repeated bytes data = 2; -} - -// deprecated -message CrdtMessageFromRendererRequest {} -// deprecated -message CrdtMessageFromRendererResponse { - repeated bytes data = 1; -} - -message IsServerRequest {} -message IsServerResponse { - bool is_server = 1; -} - -service EngineApiService { - // support for legacy SDK events. - - // @deprecated - rpc SendBatch(ManyEntityAction) returns (SendBatchResponse) {} - // @deprecated - rpc Subscribe(SubscribeRequest) returns (SubscribeResponse) {} - // @deprecated - rpc Unsubscribe(UnsubscribeRequest) returns (UnsubscribeResponse) {} - - // send information of the CRDT messages to the renderer. It returns the CRDT changes back from the renderer - // like raycast responses or the player's position - rpc CrdtSendToRenderer(CrdtSendToRendererRequest) returns (CrdtSendToResponse) {} - - // retrieves the current _full_ state of the entities from the renderer. This function is used to hidrate - // the state of the scenes when the code of the worker is stopped/resumed - rpc CrdtGetState(CrdtSendToRendererRequest) returns (CrdtGetStateResponse) {} - - // @deprecated, this response was merged into CrdtSendToResponse - rpc CrdtGetMessageFromRenderer(CrdtMessageFromRendererRequest) returns (CrdtMessageFromRendererResponse) {} - - rpc IsServer(IsServerRequest) returns (IsServerResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/environment_api.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/environment_api.proto deleted file mode 100644 index 2e5006cd0..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/environment_api.proto +++ /dev/null @@ -1,76 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.apis; - -import "decentraland/common/content_mapping.proto"; - -message MinimalRunnableEntity { - repeated decentraland.common.ContentMapping content = 1; - string metadata_json = 2; -} - -message BootstrapDataResponse { - string id = 1; - string base_url = 4; - MinimalRunnableEntity entity = 2; - bool use_f_p_s_throttling = 5; -} - -message PreviewModeResponse { - bool is_preview = 1; -} - -message AreUnsafeRequestAllowedResponse { - bool status = 1; -} - -message GetPlatformResponse { - string platform = 1; -} - -message EnvironmentRealm { - string domain = 1; - string layer = 2; - string room = 3; - string server_name = 4; - string display_name = 5; - string protocol = 6; -} - -message GetCurrentRealmResponse { - optional EnvironmentRealm current_realm = 1; -} - -message GetExplorerConfigurationResponse { - string client_uri = 1; - map configurations = 2; -} - -message GetDecentralandTimeResponse { - int32 seconds = 1; -} - -message GetBootstrapDataRequest {} -message IsPreviewModeRequest {} -message GetPlatformRequest {} -message AreUnsafeRequestAllowedRequest {} -message GetCurrentRealmRequest {} -message GetExplorerConfigurationRequest {} -message GetDecentralandTimeRequest {} - -service EnvironmentApiService { - // @deprecated, only available for SDK6 compatibility. Use runtime_api instead - rpc GetBootstrapData(GetBootstrapDataRequest) returns (BootstrapDataResponse) {} - // @deprecated, only available for SDK6 compatibility. Needs migration - rpc IsPreviewMode(IsPreviewModeRequest) returns (PreviewModeResponse) {} - // @deprecated, only available for SDK6 compatibility - rpc GetPlatform(GetPlatformRequest) returns (GetPlatformResponse) {} - // @deprecated, only available for SDK6 compatibility - rpc AreUnsafeRequestAllowed(AreUnsafeRequestAllowedRequest) returns (AreUnsafeRequestAllowedResponse) {} - // @deprecated, use GetCurrentRealm from runtime_api instead - rpc GetCurrentRealm(GetCurrentRealmRequest) returns (GetCurrentRealmResponse) {} - // @deprecated, only available for SDK6 compatibility - rpc GetExplorerConfiguration(GetExplorerConfigurationRequest) returns (GetExplorerConfigurationResponse) {} - // @deprecated, use GetTime from runtime_api instead - rpc GetDecentralandTime(GetDecentralandTimeRequest) returns (GetDecentralandTimeResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/ethereum_controller.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/ethereum_controller.proto deleted file mode 100644 index 2534cb8c8..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/ethereum_controller.proto +++ /dev/null @@ -1,64 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message RequirePaymentRequest { - string to_address = 1; - float amount = 2; - string currency = 3; -} - -message RequirePaymentResponse { - string json_any_response = 1; -} - -message SignMessageRequest { - map message = 1; -} - -message SignMessageResponse { - string message = 1; - string hex_encoded_message = 2; - string signature = 3; -} - -message ConvertMessageToObjectRequest { - string message = 1; -} - -message ConvertMessageToObjectResponse { - map dict = 1; -} - -message SendAsyncRequest { - int32 id = 1; - string method = 2; - string json_params = 3; -} - -message SendAsyncResponse { - string json_any_response = 1; -} - -message GetUserAccountRequest {} - -message GetUserAccountResponse { - optional string address = 1; -} - -service EthereumControllerService { - // @deprecated, only available for SDK6 compatibility. This was a low level API that can - // be replaced by any ethereum library on top of the provider - rpc RequirePayment(RequirePaymentRequest) returns (RequirePaymentResponse) {} - // @deprecated, only available for SDK6 compatibility. This was a low level API that can - // be replaced by any ethereum library on top of the provider - rpc SignMessage(SignMessageRequest) returns (SignMessageResponse) {} - // @deprecated, only available for SDK6 compatibility. This was a low level API that can - // be replaced by any ethereum library on top of the provider - rpc ConvertMessageToObject(ConvertMessageToObjectRequest) returns (ConvertMessageToObjectResponse) {} - - rpc SendAsync(SendAsyncRequest) returns (SendAsyncResponse) {} - - // @deprecated, only available for SDK6 compatibility. This was a low level API that can - // be replaced by any ethereum library on top of the provider - rpc GetUserAccount(GetUserAccountRequest) returns (GetUserAccountResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/parcel_identity.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/parcel_identity.proto deleted file mode 100644 index 6c1ba8f92..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/parcel_identity.proto +++ /dev/null @@ -1,43 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/content_mapping.proto"; - -message MappingsResponse { - string parcel_id = 1; - string root_cid = 2; - repeated decentraland.common.ContentMapping contents = 3; -} - -message Land { - string scene_id = 1; - string scene_json_data = 2; - string base_url = 3; - string base_url_bundles = 4; - MappingsResponse mappings_response = 5; -} - -message GetParcelRequest {} -message GetParcelResponse { - Land land = 1; - string cid = 2; -} - -message GetSceneIdRequest {} -message GetSceneIdResponse { - string scene_id = 1; -} - -message GetIsEmptyRequest {} -message GetIsEmptyResponse { - bool is_empty = 1; -} - -service ParcelIdentityService { - // @deprecated, only available for SDK6 compatibility - rpc GetParcel(GetParcelRequest) returns (GetParcelResponse) {} - // @deprecated, only available for SDK6 compatibility - rpc GetSceneId(GetSceneIdRequest) returns (GetSceneIdResponse) {} - // @deprecated, only available for SDK6 compatibility - rpc GetIsEmpty(GetIsEmptyRequest) returns (GetIsEmptyResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/permissions.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/permissions.proto deleted file mode 100644 index 41d5875d0..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/permissions.proto +++ /dev/null @@ -1,36 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.apis; - -enum PermissionItem { - PI_ALLOW_TO_MOVE_PLAYER_INSIDE_SCENE = 0; - PI_ALLOW_TO_TRIGGER_AVATAR_EMOTE = 1; - PI_USE_WEB3_API = 2; - PI_USE_WEBSOCKET = 3; - PI_USE_FETCH = 4; - PI_ALLOW_MEDIA_HOSTNAMES = 5; - PI_OPEN_EXTERNAL_LINK = 6; -} - -message PermissionResponse { - bool has_permission = 1; -} - -message HasPermissionRequest { - PermissionItem permission = 1; -} - -message HasManyPermissionRequest { - repeated PermissionItem permissions = 1; -} - -message HasManyPermissionResponse { - repeated bool has_many_permission = 1; -} - -service PermissionsService { - // @deprecated, only available for SDK6 compatibility - rpc HasPermission(HasPermissionRequest) returns (PermissionResponse) {} - // @deprecated, only available for SDK6 compatibility - rpc HasManyPermissions(HasManyPermissionRequest) returns (HasManyPermissionResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/players.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/players.proto deleted file mode 100644 index 05aeadcef..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/players.proto +++ /dev/null @@ -1,35 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/sdk/user_data.proto"; - -message Player { - string user_id = 1; -} - -message PlayersGetUserDataResponse { - optional decentraland.common.sdk.UserData data = 1; -} - -message PlayerListResponse { - repeated Player players = 1; -} - -message GetPlayerDataRequest { - string user_id = 1; -} - -message GetPlayersInSceneRequest {} -message GetConnectedPlayersRequest {} - -service PlayersService { - // Returns data about a specific player, by id - // NOTE: To be deprecated after implementing foreign-entities and once the avatar scene uses SDK7 - rpc GetPlayerData(GetPlayerDataRequest) returns (PlayersGetUserDataResponse) {} - // Returns a list of all the ids of players who are currently standing within the parcels of the scene - // NOTE: To be deprecated after implementing foreign-entities and once the avatar scene uses SDK7 - rpc GetPlayersInScene(GetPlayersInSceneRequest) returns (PlayerListResponse) {} - // Returns a list of all the ids of players who are currently connected to the same server and grouped together - // NOTE: To be deprecated after implementing foreign-entities and once the avatar scene uses SDK7 - rpc GetConnectedPlayers(GetConnectedPlayersRequest) returns (PlayerListResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/portable_experiences.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/portable_experiences.proto deleted file mode 100644 index fe2c03ad1..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/portable_experiences.proto +++ /dev/null @@ -1,55 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message KillRequest { - string pid = 1; -} - -message KillResponse { - bool status = 1; -} - -message SpawnRequest { - optional string pid = 1; - optional string ens = 2; -} - -message SpawnResponse { - string pid = 1; - string parent_cid = 2; - string name = 3; - optional string ens = 4; -} - -message PxRequest { - string pid = 1; -} - -message GetPortableExperiencesLoadedRequest {} - -message GetPortableExperiencesLoadedResponse { - repeated SpawnResponse loaded = 1; -} - -message ExitRequest {} -message ExitResponse { - bool status = 1; -} - -service PortableExperiencesService { - // Spawns a new portable experience that is detached from the current scene. - // Spawned portable experiences can only be controlled by 1) the user (from the UI) - // and 2) from the parent scene. If the parent scene gets unloaded i.e. by distance, - // once the player re-loads the parent it will inherit the children portable experiences - // to gain control over them. - rpc Spawn(SpawnRequest) returns (SpawnResponse) {} - // Kill a child portable experience, this method only works if the child was - // spawned by the same process trying to kill it. - rpc Kill(KillRequest) returns (KillResponse) {} - // Kill the current scene if the current scene is a portable experience. Other - // kind of scenes are not allowed to finish their programs like portable experiences. - rpc Exit(ExitRequest) returns (ExitResponse) {} - // Gets a list of running portable experiences for the current user. Be mindful - // about the performance penalty of calling this function all frames. - rpc GetPortableExperiencesLoaded(GetPortableExperiencesLoadedRequest) returns (GetPortableExperiencesLoadedResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/restricted_actions.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/restricted_actions.proto deleted file mode 100644 index b299fc41f..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/restricted_actions.proto +++ /dev/null @@ -1,78 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/vectors.proto"; - -message MovePlayerToRequest { - decentraland.common.Vector3 new_relative_position = 1; - optional decentraland.common.Vector3 camera_target = 2; -} - -message TeleportToRequest { - decentraland.common.Vector2 world_coordinates = 1; -} - -message TriggerEmoteRequest { - string predefined_emote = 1; -} - -message ChangeRealmRequest { - string realm = 1; - optional string message = 2; -} - -message OpenExternalUrlRequest { - string url = 1; -} - -message OpenNftDialogRequest { - string urn = 1; -} - -message UnblockPointerRequest {} - -message CommsAdapterRequest { - string connection_string = 1; -} - -message TriggerSceneEmoteRequest { - string src = 1; - optional bool loop = 2; -} - -message SuccessResponse { - bool success = 1; -} - -message TriggerEmoteResponse { } - -message MovePlayerToResponse { } - -message TeleportToResponse { } - -service RestrictedActionsService { - // MovePlayerTo will move the player in a position relative to the current scene - rpc MovePlayerTo(MovePlayerToRequest) returns (MovePlayerToResponse) {} - - // TeleportTo will move the user to the specified world LAND parcel coordinates - rpc TeleportTo(TeleportToRequest) returns (TeleportToResponse) {} - - // TriggerEmote will trigger an emote in this current user - rpc TriggerEmote(TriggerEmoteRequest) returns (TriggerEmoteResponse) {} - - // ChangeRealm prompts the user to change to a specific realm - rpc ChangeRealm(ChangeRealmRequest) returns (SuccessResponse) {} - - // OpenExternalUrl prompts the user to open an external link - rpc OpenExternalUrl(OpenExternalUrlRequest) returns (SuccessResponse) {} - - // OpenNftDialog opens an NFT dialog. - rpc OpenNftDialog(OpenNftDialogRequest) returns (SuccessResponse) {} - - // Asks the explorer to connect to other communications adapter, this feature - // can be used to join private game servers - rpc SetCommunicationsAdapter(CommsAdapterRequest) returns (SuccessResponse) {} - - // TriggerSceneEmote will trigger an scene emote file in this current user - rpc TriggerSceneEmote(TriggerSceneEmoteRequest) returns (SuccessResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/runtime.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/runtime.proto deleted file mode 100644 index 52215207d..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/runtime.proto +++ /dev/null @@ -1,71 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/content_mapping.proto"; -import "decentraland/sdk/components/realm_info.proto"; - -// This API will contain all the information related to the world runtime. -// Things related to the user, players or the scene itself has they own api, and -// won't live here. (UserIdentity, Players, ParcelIdentity) - -message GetRealmResponse { - optional decentraland.sdk.components.PBRealmInfo realm_info = 1; -} - -message GetWorldTimeResponse { - int32 seconds = 1; -} - -message GetRealmRequest {} -message GetWorldTimeRequest {} - -message ReadFileRequest { - // name of the deployed file - string file_name = 1; -} -message ReadFileResponse { - // contents of the file - bytes content = 1; - // deployed hash/CID - string hash = 2; -} - -message CurrentSceneEntityRequest {} -message CurrentSceneEntityResponse { - // this is either the entityId or the full URN of the scene that is running - string urn = 1; - // contents of the deployed entities - repeated decentraland.common.ContentMapping content = 2; - // JSON serialization of the entity.metadata field - string metadata_json = 3; - // baseUrl used to resolve all content files - string base_url = 4; -} - -message GetExplorerInformationRequest {} -message GetExplorerInformationResponse { - // the agent that current explorer is identified as - string agent = 1; - // options: "desktop", "mobile", "vr", "web" - string platform = 2; - // custom configurations set in the explorer - map configurations = 3; -} - -service RuntimeService { - // Provides information about the current realm - rpc GetRealm(GetRealmRequest) returns (GetRealmResponse) {} - // Provides information about the Decentraland Time, which is coordinated - // across players. - rpc GetWorldTime(GetWorldTimeRequest) returns (GetWorldTimeResponse) {} - // Returns the file content of a deployed asset. If the file doesn't - // exist or cannot be retrieved, the RPC call throws an error. - // This method is called to load any assets deployed among the scene, - // runtime may cache this response much more than the provided "fetch" function. - rpc ReadFile(ReadFileRequest) returns (ReadFileResponse) {} - // Returns information about the current scene. This is the replacement of GetBootstrapData - rpc GetSceneInformation(CurrentSceneEntityRequest) returns (CurrentSceneEntityResponse) {} - - // Provides information about the explorer - rpc GetExplorerInformation(GetExplorerInformationRequest) returns (GetExplorerInformationResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/scene.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/scene.proto deleted file mode 100644 index ede250eb9..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/scene.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/content_mapping.proto"; - -message GetSceneRequest {} -message GetSceneResponse { - string cid = 1; - string metadata = 2; - string base_url = 3; - repeated decentraland.common.ContentMapping contents = 4; -} - -service SceneService { - rpc GetSceneInfo(GetSceneRequest) returns (GetSceneResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/signed_fetch.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/signed_fetch.proto deleted file mode 100644 index b9c516963..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/signed_fetch.proto +++ /dev/null @@ -1,33 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message FlatFetchInit { - optional string method = 1; - optional string body = 2; - map headers = 3; -} - -message FlatFetchResponse { - bool ok = 1; - int32 status = 2; - string status_text = 3; - map headers = 4; - string body = 5; -} - -message SignedFetchRequest { - string url = 1; - optional FlatFetchInit init = 2; -} - -message GetHeadersResponse { - map headers = 1; -} - -service SignedFetchService { - // SignedFetch is used to authenticate JSON requests in name of the users, - // a special scoped signature is generated following the https://adr.decentraland.org/adr/ADR-44 - rpc SignedFetch(SignedFetchRequest) returns (FlatFetchResponse) {} - - rpc GetHeaders(SignedFetchRequest) returns (GetHeadersResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/social_controller.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/social_controller.proto deleted file mode 100644 index c9d331326..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/social_controller.proto +++ /dev/null @@ -1,19 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message InitRequest {} -message SocialEvent { - string event = 1; - string payload = 2; -} - -message GetAvatarEventsResponse { - repeated SocialEvent events = 1; -} - -service SocialControllerService { - // @deprecated, only available for SDK6 compatibility. This was a low level - // API used for the AvatarScene, it will be replaced by Foreign Entities in - // SDK7 - rpc PullAvatarEvents(InitRequest) returns (GetAvatarEventsResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/testing.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/testing.proto deleted file mode 100644 index 35829dc4d..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/testing.proto +++ /dev/null @@ -1,100 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/vectors.proto"; - -service TestingService { - // sends a test result to the test runner - rpc LogTestResult(TestResult) returns (TestResultResponse) {} - // send a list of all planned tests to the test runner - rpc Plan(TestPlan) returns (TestPlanResponse) {} - // sets the camera position and rotation in the engine - rpc SetCameraTransform (SetCameraTransformTestCommand) returns (SetCameraTransformTestCommandResponse) {} - // @internal - // take a screenshot and compare it with a stored one - // it hides the explorer hud and ui, primary player and players of avatar scenes - rpc TakeAndCompareScreenshot (TakeAndCompareScreenshotRequest) returns (TakeAndCompareScreenshotResponse) {} -} - -message TakeAndCompareScreenshotRequest { - // the source path in the scene where the screenshot is stored, - // the snapshot taken is compared with the stored one - string src_stored_snapshot = 1; - // the camera position where is set before and while taking the screenshot, relative to base scene - decentraland.common.Vector3 camera_position = 2; - // the camera position where is target to before and while taking the screenshot, relative to base scene - decentraland.common.Vector3 camera_target = 3; - // width x height screenshot size - decentraland.common.Vector2 screenshot_size = 4; - // comparison method choice and parameters values - oneof comparison_method { - ComparisonMethodGreyPixelDiff grey_pixel_diff = 5; - } - - message ComparisonMethodGreyPixelDiff {} - - enum SnapshotMode { - // only visible 3d scene and ui scene - SM_3D_AND_UI = 0; - // only visible 3d scene - SM_3D_ONLY = 1; - // only visible ui scene - SM_UI_ONLY = 2; - }; - SnapshotMode snapshot_mode = 6; -} - - -message TakeAndCompareScreenshotResponse { - bool stored_snapshot_found = 1; - oneof comparison_method_result { - ComparisonMethodGreyPixelDiffResult grey_pixel_diff = 2; - } - - message ComparisonMethodGreyPixelDiffResult { - float similarity = 1; - } -} - -message TestResult { - string name = 1; - bool ok = 2; - optional string error = 3; - optional string stack = 4; - - // how many ADR-148 ticks were spent running this test - uint32 total_frames = 5; - - // total time in seconds spent running this test - float total_time = 6; -} -message TestResultResponse {} - -message TestPlan { - message TestPlanEntry { - string name = 1; - } - - repeated TestPlanEntry tests = 1; -} -message TestPlanResponse {} - -message SetCameraTransformTestCommand { - Vector3 position = 1; - Quaternion rotation = 2; - - message Vector3 { - float x = 1; - float y = 2; - float z = 3; - } - - message Quaternion { - float x = 1; - float y = 2; - float z = 3; - float w = 4; - } -} -message SetCameraTransformTestCommandResponse {} - diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/user_action_module.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/user_action_module.proto deleted file mode 100644 index 35af6386e..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/user_action_module.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -message RequestTeleportRequest { - string destination = 1; -} - -message RequestTeleportResponse {} - -service UserActionModuleService { - // @deprecated, only available for SDK6 compatibility. Use RestrictedActions/TeleportTo - rpc RequestTeleport(RequestTeleportRequest) returns (RequestTeleportResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/apis/user_identity.proto b/crates/dcl_component/src/proto/decentraland/kernel/apis/user_identity.proto deleted file mode 100644 index 7278a2d67..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/apis/user_identity.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package decentraland.kernel.apis; - -import "decentraland/common/sdk/user_data.proto"; - -message GetUserDataRequest {} - -message GetUserDataResponse { - optional decentraland.common.sdk.UserData data = 1; -} - -message GetUserPublicKeyRequest {} - -message GetUserPublicKeyResponse { - optional string address = 1; -} - -service UserIdentityService { - // @deprecated, only available for SDK6 compatibility. UseGetUserData - rpc GetUserPublicKey(GetUserPublicKeyRequest) returns (GetUserPublicKeyResponse) {} - rpc GetUserData(GetUserDataRequest) returns (GetUserDataResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/rfc4/comms.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/rfc4/comms.proto deleted file mode 100644 index 81556443d..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/rfc4/comms.proto +++ /dev/null @@ -1,120 +0,0 @@ -// This file maps to the definition in https://rfc.decentraland.org/rfc/RFC-4 -// It is mandatory to also update that RFC when modifying this file - -syntax = "proto3"; - -package decentraland.kernel.comms.rfc4; - -message Packet { - oneof message { - Position position = 1; - AnnounceProfileVersion profile_version = 2; - ProfileRequest profile_request = 3; - ProfileResponse profile_response = 4; - Chat chat = 5; - Scene scene = 6; - Voice voice = 7; - Movement movement = 8; - PlayerEmote player_emote = 9; - SceneEmote scene_emote = 10; - MovementCompressed movement_compressed = 12; - } - uint32 protocol_version = 11; -} - -message Position { - // command number - uint32 index = 1; - // world position - float position_x = 3; - float position_y = 4; - float position_z = 5; - // quaternion - float rotation_x = 6; - float rotation_y = 7; - float rotation_z = 8; - float rotation_w = 9; -} - -message Movement { - // command number - float timestamp = 1; - // world position - float position_x = 2; - float position_y = 3; - float position_z = 4; - // velocity - float velocity_x = 5; - float velocity_y = 6; - float velocity_z = 7; - // animations - float movement_blend_value = 8; - float slide_blend_value = 9; - bool is_grounded = 10; - bool is_jumping = 11; - bool is_long_jump = 12; - bool is_long_fall = 13; - bool is_falling = 14; - - bool is_stunned = 15; - - float rotation_y = 16; - bool is_emoting = 18; -} - -message MovementCompressed { - int32 temporal_data = 1; // bit-compressed: timestamp + animations - int64 movement_data = 2; // bit-compressed: position + velocity -} - -message PlayerEmote { - uint32 incremental_id = 1; - string urn = 2; - float timestamp = 3; -} - -message SceneEmote { - string scene_entity_id = 1; - string source = 2; -} - -message AnnounceProfileVersion { - uint32 profile_version = 1; - - // Extension: optional download_url to fetch the profile from a profile service - // optional string download_url = 2; -} - -message ProfileRequest { - string address = 4; - uint32 profile_version = 3; -} - -message ProfileResponse { - string serialized_profile = 1; - string base_url = 2; - - // Extension: when Lambdas serializes profiles for the RPC, we could extend - // this format to prevent transmitting the serialized JSON and leverage protobuf - // directly - // Profile profile = 2; -} - -message Chat { - string message = 1; - double timestamp = 2; -} - -message Scene { - string scene_id = 1; - bytes data = 2; -} - -message Voice { - bytes encoded_samples = 1; - uint32 index = 2; - VoiceCodec codec = 3; - enum VoiceCodec { - VC_OPUS = 0; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/rfc5/ws_comms.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/rfc5/ws_comms.proto deleted file mode 100644 index ba928b84e..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/rfc5/ws_comms.proto +++ /dev/null @@ -1,104 +0,0 @@ -// This file maps to the definition in https://rfc.decentraland.org/rfc/RFC-5 -// It is mandatory to also update that RFC when modifying this file - -syntax = "proto3"; - -package decentraland.kernel.comms.rfc5; - -/** - * Sent to the clients when the challenge is validated and they are authenticated. - */ -message WsWelcome { - uint32 alias = 1; - map peer_identities = 2; -} - -/** - * Sent to the clients when a user connects and their identity is authenticated. - */ -message WsPeerJoin { - uint32 alias = 1; - string address = 2; -} - -/** - * Sent to the clients when a user gets disconnected. - */ -message WsPeerLeave { - uint32 alias = 1; -} - -/** - * This is the data package for all user messages. - */ -message WsPeerUpdate { - uint32 from_alias = 1; - bytes body = 2; - bool unreliable = 3; -} - - -/** - * Sent to the clients as first message, it contains a challenge string and a - * hint about if the same address is connected to another room. In such case, - * after authentication, the server may decide to end the former connection. This - * hint exists for UX purposes of the explorers for cases like multiple running - * instances of the explorer. - */ -message WsChallengeRequired { - string challenge_to_sign = 1; - bool already_connected = 2; -} - -/** - * Response to WsChallengeRequired, signed using the AuthChain mechanism. - */ -message WsSignedChallenge { - string auth_chain_json = 1; -} - -/** - * This is the first message sent by the clients, it us used to identify the client - * in the server. - */ -message WsIdentification { - string address = 1; -} - -/** - * This message is received by the peers when the same address logs in in a - * different session. It should signal that the client should be shut down and not - * retry any new comms connection. It can also be used to reject new users joining when - * the room capacity has been reached. - */ -message WsKicked { - string reason = 1; -} - -message WsPacket { - oneof message { - // direction: server->client - WsWelcome welcome_message = 1; - - // direction: server->client - WsPeerJoin peer_join_message = 2; - - // direction: client->(server)->client - WsPeerUpdate peer_update_message = 3; - - // direction: server->client - WsChallengeRequired challenge_message = 4; - - // direction: client->server - WsSignedChallenge signed_challenge_for_server = 5; - - // direction: server->client - WsPeerLeave peer_leave_message = 6; - - // direction: client->server - WsIdentification peer_identification = 7; - - // direction: server->client - WsKicked peer_kicked = 8; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/v1/broker.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/v1/broker.proto deleted file mode 100644 index 716ec0db6..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/v1/broker.proto +++ /dev/null @@ -1,114 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.comms.v1; - -enum MessageType { - MT_UNKNOWN_MESSAGE_TYPE = 0; - MT_WELCOME = 1; - MT_CONNECT = 2; - MT_WEBRTC_OFFER = 3; - MT_WEBRTC_ANSWER = 4; - MT_WEBRTC_ICE_CANDIDATE = 5; - MT_PING = 6; - MT_SUBSCRIPTION = 7; - MT_AUTH = 8; - - MT_TOPIC = 9; - MT_TOPIC_FW = 10; - - MT_TOPIC_IDENTITY = 11; - MT_TOPIC_IDENTITY_FW = 12; -} - -enum Role { - R_UNKNOWN_ROLE = 0; - R_CLIENT = 1; - R_COMMUNICATION_SERVER = 2; -} - -enum Format { - F_UNKNOWN_FORMAT = 0; - F_PLAIN = 1; - F_GZIP = 2; -} - -// NOTE: coordination messsages - -message CoordinatorMessage { - MessageType type = 1; -} - -message WelcomeMessage { - MessageType type = 1; - uint64 alias = 2; - repeated uint64 available_servers = 3; -} - -message ConnectMessage { - MessageType type = 1; - uint64 from_alias = 2; - uint64 to_alias = 3; -} - -message WebRtcMessage { - MessageType type = 1; - uint64 from_alias = 2; - uint64 to_alias = 3; - bytes data = 4; -} - -// NOTE: comm server messsages - -message MessageHeader { - MessageType type = 1; -} - -message PingMessage { - MessageType type = 1; - double time = 2; -} - -// NOTE: topics is a space separated string in the format specified by Format -message SubscriptionMessage { - MessageType type = 1; - Format format = 2; - bytes topics = 3; -} - -// NOTE: comm server messsages - -message AuthMessage { - MessageType type = 1; - Role role = 2; - bytes body = 3; -} - -message TopicMessage { - MessageType type = 1; - uint64 from_alias = 2; - string topic = 3; - bytes body = 4; -} - -message TopicFWMessage { - MessageType type = 1; - uint64 from_alias = 2; - bytes body = 3; -} - -message TopicIdentityMessage { - MessageType type = 1; - uint64 from_alias = 2; - string topic = 3; - bytes identity = 4; - Role role = 5; - bytes body = 6; -} - -message TopicIdentityFWMessage { - MessageType type = 1; - uint64 from_alias = 2; - bytes identity = 3; - Role role = 4; - bytes body = 5; -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/v1/comms.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/v1/comms.proto deleted file mode 100644 index c3f144c37..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/v1/comms.proto +++ /dev/null @@ -1,68 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.comms.v1; - -message AuthData { - string signature = 1; - string identity = 2; - string timestamp = 3; - string access_token = 4; -} - -enum Category { - C_UNKNOWN = 0; - C_POSITION = 1; - C_PROFILE = 2; - C_CHAT = 3; - C_SCENE_MESSAGE = 4; - C_PROF_REQ = 5; - C_PROF_RES = 6; -} - -message DataHeader { - Category category = 1; -} - -message PositionData { - Category category = 1; - double time = 2; - float position_x = 3; - float position_y = 4; - float position_z = 5; - float rotation_x = 6; - float rotation_y = 7; - float rotation_z = 8; - float rotation_w = 9; - bool immediate = 10; -} - -message ProfileData { - Category category = 1; - double time = 2; - string profile_version = 3; - enum ProfileType { - PT_LOCAL = 0; - PT_DEPLOYED = 1; - } - ProfileType profile_type = 4; -} - -message ProfileRequestData { - Category category = 1; - double time = 2; - string profile_version = 3; - string user_id = 4; -} - -message ProfileResponseData { - Category category = 1; - double time = 2; - string serialized_profile = 3; -} - -message ChatData { - Category category = 1; - double time = 2; - string message_id = 3; - string text = 4; -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/v2/comms.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/v2/comms.proto deleted file mode 100644 index 12b5dd9f6..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/v2/comms.proto +++ /dev/null @@ -1,61 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.comms.v2; - -message CommsMessage { - double time = 1; - oneof data { - PositionData position_data = 2; - ProfileData profile_data = 3; - ChatData chat_data = 4; - SceneData scene_data = 5; - VoiceData voice_data = 6; - ProfileRequestData profile_request_data = 7; - ProfileResponseData profile_response_data = 8; - } -} - -message PositionData { - float position_x = 1; - float position_y = 2; - float position_z = 3; - float rotation_x = 4; - float rotation_y = 5; - float rotation_z = 6; - float rotation_w = 7; - bool immediate = 8; -} - -message ProfileData { - string profile_version = 1; - string user_id = 2; - enum ProfileType { - PT_DEPLOYED = 0; - PT_LOCAL = 1; - } - ProfileType profile_type = 3; -} - -message ProfileRequestData { - string profile_version = 1; - string user_id = 2; -} - -message ProfileResponseData { - string serialized_profile = 1; -} - -message ChatData { - string message_id = 1; - string text = 2; -} - -message SceneData { - string scene_id = 1; - string text = 2; -} - -message VoiceData { - bytes encoded_samples = 1; - uint32 index = 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/v3/archipelago.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/v3/archipelago.proto deleted file mode 100644 index 8c5d6519b..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/v3/archipelago.proto +++ /dev/null @@ -1,86 +0,0 @@ -syntax = "proto3"; - -import "decentraland/common/vectors.proto"; - -package decentraland.kernel.comms.v3; - -// Server->Client messsages -message ChallengeResponseMessage { - string challenge_to_sign = 1; - bool already_connected = 2; -} - -message WelcomeMessage { - string peer_id = 1; -} - -message IslandChangedMessage { - string island_id = 1; - string conn_str = 2; - optional string from_island_id = 3; - map peers = 4; -} - -message LeftIslandMessage { - string island_id = 1; - string peer_id = 2; -} - -message JoinIslandMessage { - string island_id = 1; - string peer_id = 2; -} - -enum KickedReason { - KR_NEW_SESSION = 0; -} - -message KickedMessage { - KickedReason reason = 1; -} - -message ServerPacket { - oneof message { - ChallengeResponseMessage challenge_response = 1; - WelcomeMessage welcome = 2; - IslandChangedMessage island_changed = 3; - LeftIslandMessage left_island = 4; - JoinIslandMessage join_island = 5; - KickedMessage kicked = 6; - } -} - -// Client->Server messsages -message ChallengeRequestMessage { - string address = 1; -} - -message SignedChallengeMessage { - string auth_chain_json = 1; -} - -message Heartbeat { - decentraland.common.Position position = 1; - optional string desired_room = 2; -} - -message ClientPacket { - oneof message { - ChallengeRequestMessage challenge_request = 1; - SignedChallengeMessage signed_challenge = 2; - Heartbeat heartbeat = 3; - } -} - -// Others -message IslandData { - string id = 1; - repeated string peers = 2; - uint32 max_peers = 3; - decentraland.common.Position center = 4; - double radius = 5; -} - -message IslandStatusMessage { - repeated IslandData data = 1; -} diff --git a/crates/dcl_component/src/proto/decentraland/kernel/comms/v3/comms.proto b/crates/dcl_component/src/proto/decentraland/kernel/comms/v3/comms.proto deleted file mode 100644 index 0e7fb74f7..000000000 --- a/crates/dcl_component/src/proto/decentraland/kernel/comms/v3/comms.proto +++ /dev/null @@ -1,64 +0,0 @@ -syntax = "proto3"; - -package decentraland.kernel.comms.v3; - -message Position { - double time = 2; - float position_x = 3; - float position_y = 4; - float position_z = 5; - float rotation_x = 6; - float rotation_y = 7; - float rotation_z = 8; - float rotation_w = 9; -} - -message Profile { - double time = 2; - string profile_version = 3; - enum ProfileType { - PT_LOCAL = 0; - PT_DEPLOYED = 1; - } - ProfileType profile_type = 4; -} - -message ProfileRequest { - double time = 2; - string profile_version = 3; - string user_id = 4; -} - -message ProfileResponse { - double time = 2; - string serialized_profile = 3; -} - -message Chat { - double time = 2; - string message_id = 3; - string text = 4; -} - -message Scene { - double time = 2; - string scene_id = 3; - string data = 4; -} - -message Voice { - bytes encoded_samples = 2; - uint32 index = 3; -} - -message Data { - oneof message { - Position position = 1; - Profile profile = 2; - ProfileRequest profile_request = 3; - ProfileResponse profile_response = 4; - Chat chat = 5; - Scene scene = 6; - Voice voice = 7; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/quests/definitions.proto b/crates/dcl_component/src/proto/decentraland/quests/definitions.proto deleted file mode 100644 index 0704fb986..000000000 --- a/crates/dcl_component/src/proto/decentraland/quests/definitions.proto +++ /dev/null @@ -1,185 +0,0 @@ -syntax = "proto3"; -package decentraland.quests; - -import "google/protobuf/empty.proto"; - -// Errors -message InvalidQuest {} - -message NotUUID {} - -message InternalServerError {} - -message NotFoundQuestInstance {} - -message QuestAlreadyStarted {} - -message NotOwner {} - -message IgnoredEvent {} - -message StartQuestRequest { - string quest_id = 1; -} - -message StartQuestResponse { - /* There are a few valid reasons to not be accepted: - * - Quest is not found - * - Quest is deactivated (the owner deleted it) - * - User already started the quest - * - Internal errors (DB connection failed or something like that) */ - message Accepted {} - oneof response { - Accepted accepted = 1; - InvalidQuest invalid_quest = 2; - NotUUID not_uuid_error = 3; - InternalServerError internal_server_error = 4; - QuestAlreadyStarted quest_already_started = 5; - } -} - -message AbortQuestRequest { - string quest_instance_id = 1; -} - -message AbortQuestResponse { - /* There are a few valid reasons to not be accepted: - * - Quest instance is not found - * - Quest instance is from another user - * - Quest instance already aborted - * - Internal errors (DB connection failed or something like that) */ - message Accepted {} - oneof response { - Accepted accepted = 1; - NotFoundQuestInstance not_found_quest_instance = 2; - NotUUID not_uuid_error = 3; - NotOwner not_owner = 4; - InternalServerError internal_server_error = 5; - } -} - -message Event { - string id = 1; - string address = 2; - Action action = 3; -} - -message EventRequest { - Action action = 1; -} - -message EventResponse { - oneof response { - string accepted_event_id = 1; - IgnoredEvent ignored_event = 2; - InternalServerError internal_server_error = 3; - } -} - -message QuestDefinition { - repeated Step steps = 1; - repeated Connection connections = 2; -} - -message Connection { - string step_from = 1; - string step_to = 2; -} - -message Step { - string id = 1; - string description = 2; - repeated Task tasks = 3; -} - -message Action { - string type = 1; - map parameters = 2; -} - -message Task { - string id = 1; - string description = 2; - repeated Action action_items = 3; -} - -message StepContent { - repeated Task to_dos = 1; - repeated Task tasks_completed = 2; -} - -message QuestState { - map current_steps = 2; - fixed32 steps_left = 3; - repeated string steps_completed = 4; - repeated string required_steps = 5; -} - -message Quest { - string id = 1; - string name = 2; - string description = 3; - QuestDefinition definition = 4; - string creator_address = 5; - string image_url = 6; - bool active = 7; - fixed32 created_at = 8; -} - -message QuestInstance { - string id = 1; - Quest quest = 2; - QuestState state = 3; -} - -message QuestStateUpdate { - string instance_id = 1; - QuestState quest_state = 2; - string event_id = 3; -} - -message UserUpdate { - oneof message { - bool subscribed = 1; - QuestStateUpdate quest_state_update = 2; - QuestInstance new_quest_started = 3; - string event_ignored = 4; - } - string user_address = 5; -} - -message Quests { - repeated QuestInstance instances = 1; -} - -message GetAllQuestsResponse { - oneof response { - Quests quests = 1; - InternalServerError internal_server_error = 2; - } -} - -message GetQuestDefinitionRequest { - string quest_id = 1; -} - -message GetQuestDefinitionResponse { - oneof response { - Quest quest = 1; - InternalServerError internal_server_error = 2; - } -} - -service QuestsService { - // User actions - rpc StartQuest(StartQuestRequest) returns (StartQuestResponse) {} - rpc AbortQuest(AbortQuestRequest) returns (AbortQuestResponse) {} - rpc SendEvent(EventRequest) returns (EventResponse) {} - - // Listen to changes in quest states and event processing updates - rpc Subscribe(google.protobuf.Empty) returns (stream UserUpdate) {} - - // Query quest information - rpc GetAllQuests(google.protobuf.Empty) returns (GetAllQuestsResponse) {} - rpc GetQuestDefinition(GetQuestDefinitionRequest) returns (GetQuestDefinitionResponse) {} -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/realm/about.proto b/crates/dcl_component/src/proto/decentraland/realm/about.proto deleted file mode 100644 index 76a66069e..000000000 --- a/crates/dcl_component/src/proto/decentraland/realm/about.proto +++ /dev/null @@ -1,138 +0,0 @@ -syntax = "proto3"; -package decentraland.realm; - -import "decentraland/common/border_rect.proto"; -import "decentraland/common/vectors.proto"; - -message AboutResponse { - bool healthy = 1; - AboutConfiguration configurations = 2; - ContentInfo content = 3; - CommsInfo comms = 4; - LambdasInfo lambdas = 5; - optional BffInfo bff = 6; - bool accepting_users = 7; - - // @deprecated This message was never used but it's still here for compatibility reasons - // The reserved keyword is not working for all the toolset we have, so in the meanwhile it keeps commented - message MinimapConfiguration { - reserved 1; - // reserved "enabled"; - reserved 2; - // reserved "data_image"; - reserved 3; - // reserved "estate_image"; - } - - message MapConfiguration { - // whether the minimap should be rendered - bool minimap_enabled = 1; - - // the union of all rects here represents the places where that MAY have scenes - // - all the other parcels are considered as empty, up to the explorer to decide if they're walkable or not - // - the contained square is determined by points: - // - top-left with minX, maxY - // - bottom-left with minX, minY - // - top-right with maxX, maxY - // - bottom-right with maxX, maxY - // Note: the coordinate system used is the Cartesian coordinate system, where the y-axis increases upwards, - // not the screen coordinate system, where the origin is at the top-left corner and the y-axis increases downwards. - repeated decentraland.common.BorderRect sizes = 2; - - // ImageViewWithZoomLevel uses a description to render the minimap - // using different images with different zoom levels. - // When `version='v1'`: - // - The description allows the explorer to form the URL: - // url(x,y,zoom_level) = `{base_url}/{zoom_level}/{x},{y}{suffix_url}` - // - The given URL is for an image where the pixel `0,0` for the image `0,0` always - // points to the top-left contained square. - // - The `zoom_level=1` is to a ratio of 3.2 pixel per parcel, this means in a 32x32 pixel square - // you get 10x10 parcels. - // - Each increase of zoom level, double the ratio pixel per parcels. - message ImageViewWithZoomLevel { - // options: ['v1'] - string version = 1; - optional string base_url = 2; - optional string suffix_url = 3; - optional decentraland.common.Vector2 top_left_offset = 4; - } - - // ParcelView uses a description to render the minimap - // using a image where each pixel is a parcel and each pixel - // has the metadata to make a representation (using a shader or image-generation client-side) - // When `version='v1'`: - // - The pixel `0,0` is the top-left contained square - // - The image has to be at least of contained square pixels size - // - The metadata inside each pixel follows the generated with the atlas server https://github.com/decentraland/atlas-server/blob/af371f2a59745a1f50b0b0b2382984288c4ae891/src/adapters/mini-map-renderer.ts#L27 - message ParcelView { - // options: `v1` - string version = 1; - optional string image_url = 2; - } - - optional ImageViewWithZoomLevel satellite_view = 5; - optional ParcelView parcel_view = 6; - optional ImageViewWithZoomLevel thumbnail_view = 7; - } - - message SkyboxConfiguration { - // only one value at a time - optional float fixed_hour = 1; - } - - message AboutConfiguration { - optional string realm_name = 1; - uint32 network_id = 2; - repeated string global_scenes_urn = 3; - repeated string scenes_urn = 4; - - // The name "minimap" can't be used in this message - // The reserved keyword is not working for all the toolset we have, so in the meanwhile it keeps commented - reserved 5; - // reserved "minimap"; - - optional SkyboxConfiguration skybox = 6; - - // A content server to be used to load the parcels around the user. Uses the POST /entities/active endpoint - // to continously fetch the parcels around the users. if null, then the default content server will be used - // if == "" then the city_loader will be disabled and the scenes_urn will be used to load the world - optional string city_loader_content_server = 7; - optional MapConfiguration map = 8; - } - - message ContentInfo { - // common properties - bool healthy = 1; - optional string version = 2; - optional string commit_hash = 3; - string public_url = 4; - } - message LambdasInfo { - // common properties - bool healthy = 1; - optional string version = 2; - optional string commit_hash = 3; - string public_url = 4; - } - message CommsInfo { - // common properties - bool healthy = 1; - optional string version = 2; - optional string commit_hash = 3; - optional string public_url = 4; - // specific properties - string protocol = 50; - optional int32 users_count = 51; - optional string fixed_adapter = 52; - } - message BffInfo { - // common properties - bool healthy = 1; - optional string version = 2; - optional string commit_hash = 3; - string public_url = 4; - // specific properties - optional int32 user_count = 51; - optional string protocol_version = 52; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/README.md b/crates/dcl_component/src/proto/decentraland/sdk/components/README.md deleted file mode 100644 index 5f0dad7fd..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/README.md +++ /dev/null @@ -1,32 +0,0 @@ -# How to add a new ECS Component with Protocol-Buffers - -In this directory, we have all the components with the schema `ComponentName.proto`. `ComponentName` has to be PascalCase, and the `.proto` is the extension that is recognized as protocol-buffer schema. - -Inside each proto, we need to have at least this template: -```proto -syntax = "proto3"; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = XXXX; - -message PBComponentName { - float one_parameter = 1; -} - -``` - -Some points that must be well-defined: -- `XXXX` the component ID is a super important property of the component, and it has to be unique at least between proto, otherwise, the code generation will fail. -- `PBComponentName` the root message has to be the same as the file name with the prefix `PB` -- `one_parameter` each parameter name has to be snake_case. - - -## Common directory -The common directory only has to have unambiguous structures like decentraland.common.Vector3, decentraland.common.Color3, Quaternion, etc. These messages will never change. - -## About specific options with other languages -The definition must be the minimal proto code, and it shouldn't have a specific option to compile on some platform. So if you have to add additional information to the proto, you will be able to run a post-process after the protocol schemas acquisition. -For example, in the unity-renderer repo, it'll be necessary to add the `csharp_namespace` option but it's the responsibility of this particular implementation. This code option doesn't define how the component is. - -# Test component -If you write a proto and then push, CI will fail because the tests will fail. All the components need to be tested. `@dcl/ecs/test/components` has some examples! diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/Transform.md b/crates/dcl_component/src/proto/decentraland/sdk/components/Transform.md deleted file mode 100644 index 545e228d5..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/Transform.md +++ /dev/null @@ -1,25 +0,0 @@ - -# Transform - -Transform is not a protocol-buffer definition, because it uses the native byte-buffer to write directly on the wire. This allows the consumer to copy the message directly on memory and the component be serialized a little bit faster. - -```cpp -// Transform length = 44 -struct Transform { - float positionX; - float positionY; - float positionZ; - - float rotationX; - float rotationY; - float rotationZ; - float rotationW; - - float scaleX; - float scaleY; - float scaleZ; - - uint32_t parentEntity; -}; -``` -- Serialized in big-endian \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/animator.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/animator.proto deleted file mode 100644 index 3fcdb48c3..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/animator.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1042; - -// The Animator component is a container for multiple potential animations an Entity can display, -// separately or at the same time. It can be used to start, stop or blend animations; as well as -// to inspect their playback state. -// -// Animations have a `weight` property, which determines how pronounced the animation will be. This -// can be adjusted to blend animations together, or gracefully transition from one to the next. -message PBAnimator { - repeated PBAnimationState states = 1; // a collection of animations and their current state -} - -// (*) initial state means what frame is set when the state is reset: -// - if `speed` >= 0 the frame set is the first one -// - if `speed` < 0 the frame set is the last one -// (**) repeating means going back to the initial state at the moment the given animation is finished and keeps playing - -// AnimationState indicates the status and configuration of one available animation. -message PBAnimationState { - reserved 1; // deprecated `name` prop - string clip = 2; // the animation path in the `files` array of the scene manifest - optional bool playing = 3; // whether this animation is currently playing - optional float weight = 4; // @experimental the "weight" of this animation (see below, default: 1.0) - optional float speed = 5; // the playback speed (default: 1.0) - optional bool loop = 6; // whether the animation repeats (**) until is manually stopped (default: true) - optional bool should_reset = 7; // whether the animation is restored to the initial state (*) when it changes from stopped to playing (default: false) -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/asset_load.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/asset_load.proto deleted file mode 100644 index b605a1735..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/asset_load.proto +++ /dev/null @@ -1,10 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1213; - -// AssetLoad component allows an entity to request the pre-loading of one or more assets by the renderer. -message PBAssetLoad { - repeated string assets = 1; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/asset_load_loading_state.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/asset_load_loading_state.proto deleted file mode 100644 index 6bfca0b88..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/asset_load_loading_state.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1214; - -import "decentraland/sdk/components/common/loading_state.proto"; - -// AssetLoadLoadingState is set by the engine and provides information about -// the current state of the AssetLoad of an entity. -// The renderer appends a new object of this in each command, there can be many commands per frames -message PBAssetLoadLoadingState { - common.LoadingState current_state = 1; // current loading state - string asset = 2; // the asset being loaded (asset's scene path) - uint32 timestamp = 3; // monotonic counter -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/audio_event.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/audio_event.proto deleted file mode 100644 index 9bdea9c2e..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/audio_event.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/media_state.proto"; -option (common.ecs_component_id) = 1105; - -message PBAudioEvent { - common.MediaState state = 1; - uint32 timestamp = 2; // monotonic counter -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/audio_source.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/audio_source.proto deleted file mode 100644 index 480e13c5f..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/audio_source.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1020; - -// The AudioSource component can play an audio clips bundled with the scene, controlling some -// of the behavior. -// -// In each AudioSource instance, the sound is spatially located at the associated entity’s position, -// given by its Transform. -// -// Note that the `audio_clip_url` is not actually a URL, but rather the path of a file bundled with -// the scene and declared in its manifest. The name was chosen because the URL use-case will -// eventually be supported. -// -// `playing=true` when it's previously `playing=true` -// a) if clip is playing and `current_time` is NOT SET, the clip remains in the current `current_time` -// b) if clip is stopped or `current_time` is set, the clip is played from the `current_time` (if set) or from the beginning -// -// If other property (volume, loop, pitch) is changed while playing, the clip is keep playing with the new properties -// Changing `audio_clip_url` while playing stops the current clip and plays the new one (as a new instance) -message PBAudioSource { - optional bool playing = 1; // whether the clip is currently playing. - optional float volume = 2; // the audio volume (default: 1.0). - optional bool loop = 3; // whether the clip should restart when finished. - optional float pitch = 4; // the audio pitch (default: 1.0). - string audio_clip_url = 5; // the clip path as given in the `files` array of the scene's manifest. - optional float current_time = 6; // specifies the current playback time of the clip in seconds (default: 0). - optional bool global = 7; // whether the audio plays at constant volume across the scene. -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/audio_stream.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/audio_stream.proto deleted file mode 100644 index ba4045bc2..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/audio_stream.proto +++ /dev/null @@ -1,14 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1021; - -// The AudioStream component can play external audio clips given a URL, streaming it in real-time. -// -// Despite being attached to a particular entity, the sound is not affected by its position. -message PBAudioStream { - optional bool playing = 1; // whether the clip is currently playing - optional float volume = 2; // the audio volume (default: 1.0) - string url = 3; // the audio stream HTTP URL -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_attach.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_attach.proto deleted file mode 100644 index 7b24a1590..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_attach.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1073; - -// The AvatarAttach component automatically repositions an Entity to maintain the same position and -// rotation relative to some part of an avatar, called the "anchor point". The Entity -// will follow this anchor as it moves. -// -// The Entity's own Transform is overridden by this component. To offset position and adjust scale, -// add a child to the anchored Entity and set a Transform on it instead. -// -// AvatarAnchorPointType indicates which part of the avatar the Entity must follow. -message PBAvatarAttach { - optional string avatar_id = 1; // the user ID of the avatar (default: local user) - AvatarAnchorPointType anchor_point_id = 2; // the anchor point. -} - -// AvatarAnchorPointType determines the part of the avatar's body that anchors the Entity. -enum AvatarAnchorPointType { - // @deprecated consider parenting to `engine.PlayerEntity`, this will attach to player position with an arbitrary offset - AAPT_POSITION = 0; - AAPT_NAME_TAG = 1; - AAPT_HEAD = 4; - AAPT_NECK = 5; - AAPT_SPINE = 6; - AAPT_SPINE1 = 7; - AAPT_SPINE2 = 8; - AAPT_HIP = 9; - AAPT_LEFT_SHOULDER = 10; - AAPT_LEFT_ARM = 11; - AAPT_LEFT_FOREARM = 12; - AAPT_LEFT_HAND = 2; - AAPT_LEFT_HAND_INDEX = 13; - AAPT_RIGHT_SHOULDER = 14; - AAPT_RIGHT_ARM = 15; - AAPT_RIGHT_FOREARM = 16; - AAPT_RIGHT_HAND = 3; - AAPT_RIGHT_HAND_INDEX = 17; - AAPT_LEFT_UP_LEG = 18; - AAPT_LEFT_LEG = 19; - AAPT_LEFT_FOOT = 20; - AAPT_LEFT_TOE_BASE = 21; - AAPT_RIGHT_UP_LEG = 22; - AAPT_RIGHT_LEG = 23; - AAPT_RIGHT_FOOT = 24; - AAPT_RIGHT_TOE_BASE = 25; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_base.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_base.proto deleted file mode 100644 index 97b2fb1f4..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_base.proto +++ /dev/null @@ -1,15 +0,0 @@ - -syntax = "proto3"; -package decentraland.sdk.components; -import "decentraland/common/colors.proto"; -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1087; - -// AvatarBase sets all modifiers over the avatar's apparence. -message PBAvatarBase { - decentraland.common.Color3 skin_color = 1; - decentraland.common.Color3 eyes_color = 2; - decentraland.common.Color3 hair_color = 3; - string body_shape_urn = 4; - string name = 5; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_emote_command.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_emote_command.proto deleted file mode 100644 index 80d33a3f8..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_emote_command.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1088; - -// AvatarEmoteCommand is a grow only value set, used to signal the renderer about -// avatar emotes playback. -message PBAvatarEmoteCommand { - string emote_urn = 1; - bool loop = 2; - uint32 timestamp = 3; // monotonic counter -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_equipped_data.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_equipped_data.proto deleted file mode 100644 index 84cc3631a..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_equipped_data.proto +++ /dev/null @@ -1,14 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1091; - -// AvatarEquipData is used to read the information about the avatar's owneables. -// this component is written by the engine using the communications transports' -// data. -message PBAvatarEquippedData { - repeated string wearable_urns = 1; - repeated string emote_urns = 2; - repeated string force_render = 3; // slots that will render even if hidden -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_locomotion_settings.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_locomotion_settings.proto deleted file mode 100644 index a16f21698..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_locomotion_settings.proto +++ /dev/null @@ -1,18 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1211; - -// The PBAvatarLocomotionSettings component allows scenes to modify locomotion settings defining things such -// as the avatar movement speed, jump height etc. -message PBAvatarLocomotionSettings { - optional float walk_speed = 1; // Maximum speed when walking (in meters per second) - optional float jog_speed = 2; // Maximum speed when jogging (in meters per second) - optional float run_speed = 3; // Maximum speed when running (in meters per second) - optional float jump_height = 4; // Height of a regular jump (in meters) - optional float run_jump_height = 5; // Height of a jump while running (in meters) - optional float hard_landing_cooldown = 6; // Cooldown time after a hard landing before the avatar can move again (in seconds) -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_modifier_area.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_modifier_area.proto deleted file mode 100644 index 38be8e3d3..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_modifier_area.proto +++ /dev/null @@ -1,53 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1070; - -// The AvatarModifierArea component can be attached to an Entity to define a region of space where -// avatar behavior changes. -// -// The Entity's Transform position determines the center-point of the region, while its size is -// given as a vector in the `area` property below. The Transform rotation is applied, but the scale -// is ignored. -// -// The modifier effect is only applied to avatars inside the region. It does not affect how players -// standing inside it see avatars on the other side of the boundary. -// -// Note that, while commonly used to delineate a 2D area in a scene (hence the name), the region -// is actually a 3D volume. -message PBAvatarModifierArea { - decentraland.common.Vector3 area = 1; // the 3D size of the region - repeated string exclude_ids = 2; // user IDs that can enter and remain unaffected - repeated AvatarModifierType modifiers = 3; // list of modifiers to apply - optional AvatarMovementSettings movement_settings = 4; - optional bool use_collider_range = 5; // if true, the player will be considered inside the area when they are within 0.3m of the area. default true -} - -// AvatarModifierType is an effect that should be applied to avatars inside the region. -enum AvatarModifierType { - AMT_HIDE_AVATARS = 0; // avatars are invisible - AMT_DISABLE_PASSPORTS = 1; // selecting (e.g. clicking) an avatar will not bring up their profile. -} - -message AvatarMovementSettings { - optional AvatarControlType control_mode = 1; - // if not explicitly set, the following properties default to user's preference settings - optional float run_speed = 2; // speed the player moves at, in m/s - optional float friction = 3; // how fast the player gets up to speed or comes to rest. higher = more responsive - optional float gravity = 4; // how fast the player accelerates vertically when not on a solid surface, in m/s. should normally be negative - optional float jump_height = 5; // how high the player can jump, in meters. should normally be positive. gravity must have the same sign for jumping to be possible - optional float max_fall_speed = 6; // max fall speed in m/s. should normally be negative - optional float turn_speed = 7; // speed the player turns in tank mode, in radians/s - optional float walk_speed = 8; // speed the player walks at, in m/s - optional bool allow_weighted_movement = 9; // whether to allow player to move at a slower speed (e.g. with a walk-key or when using a gamepad/joystick). defaults to true -} - -enum AvatarControlType { - CCT_NONE = 0; // avatar cannot move - CCT_RELATIVE = 1; // avatar moves relative to the camera origin - CCT_TANK = 2; // avatar moves like a tank: left/right rotate the player, forward/backward advance/retreat the player -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_movement.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_movement.proto deleted file mode 100644 index 3f3880450..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_movement.proto +++ /dev/null @@ -1,46 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/vectors.proto"; - -option (common.ecs_component_id) = 1501; - -message PBAvatarMovement { - decentraland.common.Vector3 velocity = 1; - float orientation = 2; // 0-360, we don't allow pitch/roll - optional decentraland.common.Vector3 ground_direction = 3; - optional bool walk_success = 4; // set for one frame when a walk_target ends: true = reached target, false = failed; absent = in progress or no walk -} - -// engine behaviour (uses only capsule shapecasts and GJK closest point for portability): -// 1: set avatar orientation from movement info -> P0 -// 2: apply velocity (collide and slide) -// disable anything we are initially colliding with -// shapecast avatar from P3+N to p3+N+velocity*timestep -// on impact: -// project velocity onto slide plane (standard "Collide & Slide") -// velocity = old velocity - (normal * dot(velocity, normal)) -// continue with residual velocity and residual time -// -> P1 -// 3: record "ground collider" - nearest collider within threshold distance in ground_direction using avatar collider shapecast from P1 -// 4: update all colliders, record previous transform and new transform. -// 5: apply ground collider movement: take collider closest point, modify P1 translation and rotation by closest point translation and rotation change -> P2 -// 6: apply all other pseudo-ground collider movement: -// for each collider[i] that collides with the P2 player: -// let CTC = collider translation change -// if length(CTC) > max_move_threshold -// ignore / continue -// if dot(CTC, ground_direction) < 0 (i.e. collider is moving into the player from the ground direction) -// calculate collider_impact[i] => shapecast avatar from P2 + CTC[i] to P2. collider_impact[i] = CTC * (1 - time of impact) -// add max_by_length(collider_impact[i]) to player translation -> P3 -// 7: resolve collisions using position-based-dynamics -// while still colliding / until iteration N = max iterations -// for each collider[i] that collides with the P3+N player: -// if closest point = capsule middle (i.e. collider collides with P3 collider but with radius 0), -// ignore / continue -// else -// calculate depenetration vector[i] => closest point avatar - closest point collider -// add average(depenetration vector) to P3 -> P3+N -// repeat diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_movement_info.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_movement_info.proto deleted file mode 100644 index 46277f548..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_movement_info.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/avatar_locomotion_settings.proto"; -import "decentraland/sdk/components/input_modifier.proto"; - -option (common.ecs_component_id) = 1500; - -message PBAvatarMovementInfo { - float step_time = 1; // the length of time the current step velocity will apply for - float previous_step_time = 2; // the length of time the previous step velocity applied for - decentraland.common.Vector3 requested_velocity = 3; // the velocity requested for the previous frame - decentraland.common.Vector3 actual_velocity = 4; // the resulting velocity taking collisions into account - decentraland.common.Vector3 external_velocity = 5; // the velocity imparted by movement of the "ground" platform or pushing from other moving colliders - decentraland.sdk.components.PBAvatarLocomotionSettings active_avatar_locomotion_settings = 6; - decentraland.sdk.components.PBInputModifier active_input_modifier = 7; - optional decentraland.common.Vector3 walk_target = 8; // if set, the movement scene should walk the player to this scene-relative position - optional float walk_threshold = 9; // stop distance for walk_target -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_shape.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_shape.proto deleted file mode 100644 index 0c3bdb3f5..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/avatar_shape.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1080; -import "decentraland/common/colors.proto"; - -// The AvatarShape component contains the information required to draw and animate avatar, acting as -// a simplified GLTF container for this specific case. -// -// All fields (except ID) are optional have reasonable default values. In the case of `wearables`, -// each slot on the Avatar's body that is not explicitly included in the list has its own default. -// -// Note that, while AvatarShape can be attached to any Entity, it's only actually used in the global -// Avatar Scene. Other requirements are usually better served by GLTFs. -message PBAvatarShape { - string id = 1; // the user ID - optional string name = 2; // visible name (default: "NPC") - optional string body_shape = 3; // shape URN (default "urn:decentraland:off-chain:base-avatars:BaseFemale") - - optional decentraland.common.Color3 skin_color = 4; // RGB (default [0.6, 0.462, 0.356]) - optional decentraland.common.Color3 hair_color = 5; // RGB (default [0.283, 0.142, 0]) - optional decentraland.common.Color3 eye_color = 6; // RGB (default [0.6, 0.462, 0.356]) - - optional string expression_trigger_id = 7; // current emote animations - optional int64 expression_trigger_timestamp = 8; // start of emote animations (in the same order) - - optional bool talking = 9; // whether to display the floating voice chat icon - - // Wearable URNs, one for each body slot. - // Default values for each unspecified slot: - // Eyes : "urn:decentraland:off-chain:base-avatars:f_eyes_00", - // Eyebrows: "urn:decentraland:off-chain:base-avatars:f_eyebrows_00", - // Mouth : "urn:decentraland:off-chain:base-avatars:f_mouth_00" - // Hair : "urn:decentraland:off-chain:base-avatars:standard_hair", - // Shirt : "urn:decentraland:off-chain:base-avatars:f_simple_yellow_tshirt", - // Trousers: "urn:decentraland:off-chain:base-avatars:f_brown_trousers", - // Shoes : "urn:decentraland:off-chain:base-avatars:bun_shoes"] - repeated string wearables = 10; - repeated string emotes = 11; // available emotes (default empty) - optional bool show_only_wearables = 12; // hides the skin + hair + facial features - repeated string force_render = 13; // slots that will render even if hidden -} - diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/billboard.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/billboard.proto deleted file mode 100644 index 918b0ddec..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/billboard.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -// https://adr.decentraland.org/adr/ADR-198 -option (common.ecs_component_id) = 1090; - -// The Billboard component makes an Entity automatically reorient its rotation to face the camera. -// As the name indicates, it’s used to display in-game billboards and frequently combined with -// the TextShape component. -// -// Billboard only affects the Entity's rotation. Its scale and position are still determined by its -// Transform. -message PBBillboard { - optional BillboardMode billboard_mode = 1; // the BillboardMode (default: BM_ALL) -} - -// BillboardMode indicates one or more axis for automatic rotation, in OR-able bit flag form. -// Only the values below and the (BM_X | BM_Y) combination are valid. -enum BillboardMode { - BM_NONE = 0; - BM_X = 1; - BM_Y = 2; - BM_Z = 4; - BM_ALL = 7; // bitwise combination BM_X | BM_Y | BM_Z -} - diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_layer.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/camera_layer.proto deleted file mode 100644 index e6efc0c38..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_layer.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/colors.proto"; - -option (common.ecs_component_id) = 1503; - -message PBCameraLayer { - // layer to which these settings apply. must be > 0 - // Layer 0 is the default "real world" layer viewed by the player and cannot be modified. - uint32 layer = 1; - - // should the sun light affect this layer? default false - optional bool directional_light = 2; - - // should this layer show player avatars? default false - optional bool show_avatars = 3; - - // should this layer show the sky? default false - optional bool show_skybox = 4; - - // should this layer show distance fog? default false - optional bool show_fog = 5; - - // ambient light overrides for this layer. default -> use same as main camera - optional decentraland.common.Color3 ambient_color_override = 6; - optional float ambient_brightness_override = 7; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_layers.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/camera_layers.proto deleted file mode 100644 index 12803cede..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_layers.proto +++ /dev/null @@ -1,11 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1208; - -message PBCameraLayers { - repeated uint32 layers = 1; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_mode.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/camera_mode.proto deleted file mode 100644 index bad6d748b..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_mode.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1072; -import "decentraland/sdk/components/common/camera_type.proto"; - -// The CameraMode component can be used to determine whether the player is using a first-person o -// third-person view. -message PBCameraMode { - common.CameraType mode = 1; // the camera type (1st-person or 3rd-person) -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_mode_area.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/camera_mode_area.proto deleted file mode 100644 index 7a073bbff..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/camera_mode_area.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/camera_type.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1071; - -// The CameraModeArea component can be attached to an Entity to define a region of space where -// the player's camera mode (1st-person, 3rd-person or cinematic) is overridden. -// -// The Entity's Transform position determines the center-point of the region, while its size is -// given as a vector in the `area` property below. The Transform rotation is applied, but the scale -// is ignored. -// -// When players leave the region, their previous setting is restored. -// -// Note that, while commonly used to delineate a 2D area in a scene (hence the name), the region -// is actually a 3D volume. -// -// When mode is set to CtCinematic, the cinematic_settings field must also be provided. -message PBCameraModeArea { - decentraland.common.Vector3 area = 1; // the 3D size of the region - common.CameraType mode = 2; // the camera mode to enforce - optional CinematicSettings cinematic_settings = 3; - optional bool use_collider_range = 4; // if true, the player will be considered inside the area when they are within 0.3m of the area. default true -} - -message CinematicSettings { - uint32 camera_entity = 1; // Entity that defines the cinematic camera transform. - // Position -> camera's position - // Rotation -> camera's direction - // scale.z -> zoom level - // scale.x and scale.y -> unused - optional bool allow_manual_rotation = 2; // whether the user can move the camera's rotation. default false - optional float yaw_range = 3; // how far the camera can rotate around the y-axis / look left/right, in radians. default unrestricted - optional float pitch_range = 4; // how far the camera can rotate around the x-axis / look up-down, in radians. default unrestricted - // note: cameras can never look up/down further than Vec3::Y - optional float roll_range = 5; // how far the camera can rotate around the z-axis / tilt, in radians. default unrestricted - optional float zoom_min = 6; // minimum zoom level. must be greater than 0. defaults to the input zoom level - optional float zoom_max = 7; // maximum zoom level. must be greater than 0. defaults to the input zoom level -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/camera_transition.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/camera_transition.proto deleted file mode 100644 index 661cd8e1a..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/camera_transition.proto +++ /dev/null @@ -1,11 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components.common; - -// Defines the transition used towards the camera that contains the CameraTransition. -// This structure may be updated in the future to specify from/to entities and to have easing functions. -message CameraTransition { - oneof transition_mode { - float time = 1; - float speed = 2; // meters per second; e.g. speed 1 -> 1 meter per second - } -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/camera_type.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/camera_type.proto deleted file mode 100644 index 2c7d5a89a..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/camera_type.proto +++ /dev/null @@ -1,9 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components.common; - -enum CameraType { - CT_FIRST_PERSON = 0; - CT_THIRD_PERSON = 1; - CT_CINEMATIC = 2; // controlled by the scene -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/id.md b/crates/dcl_component/src/proto/decentraland/sdk/components/common/id.md deleted file mode 100644 index 2e389b3da..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/id.md +++ /dev/null @@ -1,2 +0,0 @@ -# Why id as file option? -Extending this option in the component definition allows having the data of its ID in the protocol buffer code generator. \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/id.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/id.proto deleted file mode 100644 index 37fd3bca6..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/id.proto +++ /dev/null @@ -1,8 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components.common; - -import "google/protobuf/descriptor.proto"; - -extend google.protobuf.FileOptions { - optional int32 ecs_component_id = 50000; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/input_action.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/input_action.proto deleted file mode 100644 index 00873e91e..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/input_action.proto +++ /dev/null @@ -1,32 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components.common; - -enum InputAction { - IA_POINTER = 0; - IA_PRIMARY = 1; - IA_SECONDARY = 2; - IA_ANY = 3; - IA_FORWARD = 4; - IA_BACKWARD = 5; - IA_RIGHT = 6; - IA_LEFT = 7; - IA_JUMP = 8; - IA_WALK = 9; - IA_ACTION_3 = 10; - IA_ACTION_4 = 11; - IA_ACTION_5 = 12; - IA_ACTION_6 = 13; - IA_MODIFIER = 14; -} - -// PointerEventType is a kind of interaction that can be detected. -enum PointerEventType { - PET_UP = 0; - PET_DOWN = 1; - PET_HOVER_ENTER = 2; - PET_HOVER_LEAVE = 3; - PET_DRAG_LOCKED = 4; - PET_DRAG = 5; - PET_DRAG_END = 6; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/loading_state.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/loading_state.proto deleted file mode 100644 index d10b76907..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/loading_state.proto +++ /dev/null @@ -1,10 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components.common; - -enum LoadingState { - UNKNOWN = 0; - LOADING = 1; - NOT_FOUND = 2; - FINISHED_WITH_ERROR = 3; - FINISHED = 4; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/media_state.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/media_state.proto deleted file mode 100644 index fdeb0c5b6..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/media_state.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components.common; - -enum MediaState { - MS_NONE = 0; - MS_ERROR = 1; - MS_LOADING = 2; - MS_READY = 3; - MS_PLAYING = 4; - MS_BUFFERING = 5; - MS_SEEKING = 6; - MS_PAUSED = 7; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/raycast_hit.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/raycast_hit.proto deleted file mode 100644 index 56d6eff25..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/raycast_hit.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components.common; -import "decentraland/common/vectors.proto"; - -// RaycastHit contains information about the intersection of a ray with a mesh. -message RaycastHit { - // Position will be relative to the scene - decentraland.common.Vector3 position = 1; // the intersection point in global coordinates - decentraland.common.Vector3 global_origin = 2; // the starting point of the ray in global coordinates - decentraland.common.Vector3 direction = 3; // the direction vector of the ray in global coordinates - decentraland.common.Vector3 normal_hit = 4; // normal of the hit surface in global coordinates - float length = 5; // the distance between the ray origin and the hit position - optional string mesh_name = 6; // mesh name, if collision happened inside a GltfContainer - optional uint32 entity_id = 7; // the ID of the Entity that has the impacted mesh attached -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/common/texts.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/common/texts.proto deleted file mode 100644 index 1e63f1ea6..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/common/texts.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components.common; - -enum TextAlignMode { - TAM_TOP_LEFT = 0; - TAM_TOP_CENTER = 1; - TAM_TOP_RIGHT = 2; - TAM_MIDDLE_LEFT = 3; - TAM_MIDDLE_CENTER = 4; - TAM_MIDDLE_RIGHT = 5; - TAM_BOTTOM_LEFT = 6; - TAM_BOTTOM_CENTER = 7; - TAM_BOTTOM_RIGHT = 8; -} - -enum Font { - F_SANS_SERIF = 0; - F_SERIF = 1; - F_MONOSPACE = 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/engine_info.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/engine_info.proto deleted file mode 100644 index ba32426ff..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/engine_info.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1048; - -// EngineInfo provides information about the graphics engine running the scene. -// The values of this component are written at the "physics" stage of the ADR-148. Meaning -// the tick_number and frame_number of the same frame could be used as correlation numbers -// for timestamps in other components. -message PBEngineInfo { - uint32 frame_number = 1; // frame counter of the engine - float total_runtime = 2; // total runtime of this scene in seconds - uint32 tick_number = 3; // tick counter of the scene as per ADR-148 -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/global_light.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/global_light.proto deleted file mode 100644 index 0fc850901..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/global_light.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/common/vectors.proto"; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1206; - -// defines the global scene light settings. must be added to the scene root. -// to control sunlight color, intensity, shadows etc, you can also add a PBLight to the scene root. -message PBGlobalLight { - // the direction the directional light shines in. - // default depends on time of day and explorer implementation - optional decentraland.common.Vector3 direction = 1; - // ambient light color - optional decentraland.common.Color3 ambient_color = 2; - // ambient light intensity. the explorer default ambient brightness is multiplied by this non-physical quantity. - // default 1 - optional float ambient_brightness = 3; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_container.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_container.proto deleted file mode 100644 index 21ddee7dc..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_container.proto +++ /dev/null @@ -1,19 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1041; - -// GltfContainer loads a GLTF file (and any additional files packaged inside) attached to an Entity. -// -// This allows the use of custom models, materials, collision boundaries and shapes that can't be -// achieved using MeshRenderer, MeshCollider and other standard components. -message PBGltfContainer { - string src = 1; // the GLTF file path as listed in the scene's manifest. - - reserved 2; - reserved 3; - - optional uint32 visible_meshes_collision_mask = 4; // default: 0 - optional uint32 invisible_meshes_collision_mask = 5; // default: CL_POINTER | CL_PHYSICS -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_container_loading_state.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_container_loading_state.proto deleted file mode 100644 index daa39933e..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_container_loading_state.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1049; - -import "decentraland/sdk/components/common/loading_state.proto"; - -// GltfContainerLoadingState is set by the engine and provides information about -// the current state of the GltfContainer of an entity. -message PBGltfContainerLoadingState { - common.LoadingState current_state = 1; - repeated string node_paths = 2; // all node paths in the gltf, which can be used with a GltfNode to inspect and modify the gltf contents - repeated string mesh_names = 3; // all meshes in the gltf. unnamed meshes will be auto-assigned a name of the form `MeshX` or `MeshX/PrimitiveY` - // where X is the mesh index and Y is the primitive index (and there is more than 1 primitive). note this may - // conflict with manually named meshes - to avoid any issues make sure all your meshes are explicitly named. - repeated string material_names = 4; // all materials in the gltf. unnamed materials will be auto-assigned a name of the form `MaterialX` where - // X is the material index. note this may conflict with manually named materials - to avoid any issues make - // sure all your materials are explicitly named. - repeated string skin_names = 5; // all mesh skins in the gltf. unnamed skins will be auto-assigned a name of the form `SkinX` where - // X is the skin index. note this may conflict with manually named skins - to avoid any issues make sure all - // your skins are explicitly named. - repeated string animation_names = 6; // all animations in the gltf. unnamed animations will be auto-assigned a name of the form `AnimationX` where - // X is the animation index. note this may conflict with manually named anims - to avoid any issues make sure all - // your animations are explicitly named. -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node.proto deleted file mode 100644 index 86d1e26ac..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node.proto +++ /dev/null @@ -1,42 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1200; - -// a GltfNode links a scene entity with a node from within a gltf, allowing the scene to inspect it or modify it. -// This component must be added to a direct child of an entity with a PBGltfContainer component, or -// to a direct child of another entity with a GltfNode component, and the referenced gltf node must be a descendent of the gltf node -// in the parent. -// The name must match the path of one of the nodes within the Gltf. These are available on the GltfContainerLoadingState component. -// -// The renderer will attach a PBGltfNodeState to the entity describing the state. Once the state is `GNS_READY`, -// - the `Transform` will be updated to match the position of the node within the gltf (relative to the gltf root, or the parent node), -// - a `MeshRenderer` with a GltfMesh mesh type will be added (if the gltf node has a mesh). -// - a `MeshCollider` with a GltfMesh mesh type will be added (if the gltf node has a collider). -// - a `Material` component including a GltfMaterial reference will be added (if the gltf node has a material). -// -// After creation, if an animation moves the node, the `Transform` will be updated. -// -// From the scene, you can modify various components to alter the gltf node: -// - modifying the `Transform` position/rotation/scale will move the node. The position is interpreted relative to the gltf root (or parent node), -// regardless of any intermediate gltf node hierarchy. -// If an animation is playing, the animation takes priority and the scene entity's position will be updated to match the animation. -// - `Visibility` can be added to hide or show the node and it's children in the gltf hierarchy. -// - `MeshRenderer` can be added/modified/removed to create/modify/remove a mesh on the node. -// - `MeshCollider` can be added/modified/removed to create/modify/remove a collider on the node. -// - `Material` can be added or modified to change the material properties. If the gltf node has a material, the original material will be -// used as a base, and any gltf features (e.g. occlusion maps) from the gtlf spec that the renderer supports but that are not exposed in the -// PBMaterial will be maintained. -// -// The scene can add additional entities as children to the gltf node, but structural modifications of the gltf are not possible: -// - changing the scene hierarchy will not change the gltf node hierarchy. Moving the entity out of the gltf will sever the link and -// change the state to `GNS_FAILED`. -// - deleting the scene entity will not delete the gltf node. -// -// Removing the GltfNode will revert any changes to the original gltf. If the GltfNode component is removed and the mesh/collider/material -// are not removed, this will result in a duplication of these components as the previously-linked entity will retain it's components and -// the gltf node will also be displayed. -message PBGltfNode { - string path = 1; // the path of the target node in the Gltf. -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node_modifiers.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node_modifiers.proto deleted file mode 100644 index 554644347..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node_modifiers.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/material.proto"; - -option (common.ecs_component_id) = 1099; - -// GltfNodeModifiers component is to be used attached to entities that have the GltfContainer component. -// -// This allows to override either the Material or the Casting Shadows behaviour of the target GLTF Node. -// -// * If the 'path' of the first modifier in the collection is an empty string: the configuration will -// affect all of the GLTF Nodes (as a global modifier). -// * Otherwise, for the modifiers whose 'path' is found in the GLTF hierarchy, the modifier will affect only -// the target Nodes. -message PBGltfNodeModifiers { - message GltfNodeModifier { - string path = 1; // The GLTF hierarchy path of the target Node to be affected - optional bool cast_shadows = 2; // The casting shadows enabled override - optional PBMaterial material = 3; // The Material that will be overridden on the target Node - } - repeated GltfNodeModifier modifiers = 1; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node_state.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node_state.proto deleted file mode 100644 index 1ce9512e9..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/gltf_node_state.proto +++ /dev/null @@ -1,20 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1201; - -// See the details of the GltfNode component for more information. - -// The state of a linked gltf node. -// If the state is GNSV_FAILED, the renderer may describe the failure in the error string. -message PBGltfNodeState { - GltfNodeStateValue state = 1; - optional string error = 2; -} - -enum GltfNodeStateValue { - GNSV_PENDING = 0; - GNSV_FAILED = 1; - GNSV_READY = 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/input_modifier.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/input_modifier.proto deleted file mode 100644 index 5bd978c67..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/input_modifier.proto +++ /dev/null @@ -1,20 +0,0 @@ -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; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/light_source.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/light_source.proto deleted file mode 100644 index 7831d69ba..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/light_source.proto +++ /dev/null @@ -1,28 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/colors.proto"; -import "decentraland/common/texture.proto"; -option (common.ecs_component_id) = 1079; - -message PBLightSource { - optional bool active = 1; // default = true, whether the lightSource is active or not. - optional decentraland.common.Color3 color = 2; // default = white, the tint of the light, in RGB format where each component is a floating point value with a range from 0 to 1. - optional float intensity = 3; // default = 100, light intensity expressed in candels (lumens/m^2 at 1 m distance, or lumens divided by 4*pi) - optional float range = 4; // default = -1, how far the light travels, expressed in meters. If left at 0 will be computed automatically as pow(intensity, 0.5) - optional bool shadow = 5; // default = false, whether the light casts shadows or not. - optional decentraland.common.TextureUnion shadow_mask_texture = 6; // Texture mask through which shadows are cast to simulate caustics, soft shadows, and light shapes such as light entering from a window. - - oneof type { - Point point = 7; - Spot spot = 8; - } - - message Point { - } - - message Spot { - optional float inner_angle = 9; // default = 21.8. Inner angle can't be higher than outer angle, otherwise will default to same value. Min value is 0. Max value is 179. - optional float outer_angle = 10; // default = 30. Outer angle can't be lower than inner angle, otherwise will inner angle will be set to same value. Max value is 179. - } -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/main_camera.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/main_camera.proto deleted file mode 100644 index 070c449c6..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/main_camera.proto +++ /dev/null @@ -1,11 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1075; - -// PBMainCamera.virtualCameraEntity defines which VirtualCamera entity is active at the moment. -// This component may hold 'repeated common.CameraTransition' transitionOverrides in the future -message PBMainCamera { - optional uint32 virtual_camera_entity = 1; // current active virtual camera -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/map_pin.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/map_pin.proto deleted file mode 100644 index 17973d3bb..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/map_pin.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/texture.proto"; -option (common.ecs_component_id) = 1097; - -// @deprecated -// Used internally for the game orchestrator PX, not exposed in the SDK -message PBMapPin { - decentraland.common.Vector2 position = 1; - optional decentraland.common.TextureUnion texture = 2; - float icon_size = 3; - string title = 4; - string description = 5; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/material.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/material.proto deleted file mode 100644 index 006a16202..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/material.proto +++ /dev/null @@ -1,69 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/common/texture.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1017; - -enum MaterialTransparencyMode { - MTM_OPAQUE = 0; - MTM_ALPHA_TEST = 1; - MTM_ALPHA_BLEND = 2; - MTM_ALPHA_TEST_AND_ALPHA_BLEND = 3; - MTM_AUTO = 4; -} - -message PBMaterial { - message UnlitMaterial { - optional decentraland.common.TextureUnion texture = 1; // default = null - optional float alpha_test = 2; // default = 0.5. range value: from 0 to 1 - optional bool cast_shadows = 3; // default = true - optional decentraland.common.Color4 diffuse_color = 4; // default = white; - optional decentraland.common.TextureUnion alpha_texture = 5; // default = null - } - - message PbrMaterial { - optional decentraland.common.TextureUnion texture = 1; // default = null - - optional float alpha_test = 2; // default = 0.5. range value: from 0 to 1 - optional bool cast_shadows = 3; // default = true - - optional decentraland.common.TextureUnion alpha_texture = 4; // default = null - optional decentraland.common.TextureUnion emissive_texture = 5; // default = null - optional decentraland.common.TextureUnion bump_texture = 6; // default = null - - optional decentraland.common.Color4 albedo_color = 7; // default = white; - optional decentraland.common.Color3 emissive_color = 8; // default = black; - optional decentraland.common.Color3 reflectivity_color = 9; // default = white; - - optional MaterialTransparencyMode transparency_mode = 10; // default = TransparencyMode.Auto - - optional float metallic = 11; // default = 0.5 - optional float roughness = 12; // default = 0.5 - reserved 13; - - optional float specular_intensity = 14; // default = 1 - optional float emissive_intensity = 15; // default = 2 - optional float direct_intensity = 16; // default = 1 - } - - oneof material { - UnlitMaterial unlit = 1; - PbrMaterial pbr = 2; - } - - message GltfMaterial { - string gltf_src = 1; - string name = 2; - } - - // A gltf material that may provide additional features not supported by the PbMaterial fields. - // If both gltf and material fields are provided, the gltf will be used only for extended features not - // supported by the PbMaterial. - // If this is provided and the `material` field is not provided, the renderer will update the material - // field with data that reflects the gltf material once it is loaded. - optional GltfMaterial gltf = 3; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/mesh_collider.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/mesh_collider.proto deleted file mode 100644 index 71250e7dc..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/mesh_collider.proto +++ /dev/null @@ -1,69 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1019; - -// The MeshCollider component provides basic collision detection between Entities and Avatars. It -// can behave like a cube, a plane, a sphere or a cylinder. -// -// The Entity's Transform affects the MeshCollider, scaling it and rotating it appropriately. If -// the Transform for the collision mesh must be different than the Transform for rendering the Entity, -// two different Entities must be used. -// -// More complex shapes require the use of a `GltfContainer` component. -message PBMeshCollider { - // BoxMesh is a prism shape that contains the Entity. - message BoxMesh {} - - // CylinderMesh is a truncated cone shape that contains the Entity. - message CylinderMesh { - optional float radius_top = 1; // (default 0.5) - optional float radius_bottom = 2; // (default 0.5) - } - - // PlaneMesh is a 2D rectangle described by the Entity's Transform. - message PlaneMesh {} - - // SphereMesh is a sphere shape that contains the Entity. - message SphereMesh {} - - // A collider constructed from a Gltf Mesh. - message GltfMesh { - string gltf_src = 1; // the GLTF file path as listed in the scene's manifest. - string name = 2; // the name of the mesh asset - } - - optional uint32 collision_mask = 1; // enabled ColliderLayers (default CL_POINTER | CL_PHYSICS) - - oneof mesh { - BoxMesh box = 2; - SphereMesh sphere = 3; - CylinderMesh cylinder = 4; - PlaneMesh plane = 5; - GltfMesh gltf = 6; - } -} - -// ColliderLayer determines the kind of collision to detect, in OR-able bit flag form. -enum ColliderLayer { - CL_NONE = 0; // no collisions - CL_POINTER = 1; // collisions with the player's pointer ray (e.g. mouse cursor hovering) - CL_PHYSICS = 2; // collision affecting your player's physics i.e. walls, floor, moving platfroms - CL_PLAYER = 4; - CL_RESERVED2 = 8; - CL_RESERVED3 = 16; - CL_RESERVED4 = 32; - CL_RESERVED5 = 64; - CL_RESERVED6 = 128; - CL_CUSTOM1 = 256; - CL_CUSTOM2 = 512; - CL_CUSTOM3 = 1024; - CL_CUSTOM4 = 2048; - CL_CUSTOM5 = 4096; - CL_CUSTOM6 = 8192; - CL_CUSTOM7 = 16384; - CL_CUSTOM8 = 32768; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/mesh_renderer.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/mesh_renderer.proto deleted file mode 100644 index a6095017a..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/mesh_renderer.proto +++ /dev/null @@ -1,48 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1018; - -// The MeshRenderer component renders a basic geometric shape for an Entity. It can be a cube, a -// plane, a sphere, a cylinder, or a Gltf mesh. -// -// The cube and plane variants can include a UV texture mapping, so specific areas of a material -// texture are rendered on different faces of the shape. They are serialized as a sequence of 2D -// `float` coordinates, one for each corner of each side of each face. -message PBMeshRenderer { - - // BoxMesh renders a prism shape. - message BoxMesh { - repeated float uvs = 1; // 96-value texture map (2D * 6 faces * 2 sides * 4 vertices) - } - - // CylinderMesh renders a truncated cone shape. - message CylinderMesh { - optional float radius_top = 1; // (default 0.5) - optional float radius_bottom = 2; // (default 0.5) - } - - // PlaneMesh renders a 2D rectangular shape. - message PlaneMesh { - repeated float uvs = 1; // 16-value texture map (2D * 1 face * 2 sides * 4 vertices) - } - - // SphereMesh renders a spherical shape. - message SphereMesh { - } - - // A mesh from a Gltf. - message GltfMesh { - string gltf_src = 1; // the GLTF file path as listed in the scene's manifest. - string name = 2; // the name of the mesh asset - } - - oneof mesh { - BoxMesh box = 1; - SphereMesh sphere = 2; - CylinderMesh cylinder = 3; - PlaneMesh plane = 4; - GltfMesh gltf = 5; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/nft_shape.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/nft_shape.proto deleted file mode 100644 index acb7ae9f7..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/nft_shape.proto +++ /dev/null @@ -1,48 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1040; - -// The NftShape component renders a framed picture from an NFT. It supports PNG, JPEG and GIF files. -// -// The `urn` field is the URI of the NFT, and must follow the format 'urn:decentraland::::' -// Example: 'urn:decentraland:ethereum:erc721:0x00000000:123' -// -// The picture frame can have several different styles, plus a background color for images that have -// transparent pixels. -message PBNftShape { - string urn = 1; // the URI of the NFT - optional NftFrameType style = 2; // the frame style (default NFT_CLASSIC) - optional decentraland.common.Color3 color = 3; // RGB background (default [0.6404918, 0.611472, 0.8584906]) -} - -// NftFrameType is a predefined framing style for the image. -enum NftFrameType { - NFT_CLASSIC = 0; - NFT_BAROQUE_ORNAMENT = 1; - NFT_DIAMOND_ORNAMENT = 2; - NFT_MINIMAL_WIDE = 3; - NFT_MINIMAL_GREY = 4; - NFT_BLOCKY = 5; - NFT_GOLD_EDGES = 6; - NFT_GOLD_CARVED = 7; - NFT_GOLD_WIDE = 8; - NFT_GOLD_ROUNDED = 9; - NFT_METAL_MEDIUM = 10; - NFT_METAL_WIDE = 11; - NFT_METAL_SLIM = 12; - NFT_METAL_ROUNDED = 13; - NFT_PINS = 14; - NFT_MINIMAL_BLACK = 15; - NFT_MINIMAL_WHITE = 16; - NFT_TAPE = 17; - NFT_WOOD_SLIM = 18; - NFT_WOOD_WIDE = 19; - NFT_WOOD_TWIGS = 20; - NFT_CANVAS = 21; - NFT_NONE = 22; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/player_identity_data.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/player_identity_data.proto deleted file mode 100644 index 68cba08c9..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/player_identity_data.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1089; - -// PlayerIdentityData is used to read the information about the avatar's -// identity. this component is written by the engine using the communications -// transports' data. -message PBPlayerIdentityData { - string address = 1; // ethereum address of this player - bool is_guest = 3; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_events.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_events.proto deleted file mode 100644 index 56daeb9c1..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_events.proto +++ /dev/null @@ -1,37 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/input_action.proto"; - -option (common.ecs_component_id) = 1062; - -// PointerEvents adds configurable pointer-based interactions to the attached Entity. -// -// Events that match the criteria defined in the PointerEvents structure are reported back to the -// Entity via the PointerEventsResult component. -// -// Some examples of events that can be detected: -// - Pointer hovering over the Entity. -// - Held mouse button released over the Entity. -// - Controller button pressed while targeting the Entity. -// - Key pressed while targeting the Entity, but only in close range. -// -// It also supports simple visual feedback when interactions occur, by showing floating text. -// More sophisticated feedback requires the use of other components. -message PBPointerEvents { - message Info { - optional common.InputAction button = 1; // key/button in use (default IA_ANY) - optional string hover_text = 2; // feedback on hover (default 'Interact') - optional float max_distance = 3; // range of interaction (default 10) - optional bool show_feedback = 4; // enable or disable hover text (default true) - } - - message Entry { - common.PointerEventType event_type = 1; // the kind of interaction to detect - Info event_info = 2; // additional configuration for this detection - } - - repeated Entry pointer_events = 1; // the list of relevant events to detect -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_events_result.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_events_result.proto deleted file mode 100644 index 127b35f20..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_events_result.proto +++ /dev/null @@ -1,19 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/input_action.proto"; -import "decentraland/sdk/components/common/raycast_hit.proto"; - -option (common.ecs_component_id) = 1063; - -// renderer append a new object of this in each command, there can be many commands per frames -message PBPointerEventsResult { - common.InputAction button = 1; // identifier of the input - common.RaycastHit hit = 2; - common.PointerEventType state = 4; - uint32 timestamp = 5; // monotonic counter - optional float analog = 6; // if the input is analog then we store it here - uint32 tick_number = 7; // number of tick in which the event was produced, equals to EngineInfo.tick_number -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_lock.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_lock.proto deleted file mode 100644 index 5843ee712..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/pointer_lock.proto +++ /dev/null @@ -1,11 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1074; - -// PointerLock indicates whether the mouse pointer is automatically following the camera’s point of -// focus (locked), or can move freely on the screen (unlocked). -message PBPointerLock { - bool is_pointer_locked = 1; // whether the pointer is locked -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/primary_pointer_info.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/primary_pointer_info.proto deleted file mode 100644 index 368e9d0ba..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/primary_pointer_info.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1209; - -import "decentraland/common/vectors.proto"; - -message PBPrimaryPointerInfo { - optional PointerType pointer_type = 1; - // in pixels - optional decentraland.common.Vector2 screen_coordinates = 2; - // in pixels - optional decentraland.common.Vector2 screen_delta = 3; - // ray direction that can be used with the primary camera origin for - // raycasting from the cursor into the world - optional decentraland.common.Vector3 world_ray_direction = 4; -} - -enum PointerType { - POT_NONE = 0; - POT_MOUSE = 1; - POT_PAD = 2; - POT_TOUCH = 3; - POT_WAND = 4; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/raycast.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/raycast.proto deleted file mode 100644 index 2896c0417..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/raycast.proto +++ /dev/null @@ -1,71 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1067; - -// The PBRaycast component and PBRaycastResult are defined in https://adr.decentraland.org/adr/ADR-200 -// -// The Raycast component allows scenes to request raycasting from the game engine. The results will -// be available in a RaycastResult component set later on the same Entity. -message PBRaycast { - // Correlation ID, defined by the scene and used internally by the scene - optional uint32 timestamp = 1; - - // How much to offset the starting point of the ray, relative to the entity's transform. - // Defaults to vec3(0,0,0) - optional decentraland.common.Vector3 origin_offset = 2; - - oneof direction { - // The direction of the ray in local coordinates (relative to the origin point) - decentraland.common.Vector3 local_direction = 6; - - // The direction of the ray in global coordinates (relative to origin) - decentraland.common.Vector3 global_direction = 3; - - // Target coordinates of the raycast, in global coordinates - decentraland.common.Vector3 global_target = 7; - - // Will point to the final world position of another entity - uint32 target_entity = 10; - } - - // Maximum length of the ray in virtual meters (global space) - float max_distance = 4; - - // the RaycastQueryType behavior - RaycastQueryType query_type = 5; - - // Indicates the renderer to perform the raycast on every scene tick (ADR-148), - // otherwise it will be performed only once, defaults to false - optional bool continuous = 8; - - // Collision mask, by default CL_POINTER | CL_PHYSICS - optional uint32 collision_mask = 9; - - // shape to cast, default ray - optional RaycastShape shape = 11; - - // include hits with entities from other scenes - optional bool include_world = 12; -} - -// RaycastQueryType indicates whether the ray should stop on the first collition, or continue. -enum RaycastQueryType { - // Pick the first (not necessarily the closest) hit within the range - RQT_HIT_FIRST = 0; - // Pick all hits within the range - RQT_QUERY_ALL = 1; - // Do not perform the raycast, only set the raycast result with empty hits - RQT_NONE = 2; -} - -enum RaycastShape { - // cast a point, get collisions along a ray - RS_RAY = 0; - // cast the avatar collider shape, get collisions from sweeping the shape - RS_AVATAR = 1; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/raycast_result.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/raycast_result.proto deleted file mode 100644 index d23c192d7..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/raycast_result.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/raycast_hit.proto"; - -option (common.ecs_component_id) = 1068; - -// The PBRaycast component and PBRaycastResult are defined in https://adr.decentraland.org/adr/ADR-200 -// -// The RaycastResult component is added to an Entity when the results of a previously attached -// Raycast component are available. It contains information about the ray and any objects it -// collided with. -message PBRaycastResult { - optional uint32 timestamp = 1; // timestamp is a correlation id, copied from the PBRaycast - decentraland.common.Vector3 global_origin = 2; // the starting point of the ray in global coordinates - decentraland.common.Vector3 direction = 3; // the direction vector of the ray in global coordinates - repeated decentraland.sdk.components.common.RaycastHit hits = 4; // zero or more hits - uint32 tick_number = 5; // number of tick in which the event was produced, equals to EngineInfo.tick_number -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/realm_info.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/realm_info.proto deleted file mode 100644 index 6c6b73010..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/realm_info.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1106; - -message PBRealmInfo { - string base_url = 1; - string realm_name = 2; - int32 network_id = 3; - string comms_adapter = 4; - bool is_preview = 5; - optional string room = 6; - optional bool is_connected_scene_room = 7; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/skybox_time.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/skybox_time.proto deleted file mode 100644 index 60e1ec320..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/skybox_time.proto +++ /dev/null @@ -1,20 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1210; - -// The SkyboxTime component allows controlling the time of day for the skybox, -// affecting the lighting and appearance of the sky in the scene. -message PBSkyboxTime { - uint32 fixed_time = 1; // fixed time of day, represented as a number of seconds since the start of the day, where 0 is 00:00hs, 43200 is 12:00hs and 86400 is 24:00hs - optional TransitionMode transition_mode = 2; // default = TransitionMode.TM_FORWARD, controls the direction of time transitions -} - -// Controls the direction for animated skybox transitions -enum TransitionMode { - TM_FORWARD = 0; // transitions forward (default) - TM_BACKWARD = 1; // transitions backward -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/text_shape.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/text_shape.proto deleted file mode 100644 index 3f529dadd..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/text_shape.proto +++ /dev/null @@ -1,45 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/texts.proto"; - -option (common.ecs_component_id) = 1030; - -// The TextShape component renders customizable floating text. -// -// The position and rotation of the text are defined by the Entity's Transform, while its size -// can either scale with the Transform or be fixed by a font size. -// -// Several options can be configured, including color, padding, line spacing and drop shadows. -message PBTextShape { - string text = 1; // the content - - optional common.Font font = 2; // the font (default F_SANS_SERIF) - optional float font_size = 3; // the font size (default 10) - optional bool font_auto_size = 4; // override `font_size` to automatically fit in `width`/`height` - - optional common.TextAlignMode text_align = 5; // X and Y alignment (default TAM_CENTER_CENTER) - - optional float width = 6; // available horizontal space (default 1) - optional float height = 7; // available vertical space (default 1) - optional float padding_top = 8; // distance from text to top border (default 0) - optional float padding_right = 9; // distance from text to right border (default 0) - optional float padding_bottom = 10; // distance from text to bottom border (default 0) - optional float padding_left = 11; // distance from text to left border (default 0) - - optional float line_spacing = 12; // extra distance between lines (default 0) - optional int32 line_count = 13; // maximum number of lines to display - optional bool text_wrapping = 14; // wrap text when the border is reached (default false) - - optional float shadow_blur = 15; // blurriness of the drop shadow (default 0) - optional float shadow_offset_x = 16; // horizontal length of the shadow (default 0) - optional float shadow_offset_y = 17; // vertical length of the shadow (default 0) - optional float outline_width = 18; // width of the stroke outlining each letter (default 0) - - optional decentraland.common.Color3 shadow_color = 19; // drop shadow color (default [1.0, 1.0, 1.0]) - optional decentraland.common.Color3 outline_color = 20; // outline stroke color (default [1.0, 1.0, 1.0]) - optional decentraland.common.Color4 text_color = 21; // text color (default [1.0, 1.0, 1.0]) -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/texture_camera.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/texture_camera.proto deleted file mode 100644 index 66bfd8c46..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/texture_camera.proto +++ /dev/null @@ -1,45 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/colors.proto"; - -option (common.ecs_component_id) = 1207; - -message PBTextureCamera { - // rendered texture width - optional uint32 width = 1; - // rendered texture height - optional uint32 height = 2; - // which layer of entities to render. entity layers can be specified by adding PBCameraLayers to target entities. - // defaults to 0 - optional uint32 layer = 3; - - // default black - optional decentraland.common.Color4 clear_color = 6; - // default infinity - optional float far_plane = 7; - - oneof mode { - Perspective perspective = 8; - Orthographic orthographic = 9; - /* Portal portal = 10; */ - }; - - // controls whether this camera acts as a receiver for audio on sources with matching `PBCameraLayers`. - // default 0 - optional float volume = 10; -} - -message Perspective { - // vertical field of view in radians - // defaults to pi/4 = 45 degrees - optional float field_of_view = 1; -} - -message Orthographic { - // vertical extent of the visible range in meters - // defaults to 4m - optional float vertical_range = 1; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/trigger_area.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/trigger_area.proto deleted file mode 100644 index 6c238f4d0..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/trigger_area.proto +++ /dev/null @@ -1,23 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1060; - -// The PBTriggerArea component is used to raise collision triggering events (through the TriggerAreaResult component) -// when entities enter this component's defined area. -// -// ADR: https://github.com/decentraland/adr/blob/2b30a5e2b4f359a7c22a68fb827db282f6e5f887/content/ADR-258-trigger-areas.md -// -// The area size and rotation is defined by the Entity's Transform. -message PBTriggerArea { - optional TriggerAreaMeshType mesh = 1; // default: MT_BOX - optional uint32 collision_mask = 2; // default: CL_PLAYER -} - -enum TriggerAreaMeshType { - TAMT_BOX = 0; - TAMT_SPHERE = 1; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/trigger_area_result.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/trigger_area_result.proto deleted file mode 100644 index 63f225164..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/trigger_area_result.proto +++ /dev/null @@ -1,34 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1061; - -// The PBTriggerAreaResult component is used to transport the trigger collision event data for the PBTriggerArea component. -// ADR: https://github.com/decentraland/adr/blob/2b30a5e2b4f359a7c22a68fb827db282f6e5f887/content/ADR-258-trigger-areas.md -message PBTriggerAreaResult { - // Trigger data object - message Trigger { - uint32 entity = 1; // The entity that triggered the Trigger Area - uint32 layers = 2; // The collision layermask of the entity that triggered the Trigger Area - decentraland.common.Vector3 position = 3; // The position of the entity that triggered the trigger - decentraland.common.Quaternion rotation = 4; // The rotation of the entity that triggered the trigger - decentraland.common.Vector3 scale = 5; // The scale of the entity that triggered the trigger - } - - uint32 triggered_entity = 1; // The entity that was triggered (this is the entity that owns the trigger area) - decentraland.common.Vector3 triggered_entity_position = 2; // The position of the triggered entity at the time of the trigger - decentraland.common.Quaternion triggered_entity_rotation = 3; // The rotation of the triggered entity at the time of the trigger - TriggerAreaEventType event_type = 4; // The state of the trigger event (ENTER, STAY, EXIT) - uint32 timestamp = 5; // The timestamp of the trigger event - Trigger trigger = 6; -} - -enum TriggerAreaEventType { - TAET_ENTER = 0; - TAET_STAY = 1; - TAET_EXIT = 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/tween.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/tween.proto deleted file mode 100644 index 2ed6d7840..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/tween.proto +++ /dev/null @@ -1,88 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1102; - -message PBTween { - float duration = 1; // in milliseconds - EasingFunction easing_function = 2; - - oneof mode { - Move move = 3; - Rotate rotate = 4; - Scale scale = 5; - TextureMove texture_move = 8; - } - - optional bool playing = 6; // default true (pause or running) - optional float current_time = 7; // between 0 and 1 -} - -message Move { - decentraland.common.Vector3 start = 1; - decentraland.common.Vector3 end = 2; - optional bool face_direction = 3; -} - -message Rotate { - decentraland.common.Quaternion start = 1; - decentraland.common.Quaternion end = 2; -} - -message Scale { - decentraland.common.Vector3 start = 1; - decentraland.common.Vector3 end = 2; -} - -// This tween mode allows to move the texture of a PbrMaterial or UnlitMaterial. -// You can also specify the movement type (offset or tiling) -message TextureMove { - decentraland.common.Vector2 start = 1; - decentraland.common.Vector2 end = 2; - optional TextureMovementType movement_type = 3; // default = TextureMovementType.TMT_OFFSET -} - -enum TextureMovementType { - TMT_OFFSET = 0; // default = TextureMovementType.TMT_OFFSET - TMT_TILING = 1; -} - -// Implementation guidelines for these easing functions can be found -// at https://github.com/ai/easings.net/blob/6fcd5f852a470bf1a7890e8178afa0f471d5f2ec/src/easings/easingsFunctions.ts -enum EasingFunction { - EF_LINEAR = 0; // default - EF_EASEINQUAD = 1; - EF_EASEOUTQUAD = 2; - EF_EASEQUAD = 3; - EF_EASEINSINE = 4; - EF_EASEOUTSINE = 5; - EF_EASESINE = 6; - EF_EASEINEXPO = 7; - EF_EASEOUTEXPO = 8; - EF_EASEEXPO = 9; - EF_EASEINELASTIC = 10; - EF_EASEOUTELASTIC = 11; - EF_EASEELASTIC = 12; - EF_EASEINBOUNCE = 13; - EF_EASEOUTBOUNCE = 14; - EF_EASEBOUNCE = 15; - EF_EASEINCUBIC = 16; - EF_EASEOUTCUBIC = 17; - EF_EASECUBIC = 18; - EF_EASEINQUART = 19; - EF_EASEOUTQUART = 20; - EF_EASEQUART = 21; - EF_EASEINQUINT = 22; - EF_EASEOUTQUINT = 23; - EF_EASEQUINT = 24; - EF_EASEINCIRC = 25; - EF_EASEOUTCIRC = 26; - EF_EASECIRC = 27; - EF_EASEINBACK = 28; - EF_EASEOUTBACK = 29; - EF_EASEBACK = 30; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/tween_sequence.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/tween_sequence.proto deleted file mode 100644 index 81e30439e..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/tween_sequence.proto +++ /dev/null @@ -1,18 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/tween.proto"; - -option (common.ecs_component_id) = 1104; - -message PBTweenSequence { - repeated PBTween sequence = 1; - optional TweenLoop loop = 2; -} - -enum TweenLoop { - TL_RESTART = 0; - TL_YOYO = 1; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/tween_state.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/tween_state.proto deleted file mode 100644 index eed148eaf..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/tween_state.proto +++ /dev/null @@ -1,18 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1103; - -message PBTweenState { - TweenStateStatus state = 1; - float current_time = 2; // between 0 and 1 -} - -enum TweenStateStatus { - TS_ACTIVE = 0; - TS_COMPLETED = 1; - TS_PAUSED= 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_background.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_background.proto deleted file mode 100644 index 8d1201e0f..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_background.proto +++ /dev/null @@ -1,34 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1053; - -import "decentraland/common/colors.proto"; -import "decentraland/common/texture.proto"; -import "decentraland/common/border_rect.proto"; - -message PBUiBackground { - optional decentraland.common.Color4 color = 1; // default=(1.0, 1.0, 1.0, 1.0), pixel = color * sample2D(texture, uv) - optional decentraland.common.TextureUnion texture = 2; - BackgroundTextureMode texture_mode = 3; - optional decentraland.common.BorderRect texture_slices = 4; // default=(1/3, 1/3, 1/3, 1/3) - repeated float uvs = 5; // default=[0,0,0,1,1,0,1,0]: starting from bottom-left vertex clock-wise -} - -enum BackgroundTextureMode { - // https://docs.unity3d.com/Manual/UIE-USS-SupportedProperties.html (Slicing section) - // https://forum.unity.com/threads/how-does-slicing-in-ui-tookkit-works.1235863/ - // https://docs.unity3d.com/Manual/9SliceSprites.html - // https://developer.mozilla.org/en-US/docs/Web/CSS/border-image-slice - NINE_SLICES = 0; - - // CENTER enables the texture to be rendered centered in relation to the - // element. If the element is smaller than the texture then the background - // should use the element as stencil to cut off the out-of-bounds area - CENTER = 1; - - // STRETCH enables the texture to cover all the area of the container, - // adopting its aspect ratio. - STRETCH = 2; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_canvas.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_canvas.proto deleted file mode 100644 index 3790d96ca..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_canvas.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; - -import "decentraland/sdk/components/common/id.proto"; -package decentraland.sdk.components; - -option (common.ecs_component_id) = 1203; - -import "decentraland/common/colors.proto"; - -// The UiCanvas component can be attached to a ui root entity to specify properties of the ui texture. -message PBUiCanvas { - uint32 width = 1; - uint32 height = 2; - - optional decentraland.common.Color4 color = 3; // default = (0.0, 0.0, 0.0, 0.0) / transparent -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_canvas_information.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_canvas_information.proto deleted file mode 100644 index f2e84e97d..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_canvas_information.proto +++ /dev/null @@ -1,24 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/border_rect.proto"; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1054; - -// This component is created by the renderer and used by the scenes to know the resolution of the UI canvas -message PBUiCanvasInformation { - // informs the scene about the resolution used for the UI rendering - float device_pixel_ratio = 1; - // informs about the width of the canvas, in virtual pixels. this value does not change when the pixel ratio changes. - int32 width = 2; - // informs about the height of the canvas, in virtual pixels. this value does not change when the pixel ratio changes. - int32 height = 3; - // informs the sdk about the interactable area. some implementations may change - // this area depending on the HUD that is being shown. this value may change at - // any time by the Renderer to create reactive UIs. as an example, an explorer with the - // chat UI hidden and with no minimap could have a rect that covers the whole screen. - // on the contrary, if the chat UI is shown, the rect would be smaller. - decentraland.common.BorderRect interactable_area = 4; -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_dropdown.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_dropdown.proto deleted file mode 100644 index 0518c9b51..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_dropdown.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/texts.proto"; - -option (common.ecs_component_id) = 1094; - -message PBUiDropdown { - bool accept_empty = 1; - optional string empty_label = 2; - repeated string options = 3; - optional int32 selected_index = 4; // default=null when accept_empty==true; default=0 when accept_empty==false - bool disabled = 5; - optional decentraland.common.Color4 color = 6; // default=(0.0,0.0,0.0,1.0) - - optional common.TextAlignMode text_align = 10; // default='center' - optional common.Font font = 11; // default=0 - optional int32 font_size = 12; // default=10 -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_dropdown_result.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_dropdown_result.proto deleted file mode 100644 index 42f14d4cc..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_dropdown_result.proto +++ /dev/null @@ -1,11 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1096; - -message PBUiDropdownResult { - int32 value = 1; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_input.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_input.proto deleted file mode 100644 index 33dac4482..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_input.proto +++ /dev/null @@ -1,20 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/texts.proto"; - -option (common.ecs_component_id) = 1093; - -message PBUiInput { - string placeholder = 1; - optional decentraland.common.Color4 color = 2; // default=(0.0,0.0,0.0,1.0) - optional decentraland.common.Color4 placeholder_color = 3; // default=(0.3,0.3,0.3,1.0) - bool disabled = 4; - optional common.TextAlignMode text_align = 10; // default='center' - optional common.Font font = 11; // default=0 - optional int32 font_size = 12; // default=10 - optional string value = 13; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_input_result.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_input_result.proto deleted file mode 100644 index 5f7341f90..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_input_result.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; - -option (common.ecs_component_id) = 1095; - -message PBUiInputResult { - string value = 1; - optional bool is_submit = 2; // default: false -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_scroll_result.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_scroll_result.proto deleted file mode 100644 index 7875f8866..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_scroll_result.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/vectors.proto"; - -option (common.ecs_component_id) = 1202; - -message PBUiScrollResult { - decentraland.common.Vector2 value = 1; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_text.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_text.proto deleted file mode 100644 index 6af0782dd..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_text.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/common/colors.proto"; -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/sdk/components/common/texts.proto"; - -option (common.ecs_component_id) = 1052; - -enum TextWrap { - TW_WRAP = 0; - TW_NO_WRAP = 1; -} - -// The UiText component creates a text widget inside a UI component tree. Its position and -// layout properties can be specified in a UiTransform component on the same Entity. - -message PBUiText { - string value = 1; // the text content, tag and are supported - optional decentraland.common.Color4 color = 2; // RGBA color (default: opaque white) - optional common.TextAlignMode text_align = 3; // alignment within the bounds (default: center) - optional common.Font font = 4; // font for the text (default: sans-serif) - optional int32 font_size = 5; // size of the text (default: 10) - optional TextWrap text_wrap = 6; // wrap text when the border is reached (default: TW_WRAP) - - optional float outline_width = 7; // width of the outline (default: 0) - optional decentraland.common.Color4 outline_color = 8; // RGBA color of the outline (default: opaque black) -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_transform.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/ui_transform.proto deleted file mode 100644 index 746fc0c7d..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/ui_transform.proto +++ /dev/null @@ -1,198 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -import "decentraland/common/colors.proto"; -import "decentraland/common/vectors.proto"; - -option (common.ecs_component_id) = 1050; - -enum YGPositionType { - YGPT_RELATIVE = 0; - YGPT_ABSOLUTE = 1; -} - -enum YGAlign { - YGA_AUTO = 0; - YGA_FLEX_START = 1; - YGA_CENTER = 2; - YGA_FLEX_END = 3; - YGA_STRETCH = 4; - YGA_BASELINE = 5; - YGA_SPACE_BETWEEN = 6; - YGA_SPACE_AROUND = 7; -} - -enum YGUnit { - YGU_UNDEFINED = 0; - YGU_POINT = 1; - YGU_PERCENT = 2; - YGU_AUTO = 3; -} - -enum YGFlexDirection { - YGFD_ROW = 0; - YGFD_COLUMN = 1; - YGFD_COLUMN_REVERSE = 2; - YGFD_ROW_REVERSE = 3; -} - -enum YGWrap { - YGW_NO_WRAP = 0; - YGW_WRAP = 1; - YGW_WRAP_REVERSE = 2; -} - -enum YGJustify { - YGJ_FLEX_START = 0; - YGJ_CENTER = 1; - YGJ_FLEX_END = 2; - YGJ_SPACE_BETWEEN = 3; - YGJ_SPACE_AROUND = 4; - YGJ_SPACE_EVENLY = 5; -} - -enum YGOverflow { - YGO_VISIBLE = 0; - YGO_HIDDEN = 1; - YGO_SCROLL = 2; -} - -enum YGDisplay { - YGD_FLEX = 0; - YGD_NONE = 1; -} - -enum YGEdge { - YGE_LEFT = 0; - YGE_TOP = 1; - YGE_RIGHT = 2; - YGE_BOTTOM = 3; - YGE_START = 4; - YGE_END = 5; - YGE_HORIZONTAL = 6; - YGE_VERTICAL = 7; - YGE_ALL = 8; -} - -enum PointerFilterMode { - PFM_NONE = 0; - PFM_BLOCK = 1; -} - -enum ShowScrollBar { - SSB_BOTH = 0; - SSB_ONLY_VERTICAL = 1; - SSB_ONLY_HORIZONTAL = 2; - SSB_HIDDEN = 3; -} - -message ScrollPositionValue { - oneof value { - decentraland.common.Vector2 position = 1; - string reference = 2; - } -} - -message PBUiTransform { - int32 parent = 1; - int32 right_of = 2; - - optional YGAlign align_content = 3; // default: YGAlign.YGA_FLEX_START - optional YGAlign align_items = 4; // default: YGAlign.YGA_STRETCH - optional YGWrap flex_wrap = 5; // default: YGWrap.YGW_WRAP - optional float flex_shrink = 6; // default: 1 - - YGPositionType position_type = 7; // YGPositionType.YGPT_RELATIVE - - YGAlign align_self = 8; // YGAlign.YGA_AUTO - YGFlexDirection flex_direction = 9; // YGFlexDirection.YGFD_ROW - YGJustify justify_content = 10; // YGJustify.YGJ_FLEX_START - - YGOverflow overflow = 11; // YGOverflow.YGO_VISIBLE - YGDisplay display = 12; // YGDisplay.YGD_FLEX - - YGUnit flex_basis_unit = 13; // YGUnit.YGU_UNDEFINED - float flex_basis = 14; - - float flex_grow = 15; - - YGUnit width_unit = 16; // YGUnit.YGU_UNDEFINED - float width = 17; - YGUnit height_unit = 18; // YGUnit.YGU_UNDEFINED - float height = 19; - - YGUnit min_width_unit = 20; // YGUnit.YGU_UNDEFINED - float min_width = 21; - YGUnit min_height_unit = 22; // YGUnit.YGU_UNDEFINED - float min_height = 23; - - YGUnit max_width_unit = 24; // YGUnit.YGU_UNDEFINED - float max_width = 25; - YGUnit max_height_unit = 26; // YGUnit.YGU_UNDEFINED - float max_height = 27; - - YGUnit position_left_unit = 28; // YGUnit.YGU_UNDEFINED - float position_left = 29; - YGUnit position_top_unit = 30; // YGUnit.YGU_UNDEFINED - float position_top = 31; - YGUnit position_right_unit = 32; // YGUnit.YGU_UNDEFINED - float position_right = 33; - YGUnit position_bottom_unit = 34; // YGUnit.YGU_UNDEFINED - float position_bottom = 35; - - YGUnit margin_left_unit = 36; // YGUnit.YGU_UNDEFINED - float margin_left = 37; - YGUnit margin_top_unit = 38; // YGUnit.YGU_UNDEFINED - float margin_top = 39; - YGUnit margin_right_unit = 40; // YGUnit.YGU_UNDEFINED - float margin_right = 41; - YGUnit margin_bottom_unit = 42; // YGUnit.YGU_UNDEFINED - float margin_bottom = 43; - - YGUnit padding_left_unit = 44; // YGUnit.YGU_UNDEFINED - float padding_left = 45; - YGUnit padding_top_unit = 46; // YGUnit.YGU_UNDEFINED - float padding_top = 47; - YGUnit padding_right_unit = 48; // YGUnit.YGU_UNDEFINED - float padding_right = 49; - YGUnit padding_bottom_unit = 50; // YGUnit.YGU_UNDEFINED - float padding_bottom = 51; - - optional PointerFilterMode pointer_filter = 52; // default: PointerFilterMode.PFM_NONE - - // Border Width - optional YGUnit border_left_width_unit = 53; // YGUnit.YGU_UNDEFINED - optional float border_left_width = 54; - optional YGUnit border_top_width_unit = 55; // YGUnit.YGU_UNDEFINED - optional float border_top_width = 56; - optional YGUnit border_right_width_unit = 57; // YGUnit.YGU_UNDEFINED - optional float border_right_width = 58; - optional YGUnit border_bottom_width_unit = 59; // YGUnit.YGU_UNDEFINED - optional float border_bottom_width = 60; - - // Border Radius - optional YGUnit border_top_left_radius_unit = 61; // YGUnit.YGU_UNDEFINED - optional float border_top_left_radius = 62; - optional YGUnit border_top_right_radius_unit = 63; // YGUnit.YGU_UNDEFINED - optional float border_top_right_radius = 64; - optional YGUnit border_bottom_left_radius_unit = 65; // YGUnit.YGU_UNDEFINED - optional float border_bottom_left_radius = 66; - optional YGUnit border_bottom_right_radius_unit = 67; // YGUnit.YGU_UNDEFINED - optional float border_bottom_right_radius = 68; - - // Border Color - optional decentraland.common.Color4 border_top_color = 69; - optional decentraland.common.Color4 border_bottom_color = 70; - optional decentraland.common.Color4 border_left_color = 71; - optional decentraland.common.Color4 border_right_color = 72; - - optional float opacity = 73; // default: 1 - - optional string element_id = 74; // reference for scroll_position. default empty - optional ScrollPositionValue scroll_position = 75; // default position=(0,0) - optional ShowScrollBar scroll_visible = 76; // default ShowScrollBar.SSB_BOTH - - optional int32 z_index = 77; // default 0 -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/video_event.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/video_event.proto deleted file mode 100644 index 917137f94..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/video_event.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1044; - -message PBVideoEvent { - uint32 timestamp = 1; // monotonic counter - uint32 tick_number = 2; // number of tick in which the event was produced, equals to EngineInfo.tick_number - float current_offset = 3; - float video_length = 4; - VideoState state = 5; -} - -enum VideoState { - VS_NONE = 0; - VS_ERROR = 1; - VS_LOADING = 2; - VS_READY = 3; - VS_PLAYING = 4; - VS_BUFFERING = 5; - VS_SEEKING = 6; - VS_PAUSED = 7; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/video_player.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/video_player.proto deleted file mode 100644 index 9487a820c..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/video_player.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1043; - -message PBVideoPlayer { - // which file to load - string src = 1; - - optional bool playing = 2; // default true - optional float position = 3; // default 0.0 - optional float volume = 4; // default 1.0 - optional float playback_rate = 5; // default 1.0 - optional bool loop = 6; // default false -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/virtual_camera.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/virtual_camera.proto deleted file mode 100644 index 94302069a..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/virtual_camera.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/camera_transition.proto"; -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1076; - -// PBVirtualCamera represents a camera to be used at some point in time during the scene execution -// * The defaultTransition represents the transition TOWARDS this camera. If there is none, it's treated as -// an 'instant' transition (like using speed/time = 0) -// * The lookAtEntity defines to which entity the Camera has to look at constantly (independent from -// the holding entity transform). -message PBVirtualCamera { - optional common.CameraTransition default_transition = 1; - optional uint32 look_at_entity = 2; -} \ No newline at end of file diff --git a/crates/dcl_component/src/proto/decentraland/sdk/components/visibility_component.proto b/crates/dcl_component/src/proto/decentraland/sdk/components/visibility_component.proto deleted file mode 100644 index 5b7ec8284..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/components/visibility_component.proto +++ /dev/null @@ -1,9 +0,0 @@ -syntax = "proto3"; -package decentraland.sdk.components; - -import "decentraland/sdk/components/common/id.proto"; -option (common.ecs_component_id) = 1081; - -message PBVisibilityComponent { - optional bool visible = 1; // default=true -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/development/local_development.proto b/crates/dcl_component/src/proto/decentraland/sdk/development/local_development.proto deleted file mode 100644 index 1bc903376..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/development/local_development.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.development; - -// ts code & main.crdt updates -message UpdateScene { - string scene_id = 1; -} - -enum UpdateModelType { - UMT_CHANGE = 0; - UMT_REMOVE = 1; -} - -// .glb & .gltf model udpates -message UpdateModel { - string scene_id = 1; - string src = 2; - string hash = 3; - UpdateModelType type = 4; -} - -message WsSceneMessage { - oneof message { - // direction: scene -> explorer - UpdateScene update_scene = 1; - UpdateModel update_model = 2; - } -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/ecs6/components_ecs6.proto b/crates/dcl_component/src/proto/decentraland/sdk/ecs6/components_ecs6.proto deleted file mode 100644 index 1bba4b614..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/ecs6/components_ecs6.proto +++ /dev/null @@ -1,678 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.ecs6; -import "decentraland/common/vectors.proto"; -import "decentraland/common/colors.proto"; - - -message ECS6Color4 { - float r = 1; - float g = 2; - float b = 3; - optional float a = 4; -} - -message Area { - optional decentraland.common.Vector3 box = 1; -} - -message UiValue { - optional float value = 1; - - enum UiValueType { - UVT_PERCENT = 0; - PIXELS = 1; - } - optional UiValueType type = 2; -} - -// CLASS_ID.AVATAR_MODIFIER_AREA -message ECS6ComponentAvatarModifierArea { - optional Area area = 1; - repeated string modifiers = 2; - repeated string exclude_ids = 3; -} - -// CLASS_ID.TRANSFORM -message ECS6ComponentTransform { - optional decentraland.common.Vector3 position = 1; - optional decentraland.common.Quaternion rotation = 2; - optional decentraland.common.Vector3 scale = 3; -} - - -// CLASS_ID.AVATAR_ATTACH -message ECS6ComponentAttachToAvatar { - enum AttachToAvatarAnchorPointId { - ATAAP_POSITION = 0; - ATAAP_NAME_TAG = 1; - ATAAP_LEFT_HAND = 2; - ATAAP_RIGHT_HAND = 3; - } - - optional string avatar_id = 1; - optional AttachToAvatarAnchorPointId anchor_point_id = 2; - optional string avatar_scene_id = 3; -} - -// CLASS_ID.BILLBOARD -message ECS6ComponentBillboard { - optional bool x = 1; - optional bool y = 2; - optional bool z = 3; -} - -// CLASS_ID.BOX_SHAPE -message ECS6ComponentBoxShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - repeated float uvs = 4; -} - -// CLASS_ID.SPHERE_SHAPE -message ECS6ComponentSphereShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; -} - -// CLASS_ID.CIRCLE_SHAPE -message ECS6ComponentCircleShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - optional float segments = 4; - optional float arc = 5; -} - - -// CLASS_ID.PLANE_SHAPE -message ECS6ComponentPlaneShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - repeated float uvs = 4; - optional float width = 6; - optional float height = 7; -} - - -// CLASS_ID.CONE_SHAPE -message ECS6ComponentConeShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - optional float radius_top = 4; - optional float radius_bottom = 5; - optional float segments_height = 6; - optional float segments_radial = 7; - optional bool open_ended = 8; - optional float radius = 9; - optional float arc = 10; -} - -// CLASS_ID.CYLINDER_SHAPE -message ECS6ComponentCylinderShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - optional float radius_top = 4; - optional float radius_bottom = 5; - optional float segments_height = 6; - optional float segments_radial = 7; - optional bool open_ended = 8; - optional float radius = 9; - optional float arc = 10; -} - - -// CLASS_ID.GLTF_SHAPE -message ECS6ComponentGltfShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - optional string src = 4; -} - - -// CLASS_ID.NFT_SHAPE -message ECS6ComponentNftShape { - enum PictureFrameStyle { - PFS_CLASSIC = 0; - PFS_BAROQUE_ORNAMENT = 1; - PFS_DIAMOND_ORNAMENT = 2; - PFS_MINIMAL_WIDE = 3; - PFS_MINIMAL_GREY = 4; - PFS_BLOCKY = 5; - PFS_GOLD_EDGES = 6; - PFS_GOLD_CARVED = 7; - PFS_GOLD_WIDE = 8; - PFS_GOLD_ROUNDED = 9; - PFS_METAL_MEDIUM = 10; - PFS_METAL_WIDE = 11; - PFS_METAL_SLIM = 12; - PFS_METAL_ROUNDED = 13; - PFS_PINS = 14; - PFS_MINIMAL_BLACK = 15; - PFS_MINIMAL_WHITE = 16; - PFS_TAPE = 17; - PFS_WOOD_SLIM = 18; - PFS_WOOD_WIDE = 19; - PFS_WOOD_TWIGS = 20; - PFS_CANVAS = 21; - PFS_NONE = 22; - } - - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - optional string src = 4; - optional PictureFrameStyle style = 5; - optional decentraland.common.Color3 color = 6; -} - - -// CLASS_ID.TEXTURE -message ECS6ComponentTexture { - optional string src = 1; - optional int32 sampling_mode = 2; - optional int32 wrap = 3; - optional bool has_alpha = 4; -} - - -// CLASS_ID.ANIMATION -message ECS6ComponentAnimator { - message AnimationState { - optional string clip = 1; - optional bool looping = 2; - optional float weight = 3; - optional bool playing = 4; - optional bool should_reset = 5; - optional float speed = 6; - optional string name = 7; - } - - repeated AnimationState states = 1; -} - -// CLASS_ID.OBJ_SHAPE -message ECS6ComponentObjShape { - optional bool with_collisions = 1; - optional bool is_pointer_blocker = 2; - optional bool visible = 3; - optional string src = 4; -} - - - -// CLASS_ID.FONT -message ECS6ComponentFont { - optional string src = 1; -} - -// CLASS_ID.TEXT_SHAPE -message ECS6ComponentTextShape { - optional float outline_width = 1; - optional decentraland.common.Color3 outline_color = 2; - optional decentraland.common.Color3 color = 3; - optional float font_size = 4; - optional string font = 5; - optional float opacity = 6; - optional string value = 7; - optional string line_spacing = 8; - optional int32 line_count = 9; - optional bool text_wrapping = 10; - optional float shadow_blur = 11; - optional float shadow_offset_x = 12; - optional float shadow_offset_y = 13; - optional decentraland.common.Color3 shadow_color = 14; - optional string h_text_align = 15; - optional string v_text_align = 16; - optional float width = 17; - optional float height = 18; - optional float padding_top = 19; - optional float padding_right = 20; - optional float padding_bottom = 21; - optional float padding_left = 22; - optional bool billboard = 23; - optional bool visible = 24; -} - - -// CLASS_ID.PBR_MATERIAL -message ECS6ComponentMaterial { - optional float alpha_test = 1; - optional ECS6Color4 albedo_color = 2; - optional decentraland.common.Color3 emissive_color = 3; - optional float metallic = 4; - optional float roughness = 5; - optional decentraland.common.Color3 reflectivity_color = 6; - optional float direct_intensity = 7; - optional float micro_surface = 8; - optional float emissive_intensity = 9; - optional float specular_intensity = 10; - optional string albedo_texture = 11; - optional string alpha_texture = 12; - optional string emissive_texture = 13; - optional string bump_texture = 14; - optional float transparency_mode = 15; - optional bool cast_shadows = 16; -} - -// CLASS_ID.BASIC_MATERIAL -message ECS6ComponentBasicMaterial { - optional float alpha_test = 1; - optional string texture = 2; - optional bool cast_shadows = 3; -} - -// CLASS_ID.UUID_CALLBACK -message ECS6ComponentUuidCallback { - optional string button = 1; - optional string hover_text = 2; - optional float distance = 3; - optional bool show_feedback = 4; - optional string type = 5; - optional string uuid = 6; -} - -// CLASS_ID.SMART_ITEM) -message ECS6ComponentSmartItem {} - -// CLASS_ID.VIDEO_CLIP -message ECS6ComponentVideoClip { - optional string url = 1; -} - -// CLASS_ID.VIDEO_TEXTURE -message ECS6ComponentVideoTexture { - enum VideoStatus { - NONE = 0; - ERROR = 1; - LOADING = 2; - READY = 3; - PLAYING = 4; - BUFFERING = 5; - } - - optional int32 sampling_mode = 1; - optional int32 wrap = 2; - optional float volume = 3; - optional float playback_rate = 4; - optional float seek = 5; - optional bool playing = 6; - optional bool loop = 7; - optional string video_clip_id = 8; -} - - -// CLASS_ID.CAMERA_MODE_AREA -message ECS6ComponentCameraModeArea { - enum CameraMode { - CM_FIRST_PERSON = 0; - CM_THIRD_PERSON = 1; - CM_BUILDING_TOOL_GOD_MODE = 2; - } - - Area area = 1; - CameraMode camera_mode = 2; -} - -// CLASS_ID.AVATAR_TEXTURE -message ECS6ComponentAvatarTexture { - optional int32 sampling_mode = 1; - optional int32 wrap = 2; - optional bool has_alpha = 3; - optional string user_id = 4; -} - -// CLASS_ID.AUDIO_CLIP -message ECS6ComponentAudioClip { - optional string url = 1; - optional bool loop = 2; - optional string loading_complete_event_id = 3; - optional float volume = 4; -} - -// CLASS_ID.AUDIO_SOURCE -message ECS6ComponentAudioSource { - optional string audio_clip_id = 1; - optional bool loop = 2; - optional float volume = 3; - optional bool playing = 4; - optional float pitch = 5; - optional int32 played_at_timestamp = 6; -} - -// CLASS_ID.AUDIO_STREAM -message ECS6ComponentAudioStream { - optional string url = 1; - optional bool playing = 2; - optional float volume = 3; -} - -// CLASS_ID.AVATAR_SHAPE -message ECS6ComponentAvatarShape { - optional string id = 1; - optional string name = 2; - optional string expression_trigger_id = 3; - optional int64 expression_trigger_timestamp = 4; - optional string body_shape = 5; - repeated string wearables = 6; - - message Emote { - optional int32 slot = 1; - optional string urn = 2; - } - - repeated Emote emotes = 7; - optional ECS6Color4 skin_color = 8; - optional ECS6Color4 hair_color = 9; - optional ECS6Color4 eye_color = 10; - optional bool use_dummy_model = 11; - optional bool talking = 12; -} - -// CLASS_ID.GIZMOS -message ECS6ComponentGizmos { - optional bool position = 1; - optional bool rotation = 2; - optional bool scale = 3; - optional bool cycle = 4; - optional string selected_gizmo = 5; - optional bool local_reference = 6; -} - -// NO CLASS -message ECS6ComponentUiShape { - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 11; -} - -// CLASS_ID.UI_CONTAINER_RECT -message ECS6ComponentUiContainerRect { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 14; - // UiShape - optional float thickness = 11; - optional ECS6Color4 color = 12; - optional bool alignment_uses_size = 13; -} - -// CLASS_ID.UI_CONTAINER_STACK -message ECS6ComponentUiContainerStack { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 16; - // UiShape - - optional bool adapt_width = 11; - optional bool adapt_height = 12; - optional ECS6Color4 color = 13; - - enum UIStackOrientation { - VERTICAL = 0; - HORIZONTAL = 1; - } - optional UIStackOrientation stack_orientation = 14; - optional float spacing = 15; -} - -// CLASS_ID.UI_BUTTON_SHAPE -message ECS6ComponentUiButton { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 26; - // UiShape - - optional float font_size = 11; - optional string font_weight = 12; - optional float thickness = 13; - optional float corner_radius = 14; - optional ECS6Color4 color = 15; - optional ECS6Color4 background = 16; - optional float padding_top = 17; - optional float padding_right = 18; - optional float padding_bottom = 19; - optional float padding_left = 20; - optional float shadow_blur = 21; - optional float shadow_offset_x = 22; - optional float shadow_offset_y = 23; - optional ECS6Color4 shadow_color = 24; - optional string text = 25; -} - -// CLASS_ID.UI_TEXT_SHAPE -message ECS6ComponentUiText { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 33; - // UiShape - - optional float outline_width = 11; - optional ECS6Color4 outline_color = 12; - optional ECS6Color4 color = 13; - optional float font_size = 14; - optional bool font_auto_size = 15; - optional string font = 16; - optional string value = 17; - optional float line_spacing = 18; - optional int32 line_count = 19; - optional bool adapt_width = 20; - optional bool adapt_height = 21; - optional bool text_wrapping = 22; - optional float shadow_blur = 23; - optional float shadow_offset_x = 24; - optional float shadow_offset_y = 25; - optional ECS6Color4 shadow_color = 26; - optional string h_text_align = 27; - optional string v_text_align = 28; - optional float padding_top = 29; - optional float padding_right = 30; - optional float padding_bottom = 31; - optional float padding_left = 32; -} - -// CLASS_ID.UI_INPUT_TEXT_SHAPE -message ECS6ComponentUiInputText { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 39; - // UiShape - - optional float outline_width = 11; - optional ECS6Color4 outline_color = 12; - optional ECS6Color4 color = 13; - optional float font_size = 14; - optional string font = 16; - optional string value = 17; - - optional string placeholder = 33; - optional float margin = 34; - optional ECS6Color4 focused_background = 35; - - optional bool text_wrapping = 22; - optional float shadow_blur = 23; - optional float shadow_offset_x = 24; - optional float shadow_offset_y = 25; - optional ECS6Color4 shadow_color = 26; - optional string h_text_align = 27; - optional string v_text_align = 28; - optional float padding_top = 29; - optional float padding_right = 30; - optional float padding_bottom = 31; - optional float padding_left = 32; - - optional string on_text_changed = 36; - optional string on_focus = 37; - optional string on_blur = 38; - optional string on_text_submit = 40; - optional string on_changed = 41; -} - -// CLASS_ID.UI_IMAGE_SHAPE -message ECS6ComponentUiImage { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 22; - // UiShape - - optional float source_left = 11; - optional float source_top = 12; - optional float source_width = 13; - optional float source_height = 14; - optional string source = 15; - optional float padding_top = 16; - optional float padding_right = 17; - optional float padding_bottom = 18; - optional float padding_left = 19; - optional bool size_in_pixels = 20; - - optional string on_click = 21; -} - -// CLASS_ID.UI_SLIDER_SHAPE -message ECS6ComponentUiScrollRect { - // UiShape - optional string name = 11; - optional bool visible = 12; - optional float opacity = 13; - optional string h_align = 14; - optional string v_align = 15; - optional UiValue width = 16; - optional UiValue height = 17; - optional UiValue position_x = 18; - optional UiValue position_y = 19; - optional bool is_pointer_blocker = 20; - optional string parent_component = 21; - // UiShape - - optional float value_x = 1; - optional float value_y = 2; - optional ECS6Color4 background_color = 3; - optional bool is_horizontal = 4; - optional bool is_vertical = 5; - optional float padding_top = 6; - optional float padding_right = 7; - optional float padding_bottom = 8; - optional float padding_left = 9; - - optional string on_changed = 10; -} - -// CLASS_ID.UI_WORLD_SPACE_SHAPE -message ECS6ComponentUiWorldSpaceShape { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 11; - // UiShape -} - -// CLASS_ID.UI_SCREEN_SPACE_SHAPE -message ECS6ComponentUiScreenSpaceShape { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 11; - // UiShape -} - -// CLASS_ID.UI_FULLSCREEN_SHAPE -message ECS6ComponentUiFullScreenShape { - // UiShape - optional string name = 1; - optional bool visible = 2; - optional float opacity = 3; - optional string h_align = 4; - optional string v_align = 5; - optional UiValue width = 6; - optional UiValue height = 7; - optional UiValue position_x = 8; - optional UiValue position_y = 9; - optional bool is_pointer_blocker = 10; - optional string parent_component = 11; - // UiShape -} diff --git a/crates/dcl_component/src/proto/decentraland/sdk/ecs6/engine_interface_ecs6.proto b/crates/dcl_component/src/proto/decentraland/sdk/ecs6/engine_interface_ecs6.proto deleted file mode 100644 index 164060408..000000000 --- a/crates/dcl_component/src/proto/decentraland/sdk/ecs6/engine_interface_ecs6.proto +++ /dev/null @@ -1,151 +0,0 @@ -syntax = "proto3"; - -package decentraland.sdk.ecs6; - -import "decentraland/common/vectors.proto"; -import "decentraland/sdk/ecs6/components_ecs6.proto"; - -message OpenExternalUrlBody { - string url = 1; -} - -message OpenNFTDialogBody { - string asset_contract_address = 1; - string token_id = 2; - optional string comment = 3; -} - -message ComponentBodyPayload { - oneof payload { - decentraland.sdk.ecs6.ECS6ComponentAvatarModifierArea avatar_modifier_area = 1; - decentraland.sdk.ecs6.ECS6ComponentTransform transform = 2; - decentraland.sdk.ecs6.ECS6ComponentAttachToAvatar attach_to_avatar = 3; - decentraland.sdk.ecs6.ECS6ComponentBillboard billboard = 4; - decentraland.sdk.ecs6.ECS6ComponentBoxShape box_shape = 5; - decentraland.sdk.ecs6.ECS6ComponentSphereShape sphere_shape = 6; - decentraland.sdk.ecs6.ECS6ComponentCircleShape circle_shape = 7; - decentraland.sdk.ecs6.ECS6ComponentPlaneShape plane_shape = 8; - decentraland.sdk.ecs6.ECS6ComponentConeShape cone_shape = 9; - decentraland.sdk.ecs6.ECS6ComponentCylinderShape cylinder_shape = 10; - decentraland.sdk.ecs6.ECS6ComponentGltfShape gltf_shape = 11; - decentraland.sdk.ecs6.ECS6ComponentNftShape nft_shape = 12; - decentraland.sdk.ecs6.ECS6ComponentTexture texture = 13; - decentraland.sdk.ecs6.ECS6ComponentAnimator animator = 14; - decentraland.sdk.ecs6.ECS6ComponentObjShape obj_shape = 15; - decentraland.sdk.ecs6.ECS6ComponentFont font = 16; - decentraland.sdk.ecs6.ECS6ComponentTextShape text_shape = 17; - decentraland.sdk.ecs6.ECS6ComponentMaterial material = 18; - decentraland.sdk.ecs6.ECS6ComponentBasicMaterial basic_material = 19; - decentraland.sdk.ecs6.ECS6ComponentUuidCallback uuid_callback = 20; - decentraland.sdk.ecs6.ECS6ComponentSmartItem smart_item = 21; - decentraland.sdk.ecs6.ECS6ComponentVideoClip video_clip = 22; - decentraland.sdk.ecs6.ECS6ComponentVideoTexture video_texture = 23; - decentraland.sdk.ecs6.ECS6ComponentCameraModeArea camera_mode_area = 24; - decentraland.sdk.ecs6.ECS6ComponentAvatarTexture avatar_texture = 25; - decentraland.sdk.ecs6.ECS6ComponentAudioClip audio_clip = 26; - decentraland.sdk.ecs6.ECS6ComponentAudioSource audio_source = 27; - decentraland.sdk.ecs6.ECS6ComponentAudioStream audio_stream = 28; - decentraland.sdk.ecs6.ECS6ComponentAvatarShape avatar_shape = 29; - decentraland.sdk.ecs6.ECS6ComponentGizmos gizmos = 30; - decentraland.sdk.ecs6.ECS6ComponentUiShape ui_shape = 31; - decentraland.sdk.ecs6.ECS6ComponentUiContainerRect ui_container_rect = 32; - decentraland.sdk.ecs6.ECS6ComponentUiContainerStack ui_container_stack = 33; - decentraland.sdk.ecs6.ECS6ComponentUiButton ui_button = 34; - decentraland.sdk.ecs6.ECS6ComponentUiText ui_text = 35; - decentraland.sdk.ecs6.ECS6ComponentUiInputText ui_input_text = 36; - decentraland.sdk.ecs6.ECS6ComponentUiImage ui_image = 37; - decentraland.sdk.ecs6.ECS6ComponentUiScrollRect ui_scroll_rect = 38; - decentraland.sdk.ecs6.ECS6ComponentUiWorldSpaceShape ui_world_space_shape = 39; - decentraland.sdk.ecs6.ECS6ComponentUiScreenSpaceShape ui_screen_space_shape = 40; - decentraland.sdk.ecs6.ECS6ComponentUiFullScreenShape ui_full_screen_shape = 41; - } -} - -message CreateEntityBody { - string id = 1; -} - -message RemoveEntityBody { - string id = 1; -} - -message UpdateEntityComponentBody { - string entity_id = 1; - int32 class_id = 2; - string name = 3; - ComponentBodyPayload component_data = 4; -} - -message AttachEntityComponentBody { - string entity_id = 1; - string name = 2; - string id = 3; -} - -message ComponentRemovedBody { - string entity_id = 1; - string name = 2; -} - -message SetEntityParentBody { - string entity_id = 1; - string parent_id = 2; -} - -message QueryBody { - string query_id = 1; - - message Ray { - decentraland.common.Vector3 origin = 1; - decentraland.common.Vector3 direction = 2; - float distance = 3; - } - - message RayQuery { - string query_id = 1; - string query_type = 2; - Ray ray = 3; - } - - RayQuery payload = 2; -} - -message ComponentCreatedBody { - string id = 1; - int32 class_id = 2; - string name = 3; -} - -message ComponentDisposedBody { - string id = 1; -} - -message ComponentUpdatedBody { - string id = 1; - ComponentBodyPayload component_data = 2; -} - -message InitMessagesFinishedBody {} - -message EntityActionPayload { - oneof payload { - OpenExternalUrlBody open_external_url = 1; - OpenNFTDialogBody open_nft_dialog = 2; - CreateEntityBody create_entity = 3; - RemoveEntityBody remove_entity = 4; - UpdateEntityComponentBody update_entity_component = 5; - AttachEntityComponentBody attach_entity_component = 6; - ComponentRemovedBody component_removed = 7; - SetEntityParentBody set_entity_parent = 8; - QueryBody query = 9; - ComponentCreatedBody component_created = 10; - ComponentDisposedBody component_disposed = 11; - ComponentUpdatedBody component_updated = 12; - InitMessagesFinishedBody init_messages_finished = 13; - } -} - -message EntityAction { - optional string tag = 2; - EntityActionPayload payload = 3; -} diff --git a/crates/dcl_component/src/proto/decentraland/social/friendships/friendships.proto b/crates/dcl_component/src/proto/decentraland/social/friendships/friendships.proto deleted file mode 100644 index 238e8516f..000000000 --- a/crates/dcl_component/src/proto/decentraland/social/friendships/friendships.proto +++ /dev/null @@ -1,162 +0,0 @@ -syntax = "proto3"; -package decentraland.social.friendships; - -// This message is a response that is sent from the server to the client -message FriendshipEventResponse { - oneof body { - RequestResponse request = 1; - AcceptResponse accept = 2; - RejectResponse reject = 4; - DeleteResponse delete = 5; - CancelResponse cancel = 6; - } -} - -message FriendshipEventResponses { - repeated FriendshipEventResponse responses = 1; -} - -message FriendshipEventPayload { - oneof body { - RequestPayload request = 1; - AcceptPayload accept = 2; - RejectPayload reject = 4; - DeletePayload delete = 5; - CancelPayload cancel = 6; - } -} - -message User { string address = 1; } - -message Users { repeated User users = 1; } - -message RequestResponse { - User user = 1; - int64 created_at = 2; - optional string message = 3; -} - -message RequestPayload { - User user = 1; - optional string message = 3; -} - -message Requests { - int64 total = 1; // Total amount of friendship requests - repeated RequestResponse items = 2; -} - -message RequestEvents { - Requests outgoing = 1; // Requests the authed user have sent to users - Requests incoming = 2; // Requests the authed user have received from users -} - -message AcceptResponse { User user = 1; } - -message AcceptPayload { User user = 1; } - -message RejectResponse { User user = 1; } - -message RejectPayload { User user = 1; } - -message DeleteResponse { User user = 1; } - -message DeletePayload { User user = 1; } - -message CancelResponse { User user = 1; } - -message CancelPayload { User user = 1; } - -message UpdateFriendshipPayload { - FriendshipEventPayload event = 1; - // For internal use only, subject to change. - optional Payload auth_token = 2; -} - -message MutualFriendsPayload { - User user = 1; - // For internal use only, subject to change. - optional Payload auth_token = 2; -} - -message Payload { - // For internal use only, subject to change. - optional string synapse_token = 1; -} - -message BadRequestError { - string message = 1; -} -message UnauthorizedError { - string message = 1; -} -message ForbiddenError { - string message = 1; -} -message TooManyRequestsError { - string message = 1; -} -message InternalServerError { - string message = 1; -} - -message UsersResponse { - oneof response { - Users users = 1; - InternalServerError internal_server_error = 2; - UnauthorizedError unauthorized_error = 3; - ForbiddenError forbidden_error = 4; - TooManyRequestsError too_many_requests_error = 5; - BadRequestError bad_request_error = 6; - } -} - -message RequestEventsResponse { - oneof response { - RequestEvents events = 1; - InternalServerError internal_server_error = 2; - UnauthorizedError unauthorized_error = 3; - ForbiddenError forbidden_error = 4; - TooManyRequestsError too_many_requests_error = 5; - } -} - -message UpdateFriendshipResponse { - oneof response { - FriendshipEventResponse event = 1; - InternalServerError internal_server_error = 2; - UnauthorizedError unauthorized_error = 3; - ForbiddenError forbidden_error = 4; - TooManyRequestsError too_many_requests_error = 5; - BadRequestError bad_request_error = 6; - } -} - -message SubscribeFriendshipEventsUpdatesResponse { - oneof response { - FriendshipEventResponses events = 1; - InternalServerError internal_server_error = 2; - UnauthorizedError unauthorized_error = 3; - ForbiddenError forbidden_error = 4; - TooManyRequestsError too_many_requests_error = 5; - } -} - -service FriendshipsService { - // Get the list of friends for the authenticated user - rpc GetFriends(Payload) returns (stream UsersResponse) {} - - // Get the list of mutual friends between the authenticated user and the one in the parameter - rpc GetMutualFriends(MutualFriendsPayload) returns (stream UsersResponse) {} - - // Get the list of request events for the authenticated user - rpc GetRequestEvents(Payload) returns (RequestEventsResponse) {} - - // Update friendship status: REQUEST, ACCEPT, REJECT, CANCEL, DELETE - rpc UpdateFriendshipEvent(UpdateFriendshipPayload) - returns (UpdateFriendshipResponse) {} - - // Subscribe to updates of friendship status: REQUEST, ACCEPT, REJECT, CANCEL, DELETE - rpc SubscribeFriendshipEventsUpdates(Payload) - returns (stream SubscribeFriendshipEventsUpdatesResponse) {} -} diff --git a/crates/dcl_component/src/proto/decentraland/social_service_v2/social_service.proto b/crates/dcl_component/src/proto/decentraland/social_service_v2/social_service.proto deleted file mode 100644 index 4c0a575ee..000000000 --- a/crates/dcl_component/src/proto/decentraland/social_service_v2/social_service.proto +++ /dev/null @@ -1,111 +0,0 @@ -syntax = "proto3"; -package decentraland.social_service_v2; - -import "google/protobuf/empty.proto"; - -// Errors - -message InvalidFriendshipAction {} - -message InternalServerError {} - -// Types - -message User { string address = 1; } - -message RequestResponse { - User user = 1; - int64 created_at = 2; - optional string message = 3; -} - -message RequestPayload { - User user = 1; - optional string message = 3; -} - -message Requests { - repeated RequestResponse requests = 1; -} - -message AcceptResponse { User user = 1; } - -message AcceptPayload { User user = 1; } - -message RejectResponse { User user = 1; } - -message RejectPayload { User user = 1; } - -message DeleteResponse { User user = 1; } - -message DeletePayload { User user = 1; } - -message CancelResponse { User user = 1; } - -message CancelPayload { User user = 1; } - -message UpsertFriendshipPayload { - oneof action { - RequestPayload request = 1; - AcceptPayload accept = 2; - RejectPayload reject = 4; - DeletePayload delete = 5; - CancelPayload cancel = 6; - } -} - -message MutualFriendsPayload { - User user = 1; -} - -message UsersResponse { - repeated User users = 1; -} - -message FriendshipRequestsResponse { - oneof response { - Requests requests = 1; - InternalServerError internal_server_error = 2; - } -} - -message UpsertFriendshipResponse { - message Accepted {} - oneof response { - Accepted accepted = 1; - InvalidFriendshipAction invalid_friendship_action = 2; - InternalServerError internal_server_error = 3; - } -} - -message FriendshipUpdate { - oneof update { - RequestResponse request = 1; - AcceptResponse accept = 2; - RejectResponse reject = 4; - DeleteResponse delete = 5; - CancelResponse cancel = 6; - } -} - -service SocialService { - // Get the list of friends for the authenticated user - rpc GetFriends(google.protobuf.Empty) returns (stream UsersResponse) {} - - // Get the list of mutual friends between the authenticated user and the one in the parameter - rpc GetMutualFriends(MutualFriendsPayload) returns (stream UsersResponse) {} - - // Get the pending friendship requests for the authenticated user - rpc GetPendingFriendshipRequests(google.protobuf.Empty) returns (FriendshipRequestsResponse) {} - - // Get the sent friendship requests for the authenticated user - rpc GetSentFriendshipRequests(google.protobuf.Empty) returns (FriendshipRequestsResponse) {} - - // Create or update friendship status: REQUEST, ACCEPT, REJECT, CANCEL, DELETE - rpc UpsertFriendship(UpsertFriendshipPayload) - returns (UpsertFriendshipResponse) {} - - // Subscribe to updates of friendship status: REQUEST, ACCEPT, REJECT, CANCEL, DELETE - rpc SubscribeToFriendshipUpdates(google.protobuf.Empty) - returns (stream FriendshipUpdate) {} -} diff --git a/crates/dcl_component/src/proto_components.rs b/crates/dcl_component/src/proto_components.rs index 2f91965b2..d0f5755d8 100644 --- a/crates/dcl_component/src/proto_components.rs +++ b/crates/dcl_component/src/proto_components.rs @@ -45,7 +45,7 @@ pub mod common { pub mod social { include!(concat!( env!("OUT_DIR"), - "/decentraland.social.friendships.rs" + "/decentraland.social_service.v1.rs" )); } diff --git a/protocol b/protocol new file mode 160000 index 000000000..14f756d2b --- /dev/null +++ b/protocol @@ -0,0 +1 @@ +Subproject commit 14f756d2b9a3db444cddd2b29118956368906b75