| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596 |
- /* ----------------------------------------------------------------------------
- * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.1
- *
- * Do not make changes to this file unless you know what you are doing--modify
- * the SWIG interface file instead.
- * ----------------------------------------------------------------------------- */
- namespace RakNet {
- using System;
- using System.Runtime.InteropServices;
- public class RakPeerInterface : IDisposable {
- private HandleRef swigCPtr;
- protected bool swigCMemOwn;
- internal RakPeerInterface(IntPtr cPtr, bool cMemoryOwn) {
- swigCMemOwn = cMemoryOwn;
- swigCPtr = new HandleRef(this, cPtr);
- }
- internal static HandleRef getCPtr(RakPeerInterface obj) {
- return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
- }
- ~RakPeerInterface() {
- Dispose();
- }
- public virtual void Dispose() {
- lock(this) {
- if (swigCPtr.Handle != IntPtr.Zero) {
- if (swigCMemOwn) {
- swigCMemOwn = false;
- RakNetPINVOKE.delete_RakPeerInterface(swigCPtr);
- }
- swigCPtr = new HandleRef(null, IntPtr.Zero);
- }
- GC.SuppressFinalize(this);
- }
- }
- public virtual void GetIncomingPassword(ref string passwordData, ref int passwordDataLength )
- {
- passwordData=CSharpGetIncomingPasswordHelper(passwordData,ref passwordDataLength);
- }
- public virtual void GetOfflinePingResponse( byte[] inOutByteArray, out uint length )
- {
- CSharpGetOfflinePingResponseHelper(inOutByteArray,out length);
- }
- public virtual bool GetConnectionList(out SystemAddress[] remoteSystems, ref ushort numberOfSystems)
- {
- RakNetListSystemAddress passVal= new RakNetListSystemAddress();
- bool returnVal = GetConnectionList(passVal,ref numberOfSystems);
- SystemAddress[] outVal = new SystemAddress[numberOfSystems];
- for (int i=0; i<numberOfSystems;i++)
- {
- outVal[i]=passVal[i];
- }
- remoteSystems=outVal;
- return returnVal;
- }
- public static RakPeerInterface GetInstance() {
- IntPtr cPtr = RakNetPINVOKE.RakPeerInterface_GetInstance();
- RakPeerInterface ret = (cPtr == IntPtr.Zero) ? null : new RakPeerInterface(cPtr, false);
- return ret;
- }
- public static void DestroyInstance(RakPeerInterface i) {
- RakNetPINVOKE.RakPeerInterface_DestroyInstance(RakPeerInterface.getCPtr(i));
- }
- public virtual StartupResult Startup(ushort maxConnections, SocketDescriptor socketDescriptors, uint socketDescriptorCount, int threadPriority) {
- StartupResult ret = (StartupResult)RakNetPINVOKE.RakPeerInterface_Startup__SWIG_0(swigCPtr, maxConnections, SocketDescriptor.getCPtr(socketDescriptors), socketDescriptorCount, threadPriority);
- return ret;
- }
- public virtual StartupResult Startup(ushort maxConnections, SocketDescriptor socketDescriptors, uint socketDescriptorCount) {
- StartupResult ret = (StartupResult)RakNetPINVOKE.RakPeerInterface_Startup__SWIG_1(swigCPtr, maxConnections, SocketDescriptor.getCPtr(socketDescriptors), socketDescriptorCount);
- return ret;
- }
- public virtual bool InitializeSecurity(string publicKey, string privateKey, bool bRequireClientKey) {
- bool ret = RakNetPINVOKE.RakPeerInterface_InitializeSecurity__SWIG_0(swigCPtr, publicKey, privateKey, bRequireClientKey);
- return ret;
- }
- public virtual bool InitializeSecurity(string publicKey, string privateKey) {
- bool ret = RakNetPINVOKE.RakPeerInterface_InitializeSecurity__SWIG_1(swigCPtr, publicKey, privateKey);
- return ret;
- }
- public virtual void DisableSecurity() {
- RakNetPINVOKE.RakPeerInterface_DisableSecurity(swigCPtr);
- }
- public virtual void AddToSecurityExceptionList(string ip) {
- RakNetPINVOKE.RakPeerInterface_AddToSecurityExceptionList(swigCPtr, ip);
- }
- public virtual void RemoveFromSecurityExceptionList(string ip) {
- RakNetPINVOKE.RakPeerInterface_RemoveFromSecurityExceptionList(swigCPtr, ip);
- }
- public virtual bool IsInSecurityExceptionList(string ip) {
- bool ret = RakNetPINVOKE.RakPeerInterface_IsInSecurityExceptionList(swigCPtr, ip);
- return ret;
- }
- public virtual void SetMaximumIncomingConnections(ushort numberAllowed) {
- RakNetPINVOKE.RakPeerInterface_SetMaximumIncomingConnections(swigCPtr, numberAllowed);
- }
- public virtual ushort GetMaximumIncomingConnections() {
- ushort ret = RakNetPINVOKE.RakPeerInterface_GetMaximumIncomingConnections(swigCPtr);
- return ret;
- }
- public virtual ushort NumberOfConnections() {
- ushort ret = RakNetPINVOKE.RakPeerInterface_NumberOfConnections(swigCPtr);
- return ret;
- }
- public virtual void SetIncomingPassword(string passwordData, int passwordDataLength) {
- RakNetPINVOKE.RakPeerInterface_SetIncomingPassword__SWIG_0(swigCPtr, passwordData, passwordDataLength);
- }
- public virtual ConnectionAttemptResult Connect(string host, ushort remotePort, string passwordData, int passwordDataLength, PublicKey publicKey, uint connectionSocketIndex, uint sendConnectionAttemptCount, uint timeBetweenSendConnectionAttemptsMS, uint timeoutTime) {
- ConnectionAttemptResult ret = (ConnectionAttemptResult)RakNetPINVOKE.RakPeerInterface_Connect__SWIG_0(swigCPtr, host, remotePort, passwordData, passwordDataLength, PublicKey.getCPtr(publicKey), connectionSocketIndex, sendConnectionAttemptCount, timeBetweenSendConnectionAttemptsMS, timeoutTime);
- return ret;
- }
- public virtual ConnectionAttemptResult Connect(string host, ushort remotePort, string passwordData, int passwordDataLength, PublicKey publicKey, uint connectionSocketIndex, uint sendConnectionAttemptCount, uint timeBetweenSendConnectionAttemptsMS) {
- ConnectionAttemptResult ret = (ConnectionAttemptResult)RakNetPINVOKE.RakPeerInterface_Connect__SWIG_1(swigCPtr, host, remotePort, passwordData, passwordDataLength, PublicKey.getCPtr(publicKey), connectionSocketIndex, sendConnectionAttemptCount, timeBetweenSendConnectionAttemptsMS);
- return ret;
- }
- public virtual ConnectionAttemptResult Connect(string host, ushort remotePort, string passwordData, int passwordDataLength, PublicKey publicKey, uint connectionSocketIndex, uint sendConnectionAttemptCount) {
- ConnectionAttemptResult ret = (ConnectionAttemptResult)RakNetPINVOKE.RakPeerInterface_Connect__SWIG_2(swigCPtr, host, remotePort, passwordData, passwordDataLength, PublicKey.getCPtr(publicKey), connectionSocketIndex, sendConnectionAttemptCount);
- return ret;
- }
- public virtual ConnectionAttemptResult Connect(string host, ushort remotePort, string passwordData, int passwordDataLength, PublicKey publicKey, uint connectionSocketIndex) {
- ConnectionAttemptResult ret = (ConnectionAttemptResult)RakNetPINVOKE.RakPeerInterface_Connect__SWIG_3(swigCPtr, host, remotePort, passwordData, passwordDataLength, PublicKey.getCPtr(publicKey), connectionSocketIndex);
- return ret;
- }
- public virtual ConnectionAttemptResult Connect(string host, ushort remotePort, string passwordData, int passwordDataLength, PublicKey publicKey) {
- ConnectionAttemptResult ret = (ConnectionAttemptResult)RakNetPINVOKE.RakPeerInterface_Connect__SWIG_4(swigCPtr, host, remotePort, passwordData, passwordDataLength, PublicKey.getCPtr(publicKey));
- return ret;
- }
- public virtual ConnectionAttemptResult Connect(string host, ushort remotePort, string passwordData, int passwordDataLength) {
- ConnectionAttemptResult ret = (ConnectionAttemptResult)RakNetPINVOKE.RakPeerInterface_Connect__SWIG_5(swigCPtr, host, remotePort, passwordData, passwordDataLength);
- return ret;
- }
- public virtual void Shutdown(uint blockDuration, byte orderingChannel, PacketPriority disconnectionNotificationPriority) {
- RakNetPINVOKE.RakPeerInterface_Shutdown__SWIG_0(swigCPtr, blockDuration, orderingChannel, (int)disconnectionNotificationPriority);
- }
- public virtual void Shutdown(uint blockDuration, byte orderingChannel) {
- RakNetPINVOKE.RakPeerInterface_Shutdown__SWIG_1(swigCPtr, blockDuration, orderingChannel);
- }
- public virtual void Shutdown(uint blockDuration) {
- RakNetPINVOKE.RakPeerInterface_Shutdown__SWIG_2(swigCPtr, blockDuration);
- }
- public virtual bool IsActive() {
- bool ret = RakNetPINVOKE.RakPeerInterface_IsActive(swigCPtr);
- return ret;
- }
- public virtual uint GetNextSendReceipt() {
- uint ret = RakNetPINVOKE.RakPeerInterface_GetNextSendReceipt(swigCPtr);
- return ret;
- }
- public virtual uint IncrementNextSendReceipt() {
- uint ret = RakNetPINVOKE.RakPeerInterface_IncrementNextSendReceipt(swigCPtr);
- return ret;
- }
- public virtual uint Send(string data, int length, PacketPriority priority, PacketReliability reliability, char orderingChannel, AddressOrGUID systemIdentifier, bool broadcast, uint forceReceiptNumber) {
- uint ret = RakNetPINVOKE.RakPeerInterface_Send__SWIG_0(swigCPtr, data, length, (int)priority, (int)reliability, orderingChannel, AddressOrGUID.getCPtr(systemIdentifier), broadcast, forceReceiptNumber);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual uint Send(string data, int length, PacketPriority priority, PacketReliability reliability, char orderingChannel, AddressOrGUID systemIdentifier, bool broadcast) {
- uint ret = RakNetPINVOKE.RakPeerInterface_Send__SWIG_1(swigCPtr, data, length, (int)priority, (int)reliability, orderingChannel, AddressOrGUID.getCPtr(systemIdentifier), broadcast);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual void SendLoopback(string data, int length) {
- RakNetPINVOKE.RakPeerInterface_SendLoopback__SWIG_0(swigCPtr, data, length);
- }
- public virtual uint Send(BitStream bitStream, PacketPriority priority, PacketReliability reliability, char orderingChannel, AddressOrGUID systemIdentifier, bool broadcast, uint forceReceiptNumber) {
- uint ret = RakNetPINVOKE.RakPeerInterface_Send__SWIG_2(swigCPtr, BitStream.getCPtr(bitStream), (int)priority, (int)reliability, orderingChannel, AddressOrGUID.getCPtr(systemIdentifier), broadcast, forceReceiptNumber);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual uint Send(BitStream bitStream, PacketPriority priority, PacketReliability reliability, char orderingChannel, AddressOrGUID systemIdentifier, bool broadcast) {
- uint ret = RakNetPINVOKE.RakPeerInterface_Send__SWIG_3(swigCPtr, BitStream.getCPtr(bitStream), (int)priority, (int)reliability, orderingChannel, AddressOrGUID.getCPtr(systemIdentifier), broadcast);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual Packet Receive() {
- IntPtr cPtr = RakNetPINVOKE.RakPeerInterface_Receive(swigCPtr);
- Packet ret = (cPtr == IntPtr.Zero) ? null : new Packet(cPtr, false);
- return ret;
- }
- public virtual void DeallocatePacket(Packet packet) {
- RakNetPINVOKE.RakPeerInterface_DeallocatePacket(swigCPtr, Packet.getCPtr(packet));
- }
- public virtual ushort GetMaximumNumberOfPeers() {
- ushort ret = RakNetPINVOKE.RakPeerInterface_GetMaximumNumberOfPeers(swigCPtr);
- return ret;
- }
- public virtual void CloseConnection(AddressOrGUID target, bool sendDisconnectionNotification, byte orderingChannel, PacketPriority disconnectionNotificationPriority) {
- RakNetPINVOKE.RakPeerInterface_CloseConnection__SWIG_0(swigCPtr, AddressOrGUID.getCPtr(target), sendDisconnectionNotification, orderingChannel, (int)disconnectionNotificationPriority);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual void CloseConnection(AddressOrGUID target, bool sendDisconnectionNotification, byte orderingChannel) {
- RakNetPINVOKE.RakPeerInterface_CloseConnection__SWIG_1(swigCPtr, AddressOrGUID.getCPtr(target), sendDisconnectionNotification, orderingChannel);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual void CloseConnection(AddressOrGUID target, bool sendDisconnectionNotification) {
- RakNetPINVOKE.RakPeerInterface_CloseConnection__SWIG_2(swigCPtr, AddressOrGUID.getCPtr(target), sendDisconnectionNotification);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual ConnectionState GetConnectionState(AddressOrGUID systemIdentifier) {
- ConnectionState ret = (ConnectionState)RakNetPINVOKE.RakPeerInterface_GetConnectionState(swigCPtr, AddressOrGUID.getCPtr(systemIdentifier));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual void CancelConnectionAttempt(SystemAddress target) {
- RakNetPINVOKE.RakPeerInterface_CancelConnectionAttempt(swigCPtr, SystemAddress.getCPtr(target));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual int GetIndexFromSystemAddress(SystemAddress systemAddress) {
- int ret = RakNetPINVOKE.RakPeerInterface_GetIndexFromSystemAddress(swigCPtr, SystemAddress.getCPtr(systemAddress));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual SystemAddress GetSystemAddressFromIndex(int index) {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetSystemAddressFromIndex(swigCPtr, index), true);
- return ret;
- }
- public virtual RakNetGUID GetGUIDFromIndex(int index) {
- RakNetGUID ret = new RakNetGUID(RakNetPINVOKE.RakPeerInterface_GetGUIDFromIndex(swigCPtr, index), true);
- return ret;
- }
- public virtual void GetSystemList(RakNetListSystemAddress addresses, RakNetListRakNetGUID guids) {
- RakNetPINVOKE.RakPeerInterface_GetSystemList(swigCPtr, RakNetListSystemAddress.getCPtr(addresses), RakNetListRakNetGUID.getCPtr(guids));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual void AddToBanList(string IP, uint milliseconds) {
- RakNetPINVOKE.RakPeerInterface_AddToBanList__SWIG_0(swigCPtr, IP, milliseconds);
- }
- public virtual void AddToBanList(string IP) {
- RakNetPINVOKE.RakPeerInterface_AddToBanList__SWIG_1(swigCPtr, IP);
- }
- public virtual void RemoveFromBanList(string IP) {
- RakNetPINVOKE.RakPeerInterface_RemoveFromBanList(swigCPtr, IP);
- }
- public virtual void ClearBanList() {
- RakNetPINVOKE.RakPeerInterface_ClearBanList(swigCPtr);
- }
- public virtual bool IsBanned(string IP) {
- bool ret = RakNetPINVOKE.RakPeerInterface_IsBanned(swigCPtr, IP);
- return ret;
- }
- public virtual void SetLimitIPConnectionFrequency(bool b) {
- RakNetPINVOKE.RakPeerInterface_SetLimitIPConnectionFrequency(swigCPtr, b);
- }
- public virtual void Ping(SystemAddress target) {
- RakNetPINVOKE.RakPeerInterface_Ping__SWIG_0(swigCPtr, SystemAddress.getCPtr(target));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual bool Ping(string host, ushort remotePort, bool onlyReplyOnAcceptingConnections, uint connectionSocketIndex) {
- bool ret = RakNetPINVOKE.RakPeerInterface_Ping__SWIG_1(swigCPtr, host, remotePort, onlyReplyOnAcceptingConnections, connectionSocketIndex);
- return ret;
- }
- public virtual bool Ping(string host, ushort remotePort, bool onlyReplyOnAcceptingConnections) {
- bool ret = RakNetPINVOKE.RakPeerInterface_Ping__SWIG_2(swigCPtr, host, remotePort, onlyReplyOnAcceptingConnections);
- return ret;
- }
- public virtual int GetAveragePing(AddressOrGUID systemIdentifier) {
- int ret = RakNetPINVOKE.RakPeerInterface_GetAveragePing(swigCPtr, AddressOrGUID.getCPtr(systemIdentifier));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual int GetLastPing(AddressOrGUID systemIdentifier) {
- int ret = RakNetPINVOKE.RakPeerInterface_GetLastPing(swigCPtr, AddressOrGUID.getCPtr(systemIdentifier));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual int GetLowestPing(AddressOrGUID systemIdentifier) {
- int ret = RakNetPINVOKE.RakPeerInterface_GetLowestPing(swigCPtr, AddressOrGUID.getCPtr(systemIdentifier));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual void SetOccasionalPing(bool doPing) {
- RakNetPINVOKE.RakPeerInterface_SetOccasionalPing(swigCPtr, doPing);
- }
- public virtual void SetOfflinePingResponse(string data, uint length) {
- RakNetPINVOKE.RakPeerInterface_SetOfflinePingResponse__SWIG_0(swigCPtr, data, length);
- }
- public virtual SystemAddress GetInternalID(SystemAddress systemAddress, int index) {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetInternalID__SWIG_0(swigCPtr, SystemAddress.getCPtr(systemAddress), index), true);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual SystemAddress GetInternalID(SystemAddress systemAddress) {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetInternalID__SWIG_1(swigCPtr, SystemAddress.getCPtr(systemAddress)), true);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual SystemAddress GetInternalID() {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetInternalID__SWIG_2(swigCPtr), true);
- return ret;
- }
- public virtual SystemAddress GetExternalID(SystemAddress target) {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetExternalID(swigCPtr, SystemAddress.getCPtr(target)), true);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual RakNetGUID GetMyGUID() {
- RakNetGUID ret = new RakNetGUID(RakNetPINVOKE.RakPeerInterface_GetMyGUID(swigCPtr), true);
- return ret;
- }
- public virtual SystemAddress GetMyBoundAddress(int socketIndex) {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetMyBoundAddress__SWIG_0(swigCPtr, socketIndex), true);
- return ret;
- }
- public virtual SystemAddress GetMyBoundAddress() {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetMyBoundAddress__SWIG_1(swigCPtr), true);
- return ret;
- }
- public static ulong Get64BitUniqueRandomNumber() {
- ulong ret = RakNetPINVOKE.RakPeerInterface_Get64BitUniqueRandomNumber();
- return ret;
- }
- public virtual RakNetGUID GetGuidFromSystemAddress(SystemAddress input) {
- RakNetGUID ret = new RakNetGUID(RakNetPINVOKE.RakPeerInterface_GetGuidFromSystemAddress(swigCPtr, SystemAddress.getCPtr(input)), false);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual SystemAddress GetSystemAddressFromGuid(RakNetGUID input) {
- SystemAddress ret = new SystemAddress(RakNetPINVOKE.RakPeerInterface_GetSystemAddressFromGuid(swigCPtr, RakNetGUID.getCPtr(input)), true);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual bool GetClientPublicKeyFromSystemAddress(SystemAddress input, string client_public_key) {
- bool ret = RakNetPINVOKE.RakPeerInterface_GetClientPublicKeyFromSystemAddress(swigCPtr, SystemAddress.getCPtr(input), client_public_key);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual void SetTimeoutTime(uint timeMS, SystemAddress target) {
- RakNetPINVOKE.RakPeerInterface_SetTimeoutTime(swigCPtr, timeMS, SystemAddress.getCPtr(target));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual uint GetTimeoutTime(SystemAddress target) {
- uint ret = RakNetPINVOKE.RakPeerInterface_GetTimeoutTime(swigCPtr, SystemAddress.getCPtr(target));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual int GetMTUSize(SystemAddress target) {
- int ret = RakNetPINVOKE.RakPeerInterface_GetMTUSize(swigCPtr, SystemAddress.getCPtr(target));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual uint GetNumberOfAddresses() {
- uint ret = RakNetPINVOKE.RakPeerInterface_GetNumberOfAddresses(swigCPtr);
- return ret;
- }
- public virtual string GetLocalIP(uint index) {
- string ret = RakNetPINVOKE.RakPeerInterface_GetLocalIP(swigCPtr, index);
- return ret;
- }
- public virtual bool IsLocalIP(string ip) {
- bool ret = RakNetPINVOKE.RakPeerInterface_IsLocalIP(swigCPtr, ip);
- return ret;
- }
- public virtual void AllowConnectionResponseIPMigration(bool allow) {
- RakNetPINVOKE.RakPeerInterface_AllowConnectionResponseIPMigration(swigCPtr, allow);
- }
- public virtual bool AdvertiseSystem(string host, ushort remotePort, string data, int dataLength, uint connectionSocketIndex) {
- bool ret = RakNetPINVOKE.RakPeerInterface_AdvertiseSystem__SWIG_0(swigCPtr, host, remotePort, data, dataLength, connectionSocketIndex);
- return ret;
- }
- public virtual bool AdvertiseSystem(string host, ushort remotePort, string data, int dataLength) {
- bool ret = RakNetPINVOKE.RakPeerInterface_AdvertiseSystem__SWIG_1(swigCPtr, host, remotePort, data, dataLength);
- return ret;
- }
- public virtual void SetSplitMessageProgressInterval(int interval) {
- RakNetPINVOKE.RakPeerInterface_SetSplitMessageProgressInterval(swigCPtr, interval);
- }
- public virtual int GetSplitMessageProgressInterval() {
- int ret = RakNetPINVOKE.RakPeerInterface_GetSplitMessageProgressInterval(swigCPtr);
- return ret;
- }
- public virtual void SetUnreliableTimeout(uint timeoutMS) {
- RakNetPINVOKE.RakPeerInterface_SetUnreliableTimeout(swigCPtr, timeoutMS);
- }
- public virtual void SendTTL(string host, ushort remotePort, int ttl, uint connectionSocketIndex) {
- RakNetPINVOKE.RakPeerInterface_SendTTL__SWIG_0(swigCPtr, host, remotePort, ttl, connectionSocketIndex);
- }
- public virtual void SendTTL(string host, ushort remotePort, int ttl) {
- RakNetPINVOKE.RakPeerInterface_SendTTL__SWIG_1(swigCPtr, host, remotePort, ttl);
- }
- public virtual void AttachPlugin(PluginInterface2 plugin) {
- RakNetPINVOKE.RakPeerInterface_AttachPlugin(swigCPtr, PluginInterface2.getCPtr(plugin));
- }
- public virtual void DetachPlugin(PluginInterface2 messageHandler) {
- RakNetPINVOKE.RakPeerInterface_DetachPlugin(swigCPtr, PluginInterface2.getCPtr(messageHandler));
- }
- public virtual void PushBackPacket(Packet packet, bool pushAtHead) {
- RakNetPINVOKE.RakPeerInterface_PushBackPacket(swigCPtr, Packet.getCPtr(packet), pushAtHead);
- }
- public virtual void ChangeSystemAddress(RakNetGUID guid, SystemAddress systemAddress) {
- RakNetPINVOKE.RakPeerInterface_ChangeSystemAddress(swigCPtr, RakNetGUID.getCPtr(guid), SystemAddress.getCPtr(systemAddress));
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- }
- public virtual Packet AllocatePacket(uint dataSize) {
- IntPtr cPtr = RakNetPINVOKE.RakPeerInterface_AllocatePacket(swigCPtr, dataSize);
- Packet ret = (cPtr == IntPtr.Zero) ? null : new Packet(cPtr, false);
- return ret;
- }
- public virtual void WriteOutOfBandHeader(BitStream bitStream) {
- RakNetPINVOKE.RakPeerInterface_WriteOutOfBandHeader(swigCPtr, BitStream.getCPtr(bitStream));
- }
- public virtual void ApplyNetworkSimulator(float packetloss, ushort minExtraPing, ushort extraPingVariance) {
- RakNetPINVOKE.RakPeerInterface_ApplyNetworkSimulator(swigCPtr, packetloss, minExtraPing, extraPingVariance);
- }
- public virtual void SetPerConnectionOutgoingBandwidthLimit(uint maxBitsPerSecond) {
- RakNetPINVOKE.RakPeerInterface_SetPerConnectionOutgoingBandwidthLimit(swigCPtr, maxBitsPerSecond);
- }
- public virtual bool IsNetworkSimulatorActive() {
- bool ret = RakNetPINVOKE.RakPeerInterface_IsNetworkSimulatorActive(swigCPtr);
- return ret;
- }
- public virtual RakNetStatistics GetStatistics(SystemAddress systemAddress, RakNetStatistics rns) {
- IntPtr cPtr = RakNetPINVOKE.RakPeerInterface_GetStatistics__SWIG_0(swigCPtr, SystemAddress.getCPtr(systemAddress), RakNetStatistics.getCPtr(rns));
- RakNetStatistics ret = (cPtr == IntPtr.Zero) ? null : new RakNetStatistics(cPtr, false);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual RakNetStatistics GetStatistics(SystemAddress systemAddress) {
- IntPtr cPtr = RakNetPINVOKE.RakPeerInterface_GetStatistics__SWIG_1(swigCPtr, SystemAddress.getCPtr(systemAddress));
- RakNetStatistics ret = (cPtr == IntPtr.Zero) ? null : new RakNetStatistics(cPtr, false);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public virtual bool GetStatistics(int index, RakNetStatistics rns) {
- bool ret = RakNetPINVOKE.RakPeerInterface_GetStatistics__SWIG_2(swigCPtr, index, RakNetStatistics.getCPtr(rns));
- return ret;
- }
- public virtual uint GetReceiveBufferSize() {
- uint ret = RakNetPINVOKE.RakPeerInterface_GetReceiveBufferSize(swigCPtr);
- return ret;
- }
- public virtual bool SendOutOfBand(string host, ushort remotePort, string data, uint dataLength, uint connectionSocketIndex) {
- bool ret = RakNetPINVOKE.RakPeerInterface_SendOutOfBand__SWIG_0(swigCPtr, host, remotePort, data, dataLength, connectionSocketIndex);
- return ret;
- }
- public virtual bool SendOutOfBand(string host, ushort remotePort, string data, uint dataLength) {
- bool ret = RakNetPINVOKE.RakPeerInterface_SendOutOfBand__SWIG_1(swigCPtr, host, remotePort, data, dataLength);
- return ret;
- }
- public uint Send(byte[] inByteArray, int length, PacketPriority priority, PacketReliability reliability, char orderingChannel, AddressOrGUID systemIdentifier, bool broadcast) {
- uint ret = RakNetPINVOKE.RakPeerInterface_Send__SWIG_4(swigCPtr, inByteArray, length, (int)priority, (int)reliability, orderingChannel, AddressOrGUID.getCPtr(systemIdentifier), broadcast);
- if (RakNetPINVOKE.SWIGPendingException.Pending) throw RakNetPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- public void SendLoopback(byte[] inByteArray, int length) {
- RakNetPINVOKE.RakPeerInterface_SendLoopback__SWIG_1(swigCPtr, inByteArray, length);
- }
- public void SetOfflinePingResponse(byte[] inByteArray, uint length) {
- RakNetPINVOKE.RakPeerInterface_SetOfflinePingResponse__SWIG_1(swigCPtr, inByteArray, length);
- }
- public bool AdvertiseSystem(string host, ushort remotePort, byte[] inByteArray, int dataLength, uint connectionSocketIndex) {
- bool ret = RakNetPINVOKE.RakPeerInterface_AdvertiseSystem__SWIG_2(swigCPtr, host, remotePort, inByteArray, dataLength, connectionSocketIndex);
- return ret;
- }
- public bool AdvertiseSystem(string host, ushort remotePort, byte[] inByteArray, int dataLength) {
- bool ret = RakNetPINVOKE.RakPeerInterface_AdvertiseSystem__SWIG_3(swigCPtr, host, remotePort, inByteArray, dataLength);
- return ret;
- }
- private string CSharpGetIncomingPasswordHelper(string passwordData, ref int passwordDataLength) {
- string ret = RakNetPINVOKE.RakPeerInterface_CSharpGetIncomingPasswordHelper(swigCPtr, passwordData, ref passwordDataLength);
- return ret;
- }
- public void SetIncomingPassword(byte[] passwordDataByteArray, int passwordDataLength) {
- RakNetPINVOKE.RakPeerInterface_SetIncomingPassword__SWIG_1(swigCPtr, passwordDataByteArray, passwordDataLength);
- }
- public void GetIncomingPassword(byte[] passwordDataByteArray, ref int passwordDataLength) {
- RakNetPINVOKE.RakPeerInterface_GetIncomingPassword(swigCPtr, passwordDataByteArray, ref passwordDataLength);
- }
- private void CSharpGetOfflinePingResponseHelper(byte[] inOutByteArray, out uint outLength) {
- RakNetPINVOKE.RakPeerInterface_CSharpGetOfflinePingResponseHelper(swigCPtr, inOutByteArray, out outLength);
- }
- public bool GetConnectionList(RakNetListSystemAddress remoteSystems, ref ushort numberOfSystems) {
- bool ret = RakNetPINVOKE.RakPeerInterface_GetConnectionList(swigCPtr, RakNetListSystemAddress.getCPtr(remoteSystems), ref numberOfSystems);
- return ret;
- }
- }
- }
|