1
This commit is contained in:
parent
843b7a43e2
commit
38aca0f7ab
@ -23,6 +23,7 @@
|
|||||||
#include "jsondatamgr.h"
|
#include "jsondatamgr.h"
|
||||||
#include "player.h"
|
#include "player.h"
|
||||||
#include "httpproxy.h"
|
#include "httpproxy.h"
|
||||||
|
#include "bag.h"
|
||||||
|
|
||||||
#include "buff/distance_dmg_addition.h"
|
#include "buff/distance_dmg_addition.h"
|
||||||
|
|
||||||
@ -1453,19 +1454,15 @@ void BattleDataContext::UseItem(int item_id)
|
|||||||
});
|
});
|
||||||
if (rsp_obj->GetType() != a8::XOT_OBJECT ||
|
if (rsp_obj->GetType() != a8::XOT_OBJECT ||
|
||||||
!rsp_obj->HasKey("errcode")) {
|
!rsp_obj->HasKey("errcode")) {
|
||||||
//cb(1, "", nullptr);
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
int errcode = rsp_obj->Get("errcode", "").GetInt();
|
int errcode = rsp_obj->Get("errcode", "").GetInt();
|
||||||
std::string errmsg = rsp_obj->Get("errmsg", "").GetString();
|
std::string errmsg = rsp_obj->Get("errmsg", "").GetString();
|
||||||
|
int item_id = rsp_obj->Get("item_id", "").GetInt();
|
||||||
|
int item_num = rsp_obj->Get("item_num", "").GetInt();
|
||||||
if (errcode) {
|
if (errcode) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
std::string room_uuid = rsp_obj->Get("room_uuid", "").GetString();
|
|
||||||
if (room_uuid.empty()) {
|
|
||||||
//cb(1, "custom battle data error", nullptr);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
f8::UdpLog::Instance()->Warning
|
f8::UdpLog::Instance()->Warning
|
||||||
("UseBattleItem error room_uuid:%s account_id%s",
|
("UseBattleItem error room_uuid:%s account_id%s",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user