SendPropArray(): Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
m (Setting bug notice hidetested=1 param on page where the bug might not need tested in param specified)
 
Line 1: Line 1:
<code>'''SendPropArray()'''</code> and <code>'''RecvPropArray()'''</code> are [[datatable]] macros that wrap around an existing [[SendProp()|send/receive prop]] and allow it to transmit as an array. They should be used with <code>[[SENDINFO_ARRAY()]]</code> in place of <code>[[SENDINFO()]]</code>.
<code>'''SendPropArray()'''</code> and <code>'''RecvPropArray()'''</code> are [[datatable]] macros that wrap around an existing [[SendProp()|send/receive prop]] and allow it to transmit as an array. They should be used with <code>[[SENDINFO_ARRAY()]]</code> in place of <code>[[SENDINFO()]]</code>.


{{bug|<code>RecvPropArray()</code> cannot be used with <code>[[Ehandle|EHandle]]</code> props. Use [[SendPropArray3()]].}}
{{bug|hidetested=1|<code>RecvPropArray()</code> cannot be used with <code>[[Ehandle|EHandle]]</code> props. Use [[SendPropArray3()]].}}


  ''usage:''
  ''usage:''

Latest revision as of 07:13, 20 May 2025

SendPropArray() and RecvPropArray() are datatable macros that wrap around an existing send/receive prop and allow it to transmit as an array. They should be used with SENDINFO_ARRAY() in place of SENDINFO().

Icon-Bug.pngBug:RecvPropArray() cannot be used with EHandle props. Use SendPropArray3().
usage:
	Send/RecvPropArray( <prop template>, <source/destination array> ),
server:
	SendPropArray( SendPropInt( SENDINFO_ARRAY(m_iMyArray) ), m_iMyServerArray ),
client:
	RecvPropArray( RecvPropInt( RECVINFO_ARRAY(m_iMyArray) ), m_iMyClientArray ),

See also