Browse docspacket.set_bytes
On this page
API method

packet.set_bytes

Writes an array of byte values (each wrapped to 0-255) into the payload at a payload-relative offset.

Syntax

Atlas Script
packet.set_bytes(offset, bytes)

Parameters

offset
Byte offset into the packet. Payload-relative for packet.* methods, and absolute (whole IP packet) for the raw_* variants.
bytes
Array of byte values (0-255) written into the packet payload.

Return value

See the remarks for the returned value and runtime behavior.

Remarks

Writes an array of byte values (each wrapped to 0-255) into the payload at a payload-relative offset. Values that would pass the end of the packet are skipped.

Examples

Usage pattern
// Replace offset, bytes with values described above.
packet.set_bytes(offset, bytes);
Reference details are generated from the Atlas Script schema in this documentation source snapshot. Confirm release-specific behavior in the Atlas for Windows build you use.