Browse Source

Merge pull request #392 from DragonAura/dev

fix(CAPI): 🐛 fix wrong gate view
tags/0.1.0
shangfengh GitHub 2 years ago
parent
commit
36763166ed
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 4 deletions
  1. +2
    -4
      CAPI/cpp/API/src/logic.cpp

+ 2
- 4
CAPI/cpp/API/src/logic.cpp View File

@@ -564,7 +564,7 @@ void Logic::LoadBufferCase(const protobuf::MessageOfObj& item)
}
case THUAI6::MessageOfObj::GateMessage:
{
if (!AssistFunction::HaveView(viewRange, x, y, item.gate_message().x(), item.gate_message().y(), bufferState->gameMap))
if (AssistFunction::HaveView(viewRange, x, y, item.gate_message().x(), item.gate_message().y(), bufferState->gameMap))
{
auto pos = std::make_pair(AssistFunction::GridToCell(item.gate_message().x()), AssistFunction::GridToCell(item.gate_message().y()));
if (bufferState->mapInfo->gateState.count(pos) == 0)
@@ -695,9 +695,7 @@ void Logic::Main(CreateAIFunc createAI, std::string IP, std::string port, bool f
fileLogger->set_pattern(pattern);
printLogger->set_pattern(pattern);
if (file)
{
fileLogger->set_level(spdlog::level::trace);
}
fileLogger->set_level(spdlog::level::debug);
else
fileLogger->set_level(spdlog::level::off);
if (print)


Loading…
Cancel
Save