Browse Source

the agent cannot turn in lava

sp 10 months ago
parent
commit
5cda933b48
  1. 3
      util/PrismModulesPrinter.cpp

3
util/PrismModulesPrinter.cpp

@ -276,8 +276,9 @@ namespace prism {
std::string PrismModulesPrinter::printTurnGuard(const AgentName &a, const std::string &direction, const ActionId &actionId, const std::string &cond) { std::string PrismModulesPrinter::printTurnGuard(const AgentName &a, const std::string &direction, const ActionId &actionId, const std::string &cond) {
std::string actionName = "[" + a + "_turn_" + direction + "]"; std::string actionName = "[" + a + "_turn_" + direction + "]";
agentNameActionMap.at(a).insert({actionId, actionName}); agentNameActionMap.at(a).insert({actionId, actionName});
std::string guard = " " + actionName;
std::string guard = " " + actionName + " & ";
if(slipperyBehaviour()) guard += " !" + a + "IsOnSlippery & "; if(slipperyBehaviour()) guard += " !" + a + "IsOnSlippery & ";
if(anyLava) guard += " !" + a + "IsOnLava &";
guard += cond + " -> "; guard += cond + " -> ";
return guard; return guard;
} }

Loading…
Cancel
Save