Skip to content

Home > @esengine/ecs-framework-monorepo > MessageManager > createMessage

MessageManager.createMessage() method

创建网络消息

Signature:

typescript
createMessage<T extends INetworkMessage>(type: MessageType, data: any, senderId: string, options?: MessageCreateOptions): T;

Parameters

Parameter

Type

Description

type

MessageType

data

any

senderId

string

options

MessageCreateOptions

(Optional)

Returns:

T

基于 MIT 许可证发布