[API reference](https://jsprismarine.dev/api/index.md) / [@jsprismarine/protocol](https://jsprismarine.dev/api/@jsprismarine/protocol/index.md) / SyncedProperties

# Class: SyncedProperties

Defined in: [protocol/src/bedrock/wire/structures/SyncedProperties.ts:22](https://github.com/JSPrismarine/JSPrismarine/blob/21088b69d7b227110b98eefd29702ff7304762ef/packages/protocol/src/bedrock/wire/structures/SyncedProperties.ts#L22)

The 2193 `PropertySyncData` structure carried by `SetActorDataPacket`, `AddActorPacket` and
`AddPlayerPacket`.

On the wire it is two lists. The Int Entries List is a varuint32 count followed by one
`Property Index` varuint32 and `Data` ZigZag varint32 per entry. The Float Entries List is a
varuint32 count followed by one `Property Index` varuint32 and `Data` little-endian float per
entry. Property indexes follow the client-synced definitions sent for the actor type.

## Constructors

### Constructor

> **new SyncedProperties**(): `SyncedProperties`

#### Returns

`SyncedProperties`

## Properties

### floatProps

> **floatProps**: [`PropertySyncEntry`](https://jsprismarine.dev/api/@jsprismarine/protocol/index.md#propertysyncentry)[] = `[]`

Defined in: [protocol/src/bedrock/wire/structures/SyncedProperties.ts:26](https://github.com/JSPrismarine/JSPrismarine/blob/21088b69d7b227110b98eefd29702ff7304762ef/packages/protocol/src/bedrock/wire/structures/SyncedProperties.ts#L26)

Float Entries List, in the order they are written.

***

### intProps

> **intProps**: [`PropertySyncEntry`](https://jsprismarine.dev/api/@jsprismarine/protocol/index.md#propertysyncentry)[] = `[]`

Defined in: [protocol/src/bedrock/wire/structures/SyncedProperties.ts:24](https://github.com/JSPrismarine/JSPrismarine/blob/21088b69d7b227110b98eefd29702ff7304762ef/packages/protocol/src/bedrock/wire/structures/SyncedProperties.ts#L24)

Int Entries List, in the order they are written.

## Methods

### networkSerialize()

> **networkSerialize**(`stream`): `void`

Defined in: [protocol/src/bedrock/wire/structures/SyncedProperties.ts:31](https://github.com/JSPrismarine/JSPrismarine/blob/21088b69d7b227110b98eefd29702ff7304762ef/packages/protocol/src/bedrock/wire/structures/SyncedProperties.ts#L31)

Write both lists in docs order: int entries, then float entries.

#### Parameters

##### stream

[`BinaryStream`](https://jsprismarine.dev/api/@jsprismarine/binaryutils/classes/BinaryStream.md)

#### Returns

`void`

***

### networkDeserialize()

> `static` **networkDeserialize**(`stream`): `SyncedProperties`

Defined in: [protocol/src/bedrock/wire/structures/SyncedProperties.ts:46](https://github.com/JSPrismarine/JSPrismarine/blob/21088b69d7b227110b98eefd29702ff7304762ef/packages/protocol/src/bedrock/wire/structures/SyncedProperties.ts#L46)

Reads both lists in docs order, the mirror of [networkSerialize](#networkserialize).

#### Parameters

##### stream

[`BinaryStream`](https://jsprismarine.dev/api/@jsprismarine/binaryutils/classes/BinaryStream.md)

#### Returns

`SyncedProperties`
