mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-08-09 20:24:16 +00:00
.github
cmake
dAuthServer
dChatFilter
dChatServer
dCommon
dDatabase
dGame
dMasterServer
dNavigation
dNet
dPhysics
dScripts
dServer
dWorldServer
dZoneManager
docs
migrations
resources
tests
thirdparty
MD5
SQLite
cpplinq
libbcrypt
magic_enum
mariadb-connector-cpp
mongoose
nlohmann
raknet
Lib
Source
AsynchronousFileIO.cpp
AsynchronousFileIO.h
AutoRPC.cpp
AutoRPC.h
AutopatcherPatchContext.h
AutopatcherRepositoryInterface.h
BigTypes.h
BitStream.cpp
BitStream.h
BitStream_NoTemplate.cpp
BitStream_NoTemplate.h
CheckSum.cpp
CheckSum.h
ClientContextStruct.h
CommandParserInterface.cpp
CommandParserInterface.h
ConnectionGraph.cpp
ConnectionGraph.h
ConsoleServer.cpp
ConsoleServer.h
DS_BPlusTree.h
DS_BinarySearchTree.h
DS_BytePool.cpp
DS_BytePool.h
DS_ByteQueue.cpp
DS_ByteQueue.h
DS_Heap.h
DS_HuffmanEncodingTree.cpp
DS_HuffmanEncodingTree.h
DS_HuffmanEncodingTreeFactory.h
DS_HuffmanEncodingTreeNode.h
DS_LinkedList.h
DS_List.h
DS_Map.h
DS_MemoryPool.h
DS_OrderedChannelHeap.h
DS_OrderedList.h
DS_Queue.h
DS_QueueLinkedList.h
DS_RangeList.h
DS_Table.cpp
DS_Table.h
DS_Tree.h
DS_WeightedGraph.h
DataBlockEncryptor.cpp
DataBlockEncryptor.h
DataCompressor.cpp
DataCompressor.h
DirectoryDeltaTransfer.cpp
DirectoryDeltaTransfer.h
EmailSender.cpp
EmailSender.h
EncodeClassName.cpp
EpochTimeToString.cpp
EpochTimeToString.h
Export.h
ExtendedOverlappedPool.cpp
ExtendedOverlappedPool.h
FileList.cpp
FileList.h
FileListTransfer.cpp
FileListTransfer.h
FileListTransferCBInterface.h
FileOperations.cpp
FileOperations.h
FormatString.cpp
FormatString.h
FullyConnectedMesh.cpp
FullyConnectedMesh.h
FunctionThread.cpp
FunctionThread.h
Gen_RPC8.cpp
Gen_RPC8.h
GetTime.cpp
GetTime.h
GridSectorizer.cpp
GridSectorizer.h
HTTPConnection.cpp
HTTPConnection.h
InlineFunctor.cpp
InlineFunctor.h
InternalPacket.h
Itoa.cpp
Itoa.h
Kbhit.h
LightweightDatabaseClient.cpp
LightweightDatabaseClient.h
LightweightDatabaseCommon.cpp
LightweightDatabaseCommon.h
LightweightDatabaseServer.cpp
LightweightDatabaseServer.h
LinuxStrings.cpp
LinuxStrings.h
LogCommandParser.cpp
LogCommandParser.h
MTUSize.h
Makefile.am
MessageFilter.cpp
MessageFilter.h
MessageIdentifiers.h
NatPunchthrough.cpp
NatPunchthrough.h
NetworkIDManager.cpp
NetworkIDManager.h
NetworkIDObject.cpp
NetworkIDObject.h
PacketConsoleLogger.cpp
PacketConsoleLogger.h
PacketFileLogger.cpp
PacketFileLogger.h
PacketLogger.cpp
PacketLogger.h
PacketPriority.h
PluginInterface.cpp
PluginInterface.h
RPCMap.cpp
RPCMap.h
RPCNode.h
RSACrypt.h
RakAssert.h
RakMemoryOverride.cpp
RakMemoryOverride.h
RakNet.vcproj
RakNet3.0.vcproj
RakNetCommandParser.cpp
RakNetCommandParser.h
RakNetDefines.h
RakNetStatistics.cpp
RakNetStatistics.h
RakNetTransport.cpp
RakNetTransport.h
RakNetTypes.cpp
RakNetTypes.h
RakNetVersion.h
RakNet_vc8.vcproj
RakNetworkFactory.cpp
RakNetworkFactory.h
RakPeer.cpp
RakPeer.h
RakPeerInterface.h
RakSleep.cpp
RakSleep.h
RakString.cpp
RakString.h
RakThread.cpp
RakThread.h
Rand.cpp
Rand.h
ReadyEvent.cpp
ReadyEvent.h
RefCountedObj.h
ReliabilityLayer.cpp
ReliabilityLayer.h
Replica.h
ReplicaEnums.h
ReplicaManager.cpp
ReplicaManager.h
ReplicaManager2.cpp
ReplicaManager2.h
Rijndael-Boxes.h
Rijndael.h
Router.cpp
Router.h
RouterInterface.h
SHA1.cpp
SHA1.h
SimpleMutex.cpp
SimpleMutex.h
SimpleTCPServer.h
SingleProducerConsumer.h
SocketLayer.cpp
SocketLayer.h
StringCompressor.cpp
StringCompressor.h
StringTable.cpp
StringTable.h
SuperFastHash.cpp
SuperFastHash.h
SystemAddressList.cpp
SystemAddressList.h
TCPInterface.cpp
TCPInterface.h
TableSerializer.cpp
TableSerializer.h
TelnetTransport.cpp
TelnetTransport.h
ThreadPool.h
ThreadsafePacketLogger.cpp
ThreadsafePacketLogger.h
TransportInterface.h
Types.h
_FindFirst.cpp
_FindFirst.h
rijndael.cpp
CMakeLists.txt
version.txt
recastnavigation
tinyxml2
CMakeLists.txt
vanity
.dockerignore
.editorconfig
.env.example
.git-blame-ignore-revs
.gitattributes
.gitignore
.gitmodules
CMakeLists.txt
CMakePresets.json
CMakeVariables.txt
CONTRIBUTING.md
Dockerfile
LICENSE
README.md
SECURITY.md
build.sh
docker-compose.yml
entrypoint.sh
logo.png
systemd.example
versions.txt
61 lines
2.7 KiB
C++
61 lines
2.7 KiB
C++
/// \file
|
|
/// \brief Contains RakNetCommandParser , used to send commands to an instance of RakPeer
|
|
///
|
|
/// This file is part of RakNet Copyright 2003 Kevin Jenkins.
|
|
///
|
|
/// Usage of RakNet is subject to the appropriate license agreement.
|
|
/// Creative Commons Licensees are subject to the
|
|
/// license found at
|
|
/// http://creativecommons.org/licenses/by-nc/2.5/
|
|
/// Single application licensees are subject to the license found at
|
|
/// http://www.jenkinssoftware.com/SingleApplicationLicense.html
|
|
/// Custom license users are subject to the terms therein.
|
|
/// GPL license users are subject to the GNU General Public
|
|
/// License as published by the Free
|
|
/// Software Foundation; either version 2 of the License, or (at your
|
|
/// option) any later version.
|
|
|
|
#ifndef __RAKNET_COMMAND_PARSER
|
|
#define __RAKNET_COMMAND_PARSER
|
|
|
|
#include "CommandParserInterface.h"
|
|
#include "Export.h"
|
|
class RakPeerInterface;
|
|
|
|
/// \brief This allows a console client to call most of the functions in RakPeer
|
|
class RAK_DLL_EXPORT RakNetCommandParser : public CommandParserInterface
|
|
{
|
|
public:
|
|
RakNetCommandParser();
|
|
~RakNetCommandParser();
|
|
|
|
/// Given \a command with parameters \a parameterList , do whatever processing you wish.
|
|
/// \param[in] command The command to process
|
|
/// \param[in] numParameters How many parameters were passed along with the command
|
|
/// \param[in] parameterList The list of parameters. parameterList[0] is the first parameter and so on.
|
|
/// \param[in] transport The transport interface we can use to write to
|
|
/// \param[in] systemAddress The player that sent this command.
|
|
/// \param[in] originalString The string that was actually sent over the network, in case you want to do your own parsing
|
|
bool OnCommand(const char *command, unsigned numParameters, char **parameterList, TransportInterface *transport, SystemAddress systemAddress, const char *originalString);
|
|
|
|
/// You are responsible for overriding this function and returning a static string, which will identifier your parser.
|
|
/// This should return a static string
|
|
/// \return The name that you return.
|
|
const char *GetName(void) const;
|
|
|
|
/// A callback for when you are expected to send a brief description of your parser to \a systemAddress
|
|
/// \param[in] transport The transport interface we can use to write to
|
|
/// \param[in] systemAddress The player that requested help.
|
|
void SendHelp(TransportInterface *transport, SystemAddress systemAddress);
|
|
|
|
/// Records the instance of RakPeer to perform the desired commands on
|
|
/// \param[in] rakPeer The RakPeer instance, or a derived class (e.g. RakPeer or RakPeer)
|
|
void SetRakPeerInterface(RakPeerInterface *rakPeer);
|
|
protected:
|
|
|
|
/// Which instance of RakPeer we are working on. Set from SetRakPeerInterface()
|
|
RakPeerInterface *peer;
|
|
};
|
|
|
|
#endif
|