CoC_LIBNETWORK

Author: Bn880, Dinger and Spinor of the CoC
Date: 2004/05/06  Revised 22/08/2004

Overview
Installation
Loading the library
List of functions
List of resources
Description
History
Conversion


Overview

The CoC Network Library is provided with the CoC Network Services add-on or mission scripts and it includes the CoC Public Array global array sharing system.  For further questions visit our forums at The Chain of Command.

Version: 2.0 REV. 2
Dependencies: COC_LIBNUMSYS (bundled in CoC Network Services)
Included in: CoC Network Services & Add-on

DOWNLOAD 2.0 PACK


Installation

Add-On Version

Script Version


Loading the library

The library is loaded automatically only as part of the CoC Network Services.
The global variable CoC_LIBNETWORK equals 2.0 if the library is loaded. See Installation .


List of functions

fArrayToVar
fDefined
fNGetType
fNCall
fNClearQ
fNGetNode
fNPing
fNPrint
fNRemoteCall
fNSend
fNSendAll
fNSendClients
fNSendGlobal
fNSendServer
fNSendRange
fPublicArray
fReceiveArray
fVarToArray


List of Resources

CoC_AbortLength
CoC_AckWaitTime
CoC_ClientChannel
CoC_ClientList
CoC_ClientsReady
CoC_ConnectTimeout
CoC_ConWaitTime
CoC_DataWaitTime
CoC_InfoWaitTime
CoC_isClient
CoC_isServer
CoC_isServerClient
CoC_isServerDedicated
CoC_MaxRetry
CoC_NPA_PollInterval
CoC_NSFunTable
CoC_PeerList
CoC_PortBusSize
CoC_PortNumber
CoC_PortWaitTime
CoC_PublicArrays


Description

The purpose of the library is to allow OFP mission or system designers to establish point to point or global communications with every network node in a network session, and to have a means to transfer any information in a manner that is as efficient as possible given the limitations of the engine. Since version 2.0 the fNSend* (excluding global) functions will allow the transmission of all OFP data types to specific functions on any destination node(s) using one point to point communication session to each network node. For reference here are all the OFP data types that these functions will send:

The fPublicArray function will allow for the sharing of arrays to all network nodes via a single network exchange(as opposed to multiple point to point), the public arrays can be filled with any of the following data types:

The fNSendGlobal function will allow the transmission of the following data types to selected nodes (or all) via a single network exchange (as opposed to multiple point to point exchanges):

The fNRemoteCall function offers a third and another unique method of sending information across. It works similarly to fNSendGlobal that it does only one network transaction per call (no matter how many destinations), however it simply executes the passed in command string remotely (entire command must be 4000 chars or less). The following data types can be embedded and transmitted in fNRemoteCall:


History

Script Version

2.0 06/05/2004

1.2 14/11/2003

1.1 14/06/2003

Added: PublicArray global array sharing system added to Network Services.
Added: Online documentation for system.
Added: functions fNPrint, fNSendAll, fNSendClients, fNSendServer, fNSendRange plus Public Array function fPublicArray and others.
Changed/Added: Configuration variables renamed to CoC_AbortLength, CoC_AckWaitTime,CoC_ConnectTimeout, CoC_ConWaitTime, CoC_DataWaitTime, CoC_InfoWaitTime, CoC_MaxRetry, CoC_PortBusSize, CoC_PortNumber, CoC_PortWaitTime and made global thus allowing configuration from init.sqs of mission.
Changed: All variable prefixes changed from "rN" to "CoC_", this includes the resources and CoC_Server (previously Server), CoC_Client (previously rNClient), CoC_ClientIndex (previously rNClientIndex).
Changed: Internal communication variable prefix shortened to "Q_" instead of "rNC_" thus improving send performance.
Changed: Almost all handshaking is now performed after mission start instead of briefing to decrease the network flood effect in large MP missions. However this will require longer CoC_ConnectionTimeout settings for bad modem connections.

1.0a 07/05/2003

Fixed: rNisServerClient now functions as expected
Fixed: EULA Revised to remove network usage clause and permit free use of the product on any computer or network.
Added: Radio Charlie added to template missions to show useful resources.

1.0 03/05/2003 INITIAL RELEASE

Add-on Version

2.0 07/05/2004

Same as Script 2.0

1.2 11/14/2003

Same as Script 1.2 and:


1.1 15/06/2003 First Public Release
0.9 10/05/2003 Internal Alpha release

File last updated 07 May 2004