diff --git a/.gitignore b/.gitignore index cf4e96af..d314a4e8 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,5 @@ node_modules package-lock.json .DS_Store out-* -proto/google \ No newline at end of file +proto/google +.idea \ No newline at end of file diff --git a/proto/decentraland/kernel/apis/comms_api.proto b/proto/decentraland/kernel/apis/comms_api.proto index 4288fe71..0f1b1ec9 100644 --- a/proto/decentraland/kernel/apis/comms_api.proto +++ b/proto/decentraland/kernel/apis/comms_api.proto @@ -20,6 +20,42 @@ message VideoTracksActiveStreamsData { VideoTrackSourceType source_type = 3; } +message SubscribeToTopicRequest { + string topic = 1; +} + +message SubscribeToTopicResponse {} + +message UnsubscribeFromTopicRequest { + string topic = 1; +} + +message UnsubscribeFromTopicResponse {} + +message PublishDataRequest { + string topic = 1; + string data = 2; +} + +message PublishDataResponse {} + +message ConsumeMessagesRequest { + string topic = 1; +} + +message ConsumeMessages { + string sender = 1; + string data = 2; +} + +message ConsumeMessagesResponse { + repeated ConsumeMessages messages = 1; +} + service CommsApiService { rpc GetActiveVideoStreams(VideoTracksActiveStreamsRequest) returns (VideoTracksActiveStreamsResponse) {} -} \ No newline at end of file + rpc SubscribeToTopic(SubscribeToTopicRequest) returns (SubscribeToTopicResponse) {} + rpc UnsubscribeFromTopic(UnsubscribeFromTopicRequest) returns (UnsubscribeFromTopicResponse) {} + rpc PublishData(PublishDataRequest) returns (PublishDataResponse) {} + rpc ConsumeMessages(ConsumeMessagesRequest) returns (ConsumeMessagesResponse) {} +} diff --git a/proto/decentraland/kernel/comms/rfc4/comms.proto b/proto/decentraland/kernel/comms/rfc4/comms.proto index ad864959..66427042 100644 --- a/proto/decentraland/kernel/comms/rfc4/comms.proto +++ b/proto/decentraland/kernel/comms/rfc4/comms.proto @@ -18,6 +18,9 @@ message Packet { PlayerEmote player_emote = 9; SceneEmote scene_emote = 10; MovementCompressed movement_compressed = 12; + LookAtPosition look_at_position = 13; + Reaction reaction = 14; + ChatReaction chat_reaction = 15; } uint32 protocol_version = 11; } @@ -138,3 +141,25 @@ message Voice { VC_OPUS = 0; } } + +// Message sent to force an avatar to look at a position +message LookAtPosition { + float timestamp = 1; + // world position + float position_x = 2; + float position_y = 3; + float position_z = 4; + string target_avatar_wallet_address = 5; +} + +message Reaction { + int32 emoji_index = 1; + float timestamp = 2; + int32 count = 3; +} + +message ChatReaction { + int32 emoji_index = 1; + string message_id = 2; + string address = 3; +} diff --git a/proto/decentraland/sdk/components/audio_analysis.proto b/proto/decentraland/sdk/components/audio_analysis.proto new file mode 100644 index 00000000..940f18af --- /dev/null +++ b/proto/decentraland/sdk/components/audio_analysis.proto @@ -0,0 +1,44 @@ +syntax = "proto3"; +package decentraland.sdk.components; + +import "decentraland/sdk/components/common/id.proto"; +option (common.ecs_component_id) = 1212; + +enum PBAudioAnalysisMode { + MODE_RAW = 0; + MODE_LOGARITHMIC = 1; +} + +message PBAudioAnalysis { + + // Parameters section + PBAudioAnalysisMode mode = 1; + + // Used only when mode == MODE_LOGARITHMIC + optional float amplitude_gain = 100; + optional float bands_gain = 101; + // End when mode == MODE_LOGARITHMIC + + // End Parameters section + + // Result section + float amplitude = 200; + + // Protobuf doesn't support fixed arrays -> 8 band fields + float band_0 = 201; + float band_1 = 202; + float band_2 = 203; + float band_3 = 204; + float band_4 = 205; + float band_5 = 206; + float band_6 = 207; + float band_7 = 208; + + // End Result section + + // Future fields + // float spectral_centroid = 13; + // float spectral_flux = 14; + // bool onset = 15; + // float bpm = 16; +} diff --git a/proto/decentraland/sdk/components/common/input_action.proto b/proto/decentraland/sdk/components/common/input_action.proto index 617f45b1..7ad11de0 100644 --- a/proto/decentraland/sdk/components/common/input_action.proto +++ b/proto/decentraland/sdk/components/common/input_action.proto @@ -17,6 +17,7 @@ enum InputAction { IA_ACTION_4 = 11; IA_ACTION_5 = 12; IA_ACTION_6 = 13; + // Modifier key (Shift on desktop) IA_MODIFIER = 14; } diff --git a/proto/decentraland/sdk/components/particle_system.proto b/proto/decentraland/sdk/components/particle_system.proto index 5d59d236..61ade1ae 100644 --- a/proto/decentraland/sdk/components/particle_system.proto +++ b/proto/decentraland/sdk/components/particle_system.proto @@ -65,7 +65,7 @@ message PBParticleSystem { optional PlaybackState playback_state = 22; // default = PS_PLAYING // --- Emission Bursts --- - repeated Burst bursts = 29; + optional BurstConfiguration bursts = 29; // ---- Nested types ---- @@ -102,6 +102,10 @@ message PBParticleSystem { } // Emission burst configuration. + message BurstConfiguration { + repeated Burst values = 1; + } + message Burst { float time = 1; // Seconds from start of cycle. uint32 count = 2; // Particles to emit.