From b67168134b7f48c49bdace4849491c34114a79a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20L=C3=BChne?= Date: Sat, 13 Aug 2016 03:22:25 +0200 Subject: [PATCH] Made initial state definition consistent with unified output format. --- src/plasp/pddl/TranslatorASP.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/plasp/pddl/TranslatorASP.cpp b/src/plasp/pddl/TranslatorASP.cpp index d598283..e3c5475 100644 --- a/src/plasp/pddl/TranslatorASP.cpp +++ b/src/plasp/pddl/TranslatorASP.cpp @@ -497,7 +497,15 @@ void TranslatorASP::translateInitialState() const // Translate single predicate if (fact->expressionType() == Expression::Type::Predicate) - this->translatePredicate(dynamic_cast(*fact)); + { + const auto &predicate = dynamic_cast(*fact); + + m_outputStream << utils::Keyword("variable") << "("; + this->translatePredicate(predicate); + m_outputStream << "), " << utils::Keyword("value") << "("; + this->translatePredicate(predicate); + m_outputStream << ", " << utils::Keyword("true") << ")"; + } // Assuming that "not" expression may only contain a predicate else if (fact->expressionType() == Expression::Type::Not) {