> For the complete documentation index, see [llms.txt](https://docs.decentraland.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.decentraland.org/contributor/contributor-ko/communications/overview.md).

# 개요

Decentraland 통신 시스템, 또는 간단히 *comms*,는 렐름 내 플레이어 간 상호작용을 처리하는 실시간 메시징 프로토콜입니다.

이러한 상호작용 중 일부는 플레이어가 시작하고, 다른 일부는 클라이언트가 내부적으로 자동 처리합니다. 몇 가지 예:

* 텍스트 및 음성 채팅
* 플레이어가 이동할 때 위치 업데이트
* 플레이어가 외형을 바꿀 때 아바타 업데이트

{% hint style="info" %}
오픈소스 [Comms Station](https://decentraland.github.io/comms-station/).
{% endhint %}

이 기능의 대부분은 주변의 모든 플레이어에게 메시지를 브로드캐스트해야 하므로, 이들은 자동으로 거리 기반 클러스터로 묶이며 이를 *섬*. 각 플레이어는 한 번에 하나의 섬에 배정되며, 월드를 이동하고 다른 플레이어와의 상대적 위치가 변함에 따라 바뀝니다.

플레이어를 섬에 관리하고 배정하는 렐름 서비스는 *Archipelago*. 필요할 때 섬을 생성하고, 인구 수를 적절한 수준으로 유지하며, 플레이어의 이동에 따라 동적으로 재배정합니다.

{% @mermaid/diagram content="flowchart LR
subgraph Realm
Players\["Players<br/>⭐⭐⭐⭐⭐⭐⭐⭐⭐"]
Archipelago\["Archipelago"]

```
    subgraph Islands
        Island1["Island 1<br/>⭐⭐⭐⭐"]
        Island2["Island 2<br/>⭐⭐⚪⚪"]
        IslandN["Island n<br/>⭐⭐⭐⚪"]
    end
    
    Players --> Archipelago
    Archipelago --> Island1
    Archipelago --> Island2
    Archipelago --> IslandN
end" %}
```

섬에 배정되면 클라이언트는 서로 간의 메시지를 중계할 실제 백엔드에 연결하기 위한 섬별 URI를 받습니다. 이 연결은 Archipelago가 클라이언트를 다른 섬으로 재배정할 때까지 유지됩니다.

이는 [Archipelago](https://github.com/decentraland/docs/blob/main/contributor/communications/archipelago/README.md) 프로토콜 외에도 클라이언트는 여러 개의 *전송 방식*, 각각이 지원되는 백엔드 중 하나를 하나의 통합 인터페이스로 감쌉니다.

### 클라이언트 수명 주기 <a href="#lifecycle" id="lifecycle"></a>

comms 클라이언트의 수명 주기는 몇 단계로 요약할 수 있습니다:

1. **렐름 선택**: ...의 URI를 획득 [Archipelago](https://github.com/decentraland/docs/blob/main/contributor/communications/archipelago/README.md) 서비스.
2. **Archipelago에 참여**: 서비스와 영구 연결을 엽니다.
3. **섬 (재)배정 받기**: 현재 위치를 보고하고 섬별 URI를 획득합니다.
4. **전송 방식 연결**: 섬별 백엔드에 두 번째 연결을 엽니다.
5. **반복**: 3단계와 4단계를 계속 반복하며, 주기적으로 새로운 위치를 보고합니다.

클라이언트가 세션을 종료하면, 단순히 Archipelago 서비스에서 연결을 끊습니다. 그러면 현재 섬에서 자동으로 제거됩니다.

{% @mermaid/diagram content="sequenceDiagram
participant Archipelago
participant Client
participant IslandBackend as Island Backend

```
Note over Client: Connect to Archipelago
Client->>Archipelago: Authenticate
Archipelago->>Client: Accept

Note over Client: Report position
Client->>Archipelago: Report position
Archipelago->>Client: Assign island

Note over Client: Connect to island
Client->>IslandBackend: Connect transport
Client->>IslandBackend: Authenticate
IslandBackend->>Client: Accept

Note over Client,IslandBackend: Exchange messages
Client->>IslandBackend: Player messages…
IslandBackend->>Client: Player messages…

Note over Client: Update position
Client->>Archipelago: Update position
Archipelago->>Client: Reassign island

Note over Client: Disconnect from old island
Client->>IslandBackend: Disconnect transport

Note over Archipelago,IslandBackend: Repeat cycle" %}
```

### 연결

Comms 연결은 주로 웹소켓 기반이지만, 일부 전송 방식은 다른 전략을 사용할 수 있습니다.

다음으로 이동: [전송 방식](https://github.com/decentraland/docs/blob/main/contributor/communications/transports/README.md) 또는 [Archipelago](https://github.com/decentraland/docs/blob/main/contributor/communications/archipelago/README.md) 섹션에서 더 자세히 알아보거나, 특정 전송 방식 페이지에서 세부 정보를 확인하세요.

### 인증

comms 연결은 클라이언트가 서버가 제공한 챌린지에 서명하도록 하여 인증되며, 이는 [인증 체인](https://github.com/decentraland/docs/blob/main/contributor/auth/authchain/README.md) 섹션에서 설명한 것과 동일한 규칙을 따릅니다.

다음 [Archipelago](https://github.com/decentraland/docs/blob/main/contributor/communications/archipelago/README.md) 페이지로 이동하거나 특정 전송 방식을 확인해 인증 흐름에 대해 자세히 알아보세요.

### 아일랜드

섬은 구성원끼리 메시지를 방송할 수 있는 매우 동적인 플레이어 그룹으로, 다음에 의해 생성되고 유지됩니다 [Archipelago](https://github.com/decentraland/docs/blob/main/contributor/communications/archipelago/README.md) 월드에서의 이동에 따라.

섬에는 미리 정의된 영역이나 중심점이 없습니다. 섬은 안정적인 지리적 특성이 아니라, 근처 플레이어들의 임시적인 집합일 뿐입니다. 섬이 어떤 지역을 차지한다고 말할 수 있다면, 그것은 단지 현재 구성원들이 그 구역에 퍼져 있기 때문입니다.

플레이어가 없는 지역에는 섬이 0개일 수도 있고, 인구가 밀집한 지역에는 여러 개의 겹치는 섬이 있을 수 있습니다. 모든 사람을 같은 그룹으로 배정하면 실시간 브로드캐스팅이 불가능해지기 때문입니다.

Decentraland 네트워크의 각 서버는 섬의 최대 인원과 플레이어를 근처로 간주하는 거리를 설정할 수 있습니다. 기본값으로, 섬은 서로 100미터 이내에 있는 최대 100명의 플레이어를 수용할 수 있습니다.

섬에 배정되고 참여하는 흐름은 다음에서 자세히 설명합니다 [Archipelago](https://github.com/decentraland/docs/blob/main/contributor/communications/archipelago/README.md) 섹션에서 설명한 것과 동일한 규칙을 따릅니다.

### 메시지

comms 프로토콜의 메시지는 다음을 사용해 직렬화된 이진 블롭입니다 [프로토콜 버퍼](https://github.com/protocolbuffers/protobuf), 다음으로 감싸진 [패킷](https://github.com/decentraland/docs/blob/main/contributor/communications/messages/README.md#Packet) 구조체.

{% hint style="info" %}
다음 단어를 사용할 때 *message* comms 맥락에서는 항상 플레이어 간에 교환되는 채팅 메시지가 아니라, 이진 메시지 프로토콜을 가리킵니다.
{% endhint %}

다양한 실시간 상호작용 흐름을 위한 여러 다른 메시지 유형이 있습니다. 다음으로 이동해 [메시지](https://github.com/decentraland/docs/blob/main/contributor/communications/messages/README.md) 섹션에서 더 자세히 알아보세요.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.decentraland.org/contributor/contributor-ko/communications/overview.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
