Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
David LELIEVRE
projetS2-15-AL
Commits
dfbb28b4
Commit
dfbb28b4
authored
Jun 25, 2021
by
jwars62
Browse files
com
parent
f2832ca0
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/controleur/ButtonGrilleHautControleur.java
View file @
dfbb28b4
...
...
@@ -58,7 +58,7 @@ public class ButtonGrilleHautControleur implements ActionListener{
System
.
out
.
println
(
"\1:"
+
s
+
"\n2:"
+
n
[
0
]);
if
(
n
[
0
].
equals
(
s
)){
System
.
out
.
println
(
"ok:"
+
n
[
1
]);
log
.
tir_recu
(
n
[
1
]
,
recup
);
log
.
tir_recu
(
n
[
1
]);
}
}
}
...
...
src/vue/FenLog.java
View file @
dfbb28b4
...
...
@@ -1140,8 +1140,12 @@ public class FenLog extends JFrame{
* @param cible le bouton ciblé
* @throws BadCoordException
*/
public
void
tir_recu
(
String
pos
,
JButton
cible
)
throws
BadCoordException
{
IShip
ship
=
this
.
flotte
.
findShip
(
new
Coord
(
pos
));
public
void
tir_recu
(
String
pos
)
throws
BadCoordException
{
Coord
c
=
new
Coord
(
pos
);
IShip
ship
=
this
.
flotte
.
findShip
(
c
);
int
x
=
c
.
getX
();
int
y
=
c
.
getY
();
JButton
cible
=
this
.
buttonGrilleBas
[
x
-
1
][
y
-
1
];
if
(
ship
==
null
){
this
.
colorizeNone
(
cible
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment