Commit 71ff61a4 authored by Bernhard Rumpe's avatar Bernhard Rumpe
Browse files

BR-sy

parent fd95ebfe
Pipeline #175162 passed with stage
in 8 minutes and 38 seconds
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.coinSearch;
component CoinWeights {
......@@ -9,4 +10,4 @@ component CoinWeights {
buiscuitWeight = 50;
coinWeight = 200;
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.coinSearch;
component SearchCoinsBottom {
......@@ -34,4 +35,4 @@ component SearchCoinsBottom {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.coinSearch;
component SearchCoinsLeft {
......@@ -34,4 +35,4 @@ component SearchCoinsLeft {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.coinSearch;
component SearchCoinsRight {
......@@ -34,4 +35,4 @@ component SearchCoinsRight {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.coinSearch;
component SearchCoinsTop {
......@@ -34,4 +35,4 @@ component SearchCoinsTop {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.enemySearch;
component EnemyWeights {
......@@ -11,4 +12,4 @@ component EnemyWeights {
towardsPacMan = -10;
eatable = 5000;
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.enemySearch;
component SearchEnemiesBottom {
......@@ -42,4 +43,4 @@ component SearchEnemiesBottom {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.enemySearch;
component SearchEnemiesLeft {
......@@ -42,4 +43,4 @@ component SearchEnemiesLeft {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.enemySearch;
component SearchEnemiesRight {
......@@ -42,4 +43,4 @@ component SearchEnemiesRight {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.coneSearch.enemySearch;
component SearchEnemiesTop {
......@@ -42,4 +43,4 @@ component SearchEnemiesTop {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.decision;
// compares all values of the safe directions and takes the maximum
......@@ -66,4 +67,4 @@ component CompareValues {
end
newPacManDirection = newDirection;
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.decision;
// Main strategy
......@@ -43,4 +44,4 @@ component Decision {
connect intersection.interSectionReached -> verifyDirection.interSection;
connect compareValues.newPacManDirection -> verifyDirection.tryDirection;
connect verifyDirection.newPacManDirection -> newPacManDirection;
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.decision;
// check whether an intersection (3 or more non-blocked paths) is reached
......@@ -40,4 +41,4 @@ component NextIntersection {
end
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.decision;
// check which directions are not blocked
......@@ -45,4 +46,4 @@ component PossibleWays {
rightPossible = 0;
end
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.decision;
stream TestCompareValues for CompareValues {
......@@ -15,4 +16,4 @@ stream TestCompareValues for CompareValues {
rightPossible: 0 tick 0 tick 0 tick 0 tick 1 tick 1;
newPacManDirection: 0 tick 0 tick 1 tick 1 tick 2 tick 3;
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.heithoff2.decision;
component VerifyDirection {
......@@ -47,4 +48,4 @@ component VerifyDirection {
lastDirection = newPacManDirection;
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
// see https://github.com/daleharvey/pacman/blob/master/pacman.js#L28
package de.rwth.pacman.structs;
......@@ -8,4 +9,4 @@ struct Ghost {
Z (0 : 1 : 3) dir;
B eatable;
B eaten;
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.structs;
import de.rwth.pacman.structs.Ghost;
......@@ -18,4 +19,4 @@ component GhostFactory {
ghost.eatable = Eatable;
ghost.eaten = Eaten;
}
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
// see https://github.com/daleharvey/pacman/blob/master/pacman.js#L281
// we do not need `direction` and `due` as input, as `direction` is output and `due` is only for the game
......@@ -11,4 +12,4 @@ struct PacManData {
// but then we are dead, and so the
// controller is not invoked anymore
Z(0:oo) score;
}
\ No newline at end of file
}
/* (c) https://github.com/MontiCore/monticore */
package de.rwth.pacman.structs;
import de.rwth.pacman.structs.PacManData;
......@@ -18,4 +19,4 @@ component PacManDataFactory {
pacMan.lives = Lives;
pacMan.score = Score;
}
}
\ No newline at end of file
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment