Saataa andagii !
This commit is contained in:
parent
4775a751ab
commit
578575512c
2 changed files with 117 additions and 0 deletions
73
projet.use
Normal file
73
projet.use
Normal file
|
@ -0,0 +1,73 @@
|
|||
model projet_bataille_navale
|
||||
|
||||
enum TypeCase {
|
||||
Vide,
|
||||
Bateau,
|
||||
Touche,
|
||||
Rate
|
||||
}
|
||||
|
||||
enum TypeBateau {
|
||||
Torpilleur,
|
||||
Contre_Torpilleur,
|
||||
Croiseur,
|
||||
Porte_Avions
|
||||
}
|
||||
|
||||
enum TypeCoup {
|
||||
Rate,
|
||||
Touche,
|
||||
Touche_Coule
|
||||
}
|
||||
|
||||
enum EtatBateau {
|
||||
Operationnel,
|
||||
Coule
|
||||
}
|
||||
|
||||
class Jeu
|
||||
operations
|
||||
init(nom1: String,nom2: String): void
|
||||
debut(): void
|
||||
end
|
||||
|
||||
class Joueur
|
||||
attributes
|
||||
Nom: String
|
||||
operations
|
||||
tirer(case: String): TypeCoup
|
||||
tirerRobot(): TypeCoup
|
||||
end
|
||||
|
||||
class Flotte
|
||||
operations
|
||||
ajouterBateau(bateau: Bateau): void
|
||||
end
|
||||
|
||||
class TypeCoup
|
||||
attributes
|
||||
type: TypeCoup
|
||||
end
|
||||
|
||||
class Plateau
|
||||
operations
|
||||
afficherPlateau(CacherBateaux: Boolean): void
|
||||
end
|
||||
|
||||
class Case
|
||||
attributes
|
||||
x: Integer
|
||||
y: Integer
|
||||
type: TypeCase
|
||||
operations
|
||||
changerEtat(nouveauEtat: TypeCase): void
|
||||
getEtat(): TypeCase
|
||||
end
|
||||
|
||||
class Bateau
|
||||
attributes
|
||||
type: TypeBateau
|
||||
longueur: Integer
|
||||
Etat: EtatBateau
|
||||
end
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue