This commit is contained in:
2022-04-15 18:34:06 +08:00
parent e992233ba2
commit bd0d475b57
2 changed files with 9 additions and 3 deletions

View File

@@ -969,10 +969,12 @@ int squirrel::Get_Dragon_Pack(uint32_t v)
int squirrel::Redom_Dragon(uint32_t v)
{
int Type;
int Port;
int ParameterNum = SQGetTop(v);
if (ParameterNum == 2)
if (ParameterNum == 3)
{
SQGetInt(v, 2, &Type);
SQGetInt(v, 3, &Port);
rapidjson::StringBuffer buffer;
rapidjson::Writer<rapidjson::StringBuffer> writer(buffer);
@@ -983,8 +985,8 @@ int squirrel::Redom_Dragon(uint32_t v)
char* str = (char*)buffer.GetString();
_SendpacksType(*_SendClass, 0, 130);
_SendPacksChar(*_SendClass, 0, str,strlen(str));
_SendpacksType(*_SendClass, 0, Port);
_SendPacksChar(*_SendClass, 0, str, strlen(str));
_SendPacks();
}
else