Package blockly_robot.robot.logic
Class Task
java.lang.Object
blockly_robot.robot.logic.Task
Eine Trainingsaufgabe (Task) besteht aus mehreren (in der Regel 3)
Schwierigkeitsgraden (Difficulty). Ein Schwierigkeitsgrad kann einen oder
mehrere Tests (Level) haben.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringextractTaskPath(String path) booleanReturns the background color.intReturns the grid color.getData()getIntro()getLevel()Returns the first version of a training task with the easiest difficultygetLevel(int difficulty) Retrieves the level based on the given difficulty.getLevel(Difficulty difficulty) Returns the level associated with the given difficulty.getLevel(Difficulty difficulty, int test) Retrieves the level for a given difficulty and test.Returns a map of difficulty levels and their corresponding list of levels.intDie Anzahl der Kacheln einer Spalte, des Tests (Level) mit der größten horizontalen Ausdehnung.intintDie Anzahl der Tests des Schwierigkeitsgrads mit den meisten Tests.intDie Anzahl der Kacheln einer Zeile, des Tests (Level) mit der größten vertikalen Ausdehnung.intintDie Anzahl an Schwierigkeitsgraden (In der Regel 3).intDie Anzahl aller Tests (Level).getTitle()Returns the virtual robot of the first version of a training task with the easiest difficulty. / Gibt einen virtuellen Roboter der erste Version einer Trainingsaufgabe mit dem leichtesten Schwierigkeitsgrad zurück.booleanstatic TaskloadByTaskPath(String taskPath)
-
Constructor Details
-
Task
-
-
Method Details
-
loadByTaskPath
- Parameters:
taskPath- Der relative Pfad zu resources/data/tasks
-
extractTaskPath
-
getTaskPath
-
getData
-
getTitle
-
getIntro
-
getItemCreator
-
getBorderColor
Returns the grid color.- Returns:
- the grid color as a String.
-
getBackgroundColor
Returns the background color.- Returns:
- the background color as a String.
-
getBagSize
public int getBagSize() -
getMaxFallAltitude
public int getMaxFallAltitude() -
getNbPlatforms
public int getNbPlatforms() -
getLevels
Returns a map of difficulty levels and their corresponding list of levels.- Returns:
- the map of difficulty levels and their corresponding list of levels
-
getLevel
Retrieves the level for a given difficulty and test.- Parameters:
difficulty- the difficulty of the tasktest- the test index (0 is the first test)- Returns:
- the level corresponding to the given difficulty and test
-
getLevel
Returns the level associated with the given difficulty.- Parameters:
difficulty- the difficulty of the task- Returns:
- the level associated with the difficulty
-
getLevel
Retrieves the level based on the given difficulty.- Parameters:
difficulty- the difficulty level as an integer (0 is easy, 1 is medium, 2 is hard)- Returns:
- the corresponding level
-
getLevel
Returns the first version of a training task with the easiest difficulty. / Gibt die erste Version einer Trainingsaufgabe mit dem leichtesten Schwierigkeitsgrad zurück. -
getLevelCollection
-
getContextData
-
getVirtualRobot
Returns the virtual robot of the first version of a training task with the easiest difficulty. / Gibt einen virtuellen Roboter der erste Version einer Trainingsaufgabe mit dem leichtesten Schwierigkeitsgrad zurück. -
getMaxCols
public int getMaxCols()Die Anzahl der Kacheln einer Spalte, des Tests (Level) mit der größten horizontalen Ausdehnung. -
getMaxRows
public int getMaxRows()Die Anzahl der Kacheln einer Zeile, des Tests (Level) mit der größten vertikalen Ausdehnung. -
getNumberOfDifficulties
public int getNumberOfDifficulties()Die Anzahl an Schwierigkeitsgraden (In der Regel 3). -
getMaxLevelsPerDifficulty
public int getMaxLevelsPerDifficulty()Die Anzahl der Tests des Schwierigkeitsgrads mit den meisten Tests. -
getNumberOfLevels
public int getNumberOfLevels()Die Anzahl aller Tests (Level). -
hasGravity
public boolean hasGravity() -
getAutoWithdraw
public boolean getAutoWithdraw() -
getBagInit
-