feat: spoof bloodweb items
This commit is contained in:
@@ -215,7 +215,50 @@ void Spoofer::modifyCharacterData(json& js)
|
||||
}
|
||||
|
||||
if (js.contains("prestigeLevel") && js["prestigeLevel"].get<int>() <= 1)
|
||||
if (js.contains("bloodWebLevel") && js["bloodWebLevel"].get<int>() <= 15) js["bloodWebLevel"] = 15;
|
||||
if (js.contains("bloodWebLevel") && js["bloodWebLevel"].get<int>() <= 15) js["bloodWebLevel"] = 16;
|
||||
|
||||
if (js.contains("bloodWebData"))
|
||||
{
|
||||
std::vector<std::string> paths;
|
||||
json ringDataArray = json::array();
|
||||
|
||||
ringDataArray.push_back({{"nodeData", json::array({{{"nodeId", "0"}, {"state", "Collected"}}})}});
|
||||
|
||||
int nodesPerRing[] = {6, 12, 12};
|
||||
std::vector<std::string> prevRingNodes = {"0"};
|
||||
|
||||
for (int ring = 1; ring <= 3; ++ring)
|
||||
{
|
||||
json nodeDataArray = json::array();
|
||||
std::vector<std::string> currentRingNodes;
|
||||
int numNodes = nodesPerRing[ring - 1];
|
||||
|
||||
for (int i = 1; i <= numNodes; ++i)
|
||||
{
|
||||
std::string childId = std::to_string((ring * 100) + i);
|
||||
currentRingNodes.push_back(childId);
|
||||
|
||||
int parentIndex = (i - 1) / (numNodes / static_cast<int>(prevRingNodes.size()));
|
||||
|
||||
if (parentIndex >= prevRingNodes.size()) parentIndex = static_cast<int>(prevRingNodes.size()) - 1;
|
||||
|
||||
std::string parentId = prevRingNodes[parentIndex];
|
||||
paths.push_back(parentId + "_" + childId);
|
||||
|
||||
nodeDataArray.push_back(
|
||||
{{"nodeId", childId}, {"state", "Collected"}, {"contentId", "ADDON_toolbox_socketswivels"}});
|
||||
}
|
||||
|
||||
ringDataArray.push_back({{"nodeData", nodeDataArray}});
|
||||
prevRingNodes = std::move(currentRingNodes);
|
||||
}
|
||||
|
||||
js["bloodWebData"]["paths"] = paths;
|
||||
js["bloodWebData"]["ringData"] = ringDataArray;
|
||||
|
||||
js["bloodWebData"]["paths"] = paths;
|
||||
js["bloodWebData"]["ringData"] = ringDataArray;
|
||||
}
|
||||
|
||||
if (js.contains("characterItems") && js["characterItems"].is_array())
|
||||
{
|
||||
@@ -392,7 +435,7 @@ void Spoofer::serverResponseHandler(const std::string& url, std::string& body, s
|
||||
{
|
||||
if (charInfo.contains("bloodWebLevel") && charInfo.at("bloodWebLevel").get<int>() <= 15)
|
||||
if (!charInfo.contains("prestigeLevel") || charInfo.at("prestigeLevel").get<int>() <= 0)
|
||||
charInfo["bloodWebLevel"] = 15;
|
||||
charInfo["bloodWebLevel"] = 16;
|
||||
|
||||
if (charInfo.contains("bloodWebData") && charInfo.at("bloodWebData").contains("level"))
|
||||
charInfo["bloodWebData"]["level"] = 1;
|
||||
@@ -433,7 +476,7 @@ void Spoofer::serverResponseHandler(const std::string& url, std::string& body, s
|
||||
json mock;
|
||||
mock["bloodWebLevelChanged"] = false;
|
||||
mock["updatedWallets"] = json::array();
|
||||
mock["bloodWebLevel"] = 15;
|
||||
mock["bloodWebLevel"] = 16;
|
||||
mock["prestigeLevel"] = 0;
|
||||
mock["bloodWebData"] = {{"ringData", json::array()}, {"paths", json::array()}};
|
||||
mock["characterItems"] = json::array();
|
||||
|
||||
Reference in New Issue
Block a user