3 Commits

6 changed files with 55 additions and 13 deletions

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 128 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 22 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 40 KiB

View File

@@ -3,6 +3,28 @@ title: Avalam - Diagramme de classes (complet)
---
classDiagram
class ArenaGame{
+ArenaGame(IBoard board, AbstractGamePlayer bot1, AbstractGamePlayer bot2)
-createPlayerMap(AbstractGamePlayer bot1, AbstractGamePlayer bot2): EnumMap<Player, AbstractGamePlayer>
}
class ArenaWindow{
-resultsTable: JTable
-tableModel: DefaultTableModel
-results: List<string>
+ArenaWindows()
-createConfigPanel(): JPanel
-createResultsTable()
-showConfigDialog()
-runArena(String bot1Type, String bot2Type, int depth, int nbParties)
-createBot(String botType, Player player, int depth): AbstractGamePlayer
-getWinnerName(Result result, String bot1Type, String bot2Type): String
}
ArenaWindow *-- AvalamBoard
ArenaWindow *-- ArenaGame
class AvalamBoard{
+SIZE: int
-MAX_HEIGHT: int
@@ -42,8 +64,6 @@ classDiagram
+toString(): String
}
class AvalamWindow{
-board : AvalamBoard
@@ -70,13 +90,18 @@ classDiagram
AvalamWindow *-- BoardView
AvalamWindow *-- ScoreView
AvalamWindow *-- TurnView
AvalamWindow *-- EndGameDialog
AvalamWindow --> GameMode
class BackgroundLayer{
-img: Image
+BackgroundLayer(String resourcePath)
#paintComponent(Graphics g): void
}
class BoardLoader{
+loadFromFile(String resourcePath): Tower[][]
}
class BoardView{
-board: AvalamBoard
@@ -105,14 +130,6 @@ classDiagram
BoardView *-- InteractionController
BoardView --> AvalamBoard
class BackgroundLayer{
-img: Image
+BackgroundLayer(String resourcePath)
#paintComponent(Graphics g): void
}
class Color{
-YELLOW(int r, int g, int b)
-RED(int r, int g, int b)
@@ -122,11 +139,17 @@ classDiagram
+toPlayer(): fr.iut_fbleau.GameAPI.Player
}
class EndGameDialog{
+EndGameDialog(JFrame parent, Result result, int scoreJaune, int scoreRouge, GameMode mode, int depth, Runnable onReplay, Runnable onMenu, Runnable onQuit)
-modeToString(GameMode mode, int depth): String
}
class GameMode{
PVP
PVBOT
PVALPHA
PVGOD
PVGOD
ARENA
}
class HighlightLayer{
@@ -165,6 +188,7 @@ classDiagram
Main ..> AvalamWindow
Main ..> GameMode
Main ..> ArenaWindow
class PieceButton{
-color: java.awt.Color

View File

@@ -17,7 +17,16 @@ classDiagram
}
class DivineBot{
-me: Player
-maxDepth: int
-rng: Random
+DivineBot(Player p, int maxDepth)
+giveYourMove(IBoard board): AbstractPly
-alphaBeta(IBoard board, int depth, int alpha, int beta): int
-terminalValue(IBoard board): int
-evaluate(IBoard board): int
-listMoves(IBoard board): List<AbstractPly>
}
class IdiotBot{