WriteByte

From NPC for VCMP 0.4 Servers
Revision as of 17:32, 24 June 2023 by Habi (talk | contribs) (Created page with "{{Welcome|desc=This will write one byte(0-255) to the given blob which can be later passed to SendServerData.|params=<source lang="lua">( b, byte )</source><poem> ::b : The blob in which to write the integer. ::byte : The byte( 0-255 ) to be written </poem>| example=<source lang="lua"> local b=blob(); WriteByte(b, 100 ); SendServerData(b);</source>| retvals=The function returns true on success.| relfuncs=*WriteInt *WriteFloat *WriteString *SendServerDat...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


Description:
This will write one byte(0-255) to the given blob which can be later passed to SendServerData.


Parameters:

( b, byte )

b : The blob in which to write the integer.
byte : The byte( 0-255 ) to be written


Return Values:
The function returns true on success.


Example

local b=blob();
WriteByte(b, 100 );
SendServerData(b);

Related Functions

The following functions may be helpful as they relate to this function in one way or another.