STATE_multiplayer_message_write_buffer

 

 


  The engine has an internal buffer that is used to store the message.
  Calling STATE_multiplayer_message_create() simply reset this buffer.
   Calling this function will add the given buffer to the internal message buffer.
   Returns: OK or VR_ERROR.
  
   Examples
    A)
  		STATE_multiplayer_message_create();
  		double location[3]={100,200,300};
  		STATE_multiplayer_message_write_buffer(location, sizeof(double)*3);
  		STATE_multiplayer_message_send();    three double numbers will be sent 100,200,300
  
    B)
  		double location[3]={100,200,300};
  		STATE_multiplayer_message_write_buffer(location, sizeof(double)*3);
  		location[0]=400;
  		  Note that the second buffer is concatenated to the first one.
  		STATE_multiplayer_message_write_buffer(location, sizeof(double)*3);
  		STATE_multiplayer_message_send();   six double numbers will be sent 100,200,300, 400, 200, 300

 

 

Go to page 1      Select API

 

Copyright © 2007 3DSTATE Corporation. www.3dstate.com