1 Commits

Author SHA1 Message Date
server
1eda856283 issue-4: expose biolog submit network helper 2026-04-16 17:26:51 +02:00
3 changed files with 15 additions and 1 deletions

View File

@@ -317,6 +317,7 @@ class CPythonNetworkStream : public CNetworkStream, public CSingleton<CPythonNet
// Main Game Phase
bool SendC2CPacket(DWORD dwSize, void * pData);
bool SendChatPacket(const char * c_szChat, BYTE byType = CHAT_TYPE_TALKING);
bool SendBiologSubmit();
bool SendWhisperPacket(const char * name, const char * c_szChat);
bool SendMessengerAddByVIDPacket(DWORD vid);
bool SendMessengerAddByNamePacket(const char * c_szName);

View File

@@ -499,6 +499,13 @@ PyObject* netSendChatPacket(PyObject* poSelf, PyObject* poArgs)
return Py_BuildNone();
}
PyObject* netSendBiologSubmit(PyObject* poSelf, PyObject* poArgs)
{
CPythonNetworkStream& rkNetStream = CPythonNetworkStream::Instance();
rkNetStream.SendBiologSubmit();
return Py_BuildNone();
}
PyObject* netSendEmoticon(PyObject* poSelf, PyObject* poArgs)
{
int eEmoticon;
@@ -1700,6 +1707,7 @@ void initnet()
{ "IsConnect", netIsConnect, METH_VARARGS },
{ "SendChatPacket", netSendChatPacket, METH_VARARGS },
{ "SendBiologSubmit", netSendBiologSubmit, METH_VARARGS },
{ "SendEmoticon", netSendEmoticon, METH_VARARGS },
{ "SendWhisperPacket", netSendWhisperPacket, METH_VARARGS },

View File

@@ -788,6 +788,11 @@ bool CPythonNetworkStream::SendChatPacket(const char * c_szChat, BYTE byType)
return true;
}
bool CPythonNetworkStream::SendBiologSubmit()
{
return SendChatPacket("/biolog_submit");
}
//////////////////////////////////////////////////////////////////////////
// Emoticon
void CPythonNetworkStream::RegisterEmoticonString(const char * pcEmoticonString)
@@ -4357,4 +4362,4 @@ void CPythonNetworkStream::Discord_Close()
{
Discord_Shutdown();
}
#endif
#endif