Documentation ¶
Overview ¶
The posbus package implements the custom protocol for communication between the backend and frontends.
Originally it implemented messaging for position updates of objects in a 3D space, hence the PosBus name. But has been expanded to include more types of information.
Messages are in a compact binary format and usually send through a websocket connection.
Index ¶
- Constants
- func BinMessage(m Message) []byte
- func DecodeTo(buf []byte, m Message) (err error)
- func ExtraTypes() []reflect.Type
- func MessageDataTypeById(id MsgType) reflect.Type
- func MessageNameById(id MsgType) string
- func MessageTypeNameById(id MsgType) string
- func MsgTypeName(m Message) string
- func WSMessage(m Message) *websocket.PreparedMessage
- type ActivityUpdate
- type ActivityUpdateType
- type AddObjects
- type AddPendingStake
- type AddUsers
- type AttributeChangeType
- type AttributeValueChanged
- type EventStart
- type FlyToMe
- type GenericMessage
- type HandShake
- type HighFive
- type LockObject
- type LockObjectResponse
- type Message
- type MsgType
- type MyTransform
- type Notification
- type NotificationType
- type ObjectData
- type ObjectDefinition
- type ObjectTransform
- type PBEthAddress
- type PBUint256
- type RemoveObjects
- type RemoveUsers
- type SetWorld
- type Signal
- type SignalType
- type StringAnyMap
- type TeleportRequest
- type Trigger
- type TriggerVisualEffects
- type UnlockObject
- type UserAction
- type UserData
- type UserStakedToOdyssey
- type UserTransform
- type UsersTransformList
- type VisualEffect
Constants ¶
const ( MsgTypeSize = 4 MsgArrTypeSize = 4 MsgUUIDTypeSize = 16 MsgLockStateSize = 4 )
const ( TriggerNone = iota TriggerWow TriggerHighFive TriggerEnteredObject TriggerLeftObject TriggerStake )
const UserTransformMessageSize = MsgUUIDTypeSize + cmath.Float32Bytes*6
Variables ¶
This section is empty.
Functions ¶
func BinMessage ¶
func ExtraTypes ¶
func MessageDataTypeById ¶
func MessageNameById ¶
func MessageTypeNameById ¶
func MsgTypeName ¶
func WSMessage ¶
func WSMessage(m Message) *websocket.PreparedMessage
Types ¶
type ActivityUpdate ¶
type ActivityUpdate struct { ActivityId umid.UMID `json:"activity_id"` ChangeType string `json:"change_type"` Type *entry.ActivityType `json:"type"` Data *entry.ActivityData `json:"data"` UserId umid.UMID `json:"user_id"` ObjectId umid.UMID `json:"object_id"` }
func (*ActivityUpdate) GetType ¶
func (r *ActivityUpdate) GetType() MsgType
func (ActivityUpdate) MarshalMUS ¶
func (v ActivityUpdate) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (ActivityUpdate) SizeMUS ¶
func (v ActivityUpdate) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*ActivityUpdate) UnmarshalMUS ¶
func (v *ActivityUpdate) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type ActivityUpdateType ¶
type ActivityUpdateType string
TODO: does musgo support type aliases/const like this?
const ( ActivityUpdateChangeType ActivityUpdateType = "" NewActivityUpdateType ActivityUpdateType = "new" ChangedActivityUpdateType ActivityUpdateType = "changed" RemovedActivityUpdateType ActivityUpdateType = "removed" )
type AddObjects ¶
type AddObjects struct {
Objects []ObjectDefinition `json:"objects"`
}
func (*AddObjects) GetType ¶
func (g *AddObjects) GetType() MsgType
func (AddObjects) MarshalMUS ¶
func (v AddObjects) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (AddObjects) SizeMUS ¶
func (v AddObjects) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*AddObjects) UnmarshalMUS ¶
func (v *AddObjects) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type AddPendingStake ¶
type AddPendingStake struct { TransactionID umid.UMID `json:"transaction_id"` OdysseyId umid.UMID `json:"odyssey_id"` Wallet PBEthAddress `json:"wallet"` Amount PBUint256 `json:"amount"` Comment string `json:"comment"` Kind int `json:"kind"` }
func (*AddPendingStake) GetType ¶
func (g *AddPendingStake) GetType() MsgType
func (AddPendingStake) MarshalMUS ¶
func (v AddPendingStake) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (AddPendingStake) SizeMUS ¶
func (v AddPendingStake) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*AddPendingStake) UnmarshalMUS ¶
func (v *AddPendingStake) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type AddUsers ¶
type AddUsers struct {
Users []UserData `json:"users"`
}
func (AddUsers) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type AttributeChangeType ¶
type AttributeChangeType string
TODO: does musgo support type aliases/const like this?
const ( InvalidAttributeChangeType AttributeChangeType = "" ChangedAttributeChangeType AttributeChangeType = "attribute_changed" RemovedAttributeChangeType AttributeChangeType = "attribute_removed" )
type AttributeValueChanged ¶
type AttributeValueChanged struct { // The plugin that owns the attribute PluginID umid.UMID `json:"plugin_id"` // Name of attribute (scoped to plugin) AttributeName string `json:"attribute_name"` // Indicate what has changed (removed or value changed) ChangeType string `json:"change_type"` // The new value, in case of change/new. Value *StringAnyMap `json:"value"` // ID of the related object/user TargetID umid.UMID `json:"target_id"` }
func (*AttributeValueChanged) GetType ¶
func (r *AttributeValueChanged) GetType() MsgType
func (AttributeValueChanged) MarshalMUS ¶
func (v AttributeValueChanged) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (AttributeValueChanged) SizeMUS ¶
func (v AttributeValueChanged) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*AttributeValueChanged) UnmarshalMUS ¶
func (v *AttributeValueChanged) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type EventStart ¶
func (*EventStart) GetType ¶
func (r *EventStart) GetType() MsgType
func (EventStart) MarshalMUS ¶
func (v EventStart) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (EventStart) SizeMUS ¶
func (v EventStart) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*EventStart) UnmarshalMUS ¶
func (v *EventStart) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type FlyToMe ¶
type FlyToMe struct { Pilot umid.UMID `json:"pilot"` PilotName string `json:"pilot_name"` ObjectID umid.UMID `json:"object_id"` }
func (FlyToMe) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type GenericMessage ¶
func NewGenericMessage ¶
func NewGenericMessage(topic string, data interface{}) *GenericMessage
func (*GenericMessage) GetType ¶
func (g *GenericMessage) GetType() MsgType
func (GenericMessage) MarshalMUS ¶
func (v GenericMessage) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (GenericMessage) SizeMUS ¶
func (v GenericMessage) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*GenericMessage) UnmarshalMUS ¶
func (v *GenericMessage) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type HandShake ¶
type HandShake struct { // Versioning for this message, for compatibility handling. HandshakeVersion int `json:"handshake_version"` // Versioning for the protocol to use after the handshake. ProtocolVersion int `json:"protocol_version"` // Authentication token (JWT). Token string `json:"token"` // User identifier (should match the token). UserId umid.UMID `json:"user_id"` // Unique session identifier, for state/reconnection handling. SessionId umid.UMID `json:"session_id"` }
A HandShake is the first message a client sends after connecting.
func (HandShake) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type HighFive ¶
type HighFive struct { SenderID umid.UMID `json:"sender_id"` ReceiverID umid.UMID `json:"receiver_id"` Message string `json:"message"` }
func (HighFive) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type LockObject ¶
func (*LockObject) GetType ¶
func (l *LockObject) GetType() MsgType
func (LockObject) MarshalMUS ¶
func (v LockObject) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (LockObject) SizeMUS ¶
func (v LockObject) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*LockObject) UnmarshalMUS ¶
func (v *LockObject) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type LockObjectResponse ¶
type LockObjectResponse struct { ID umid.UMID `json:"id"` State uint32 `json:"result"` LockOwner umid.UMID `json:"lock_owner"` }
func (*LockObjectResponse) GetType ¶
func (l *LockObjectResponse) GetType() MsgType
func (LockObjectResponse) MarshalMUS ¶
func (v LockObjectResponse) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (LockObjectResponse) SizeMUS ¶
func (v LockObjectResponse) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*LockObjectResponse) UnmarshalMUS ¶
func (v *LockObjectResponse) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type Message ¶
type Message interface { MarshalMUS(buf []byte) int UnmarshalMUS(buf []byte) (int, error) SizeMUS() int GetType() MsgType }
func NewMessageOfType ¶
type MsgType ¶
type MsgType uint32
const ( TypeActivityUpdate MsgType = 0xCA57695D TypeAddObjects MsgType = 0x2452A9C1 TypeAddPendingStake MsgType = 0xF020D682 TypeAddUsers MsgType = 0xF51F2AFF TypeAttributeValueChanged MsgType = 0x10DACDB7 TypeEventStart MsgType = 0xAA854D2C TypeFlyToMe MsgType = 0xA6EB70C6 TypeGenericMessage MsgType = 0xF508E4A3 TypeHandShake MsgType = 0x7C41941A TypeHighFive MsgType = 0x3D501432 TypeLockObject MsgType = 0xA7DE9F59 TypeLockObjectResponse MsgType = 0x0924668C TypeMyTransform MsgType = 0xF878C4BF TypeNotification MsgType = 0xC1FB41D7 TypeObjectData MsgType = 0xCACE197C TypeObjectDefinition MsgType = 0xD742B52E TypeObjectTransform MsgType = 0xEA6DA4B4 TypeRemoveObjects MsgType = 0x6BF88C24 TypeRemoveUsers MsgType = 0xF5A14BB0 TypeSetWorld MsgType = 0xCCDF2E49 TypeSignal MsgType = 0xADC1964D TypeTeleportRequest MsgType = 0x78DA55D9 TypeTriggerVisualEffects MsgType = 0xD96089C6 TypeUnlockObject MsgType = 0xA54EDEB9 TypeUserAction MsgType = 0xEF1A2E75 TypeUserData MsgType = 0xF702EF5F TypeUserStakedToOdyssey MsgType = 0x10DACABC TypeUserTransform MsgType = 0x3BC97EBB TypeUsersTransformList MsgType = 0x285954B8 )
func GetMessageIds ¶
func GetMessageIds() []MsgType
GetMessageIds : returns list of message IDs sorted according to message names
func MessageIdByName ¶
func MessageType ¶
type MyTransform ¶
type MyTransform cmath.TransformNoScale
func (*MyTransform) GetType ¶
func (a *MyTransform) GetType() MsgType
func (MyTransform) MarshalMUS ¶
func (v MyTransform) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (MyTransform) SizeMUS ¶
func (v MyTransform) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*MyTransform) UnmarshalMUS ¶
func (v *MyTransform) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type Notification ¶
type Notification struct { NotifyType NotificationType `json:"notify_type"` Value string `json:"value"` }
func (*Notification) GetType ¶
func (g *Notification) GetType() MsgType
func (Notification) MarshalMUS ¶
func (v Notification) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (Notification) SizeMUS ¶
func (v Notification) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*Notification) UnmarshalMUS ¶
func (v *Notification) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type NotificationType ¶
type NotificationType uint32
const ( NotificationNone NotificationType = 0 NotificationWow NotificationType = 1 NotificationHighFive NotificationType = 2 NotificationStageModeAccept NotificationType = 10 NotificationStageModeInvitation NotificationType = 11 NotificationStageModeSet NotificationType = 12 NotificationStageModeStageJoin NotificationType = 13 NotificationStageModeStageRequest NotificationType = 14 NotificationStageModeStageDeclined NotificationType = 15 NotificationGatheringStart NotificationType = 20 NotificationTextMessage NotificationType = 500 NotificationRelay NotificationType = 501 NotificationGeneric NotificationType = 999 NotificationLegacy NotificationType = 1000 )
func (NotificationType) MarshalMUS ¶
func (v NotificationType) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (NotificationType) SizeMUS ¶
func (v NotificationType) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*NotificationType) UnmarshalMUS ¶
func (v *NotificationType) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type ObjectData ¶
type ObjectData struct { ID umid.UMID `json:"id"` Entries map[entry.SlotType]*StringAnyMap `json:"entries"` }
func (*ObjectData) GetType ¶
func (l *ObjectData) GetType() MsgType
func (ObjectData) MarshalMUS ¶
func (v ObjectData) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (ObjectData) SizeMUS ¶
func (v ObjectData) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*ObjectData) UnmarshalMUS ¶
func (v *ObjectData) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type ObjectDefinition ¶
type ObjectDefinition struct { ID umid.UMID `json:"id"` ParentID umid.UMID `json:"parent_id"` AssetType umid.UMID `json:"asset_type"` AssetFormat dto.Asset3dType `json:"asset_format"` // TODO: Rename AssetType to AssetID, so Type can be used for this. Name string `json:"name"` Transform cmath.Transform `json:"transform"` IsEditable bool `json:"is_editable"` TetheredToParent bool `json:"tethered_to_parent"` ShowOnMiniMap bool `json:"show_on_minimap"` }
func (*ObjectDefinition) GetType ¶
func (g *ObjectDefinition) GetType() MsgType
func (ObjectDefinition) MarshalMUS ¶
func (v ObjectDefinition) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (ObjectDefinition) SizeMUS ¶
func (v ObjectDefinition) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*ObjectDefinition) UnmarshalMUS ¶
func (v *ObjectDefinition) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type ObjectTransform ¶
type ObjectTransform struct { ID umid.UMID `json:"id"` Transform cmath.Transform `json:"object_transform"` }
ObjectTransform is a transform to apply to a specific object.
func (*ObjectTransform) GetType ¶
func (g *ObjectTransform) GetType() MsgType
func (ObjectTransform) MarshalMUS ¶
func (v ObjectTransform) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (ObjectTransform) SizeMUS ¶
func (v ObjectTransform) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*ObjectTransform) UnmarshalMUS ¶
func (v *ObjectTransform) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type PBEthAddress ¶
func (PBEthAddress) MarshalMUS ¶
func (v PBEthAddress) MarshalMUS(buf []byte) int
func (PBEthAddress) SizeMUS ¶
func (v PBEthAddress) SizeMUS() int
func (*PBEthAddress) UnmarshalMUS ¶
func (v *PBEthAddress) UnmarshalMUS(buf []byte) (int, error)
type PBUint256 ¶
func (PBUint256) MarshalMUS ¶
type RemoveObjects ¶
func (*RemoveObjects) GetType ¶
func (g *RemoveObjects) GetType() MsgType
func (RemoveObjects) MarshalMUS ¶
func (v RemoveObjects) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (RemoveObjects) SizeMUS ¶
func (v RemoveObjects) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*RemoveObjects) UnmarshalMUS ¶
func (v *RemoveObjects) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type RemoveUsers ¶
func (*RemoveUsers) GetType ¶
func (a *RemoveUsers) GetType() MsgType
func (RemoveUsers) MarshalMUS ¶
func (v RemoveUsers) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (RemoveUsers) SizeMUS ¶
func (v RemoveUsers) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*RemoveUsers) UnmarshalMUS ¶
func (v *RemoveUsers) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type SetWorld ¶
type SetWorld struct { ID umid.UMID `json:"id"` Name string `json:"name"` Avatar umid.UMID `json:"avatar"` Owner umid.UMID `json:"owner"` Avatar3DAssetID umid.UMID `json:"avatar_3d_asset_id" gopy:"avatar_3d_asset_id"` }
func (SetWorld) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type Signal ¶
type Signal struct {
Value SignalType `json:"value"`
}
func (Signal) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type SignalType ¶
type SignalType uint32
const ( SignalNone SignalType = iota SignalDualConnection SignalReady SignalInvalidToken SignalSpawn SignalLeaveWorld SignalConnectionFailed SignalConnected SignalConnectionClosed SignalWorldDoesNotExist )
func (SignalType) MarshalMUS ¶
func (v SignalType) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (SignalType) SizeMUS ¶
func (v SignalType) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*SignalType) UnmarshalMUS ¶
func (v *SignalType) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type StringAnyMap ¶
func (StringAnyMap) MarshalMUS ¶
func (v StringAnyMap) MarshalMUS(buf []byte) int
func (StringAnyMap) SizeMUS ¶
func (v StringAnyMap) SizeMUS() int
func (*StringAnyMap) UnmarshalMUS ¶
func (v *StringAnyMap) UnmarshalMUS(buf []byte) (int, error)
type TeleportRequest ¶
func (*TeleportRequest) GetType ¶
func (g *TeleportRequest) GetType() MsgType
func (TeleportRequest) MarshalMUS ¶
func (v TeleportRequest) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (TeleportRequest) SizeMUS ¶
func (v TeleportRequest) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*TeleportRequest) UnmarshalMUS ¶
func (v *TeleportRequest) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type Trigger ¶
type Trigger uint32
func (Trigger) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type TriggerVisualEffects ¶
type TriggerVisualEffects struct {
Effects []VisualEffect `json:"effects"`
}
func (*TriggerVisualEffects) GetType ¶
func (g *TriggerVisualEffects) GetType() MsgType
func (TriggerVisualEffects) MarshalMUS ¶
func (v TriggerVisualEffects) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (TriggerVisualEffects) SizeMUS ¶
func (v TriggerVisualEffects) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*TriggerVisualEffects) UnmarshalMUS ¶
func (v *TriggerVisualEffects) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type UnlockObject ¶
func (*UnlockObject) GetType ¶
func (l *UnlockObject) GetType() MsgType
func (UnlockObject) MarshalMUS ¶
func (v UnlockObject) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (UnlockObject) SizeMUS ¶
func (v UnlockObject) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*UnlockObject) UnmarshalMUS ¶
func (v *UnlockObject) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type UserAction ¶
type UserAction struct {
Value Trigger `json:"value"`
}
func (*UserAction) GetType ¶
func (g *UserAction) GetType() MsgType
func (UserAction) MarshalMUS ¶
func (v UserAction) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (UserAction) SizeMUS ¶
func (v UserAction) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*UserAction) UnmarshalMUS ¶
func (v *UserAction) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type UserData ¶
type UserData struct { ID umid.UMID `json:"id"` Name string `json:"name"` Avatar string `json:"avatar"` Transform cmath.TransformNoScale `json:"transform"` IsGuest bool `json:"is_guest"` }
func (UserData) MarshalMUS ¶
MarshalMUS fills buf with the MUS encoding of v.
type UserStakedToOdyssey ¶
type UserStakedToOdyssey struct { TransactionHash string `json:"transaction_hash"` Wallet string `json:"wallet"` ObjectID umid.UMID `json:"object_id"` Amount string `json:"amount"` Comment string `json:"comment"` Kind int `json:"kind"` }
func (*UserStakedToOdyssey) GetType ¶
func (r *UserStakedToOdyssey) GetType() MsgType
func (UserStakedToOdyssey) MarshalMUS ¶
func (v UserStakedToOdyssey) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (UserStakedToOdyssey) SizeMUS ¶
func (v UserStakedToOdyssey) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*UserStakedToOdyssey) UnmarshalMUS ¶
func (v *UserStakedToOdyssey) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type UserTransform ¶
type UserTransform struct { ID umid.UMID `json:"id"` Transform cmath.TransformNoScale `json:"transform"` }
UserTransform is a transform to apply to a specific user.
func (*UserTransform) GetType ¶
func (s *UserTransform) GetType() MsgType
func (UserTransform) MarshalMUS ¶
func (v UserTransform) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (UserTransform) SizeMUS ¶
func (v UserTransform) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*UserTransform) UnmarshalMUS ¶
func (v *UserTransform) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type UsersTransformList ¶
type UsersTransformList struct {
Value []UserTransform `json:"value"`
}
func (*UsersTransformList) GetType ¶
func (s *UsersTransformList) GetType() MsgType
func (UsersTransformList) MarshalMUS ¶
func (v UsersTransformList) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (UsersTransformList) SizeMUS ¶
func (v UsersTransformList) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*UsersTransformList) UnmarshalMUS ¶
func (v *UsersTransformList) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
type VisualEffect ¶
type VisualEffect struct {
Name string `json:"name"`
}
FIXME: finalize VisualEffect type with all data
func (VisualEffect) MarshalMUS ¶
func (v VisualEffect) MarshalMUS(buf []byte) int
MarshalMUS fills buf with the MUS encoding of v.
func (VisualEffect) SizeMUS ¶
func (v VisualEffect) SizeMUS() int
SizeMUS returns the size of the MUS-encoded v.
func (*VisualEffect) UnmarshalMUS ¶
func (v *VisualEffect) UnmarshalMUS(buf []byte) (int, error)
UnmarshalMUS parses the MUS-encoded buf, and sets the result to *v.
Source Files ¶
- ActivityUpdate.mus.go
- AddObjects.mus.go
- AddPendingStake.mus.go
- AddUsers.mus.go
- AttributeValueChanged.mus.go
- EventStart.mus.go
- FlyToMe.mus.go
- GenericMessage.mus.go
- HandShake.mus.go
- HighFive.mus.go
- LockObject.mus.go
- LockObjectResponse.mus.go
- MyTransform.mus.go
- Notification.mus.go
- NotificationType.mus.go
- ObjectData.mus.go
- ObjectDefinition.mus.go
- ObjectTransform.mus.go
- RemoveObjects.mus.go
- RemoveUsers.mus.go
- SetWorld.mus.go
- Signal.mus.go
- SignalType.mus.go
- TeleportRequest.mus.go
- Trigger.mus.go
- TriggerVisualEffects.mus.go
- UnlockObject.mus.go
- UserAction.mus.go
- UserData.mus.go
- UserStakedToOdyssey.mus.go
- UserTransform.mus.go
- UsersTransformList.mus.go
- VisualEffect.mus.go
- activity_update.go
- add_objects.go
- add_pending_stake.go
- add_users.go
- attribute_value_changed.go
- doc.go
- event_start.go
- fly_to_me.go
- generic.go
- handshake.go
- high_five.go
- message.go
- my_transform.go
- notification.go
- object_data.go
- object_definition.go
- object_lock.go
- object_position.go
- posbus_ether_address.go
- posbus_uint256.go
- remove_objects.go
- remove_users.go
- set_world.go
- signal.go
- string_map_base.go
- teleport_request.go
- trigger_visual_effect.go
- trigger_visual_effects.go
- types.autogen.go
- user_action.go
- user_data.go
- user_staked_to_odyssey.go
- users_transform_list.go