Message

Definition

A message is the basic communications unit for the Second Life world. Messages are used to pass serialized information about almost every part of the system back and forth between two hosts on a network, through connections known as circuits.

There are many hundreds of messages in the Second Life message system. A list of them is available at Category:Messages.

Message Format

Messages are defined in the Message Template. They follow the format:

{
	[Message Name] [Message Frequency] [Message ID] [Message Trust Level] [Message Encoding]
	{
		[Block 1 Name]		[Block 1 Quantity]
		{	[Block 1 Parameter 1 Name]		[Block 1 Parameter 1 Type]	}
		{	[Block 2 Parameter 2 Name]		[Block 2 Parameter 2 Type]	}
                [...]
	}
        [...]
	{
		[Block n Name]		[Block n Quantity]
		{	[Block n Parameter 1 Name]		[Block n Parameter 1 Type]	}
                [...]
	}
}

For example

{
	TestMessage Low 1 NotTrusted Zerocoded
	{
		TestBlock1		Single
		{	Test1		U32	}
	}
	{
		NeighborBlock		Multiple		4
		{	Test0		U32	}
		{	Test1		U32	}
		{	Test2		U32	}
	}
}

Preamble

The preamble contains information about the message as a whole.

Blocks

Blocks are delimiters for groups of data in a message.

Variables

Variables contain the data sent with the message

Data Types