Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
ChessProject
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
9631413
ChessProject
Commits
54114b5f
Commit
54114b5f
authored
May 18, 2019
by
hamed
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Relative Path
parent
5aa08fcb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
ChessFrame.java
src/Main/ChessFrame.java
+12
-12
No files found.
src/Main/ChessFrame.java
View file @
54114b5f
...
...
@@ -41,31 +41,31 @@ public class ChessFrame extends JFrame implements MouseListener, MouseMotionList
try
{
if
(
p
.
isWhite
())
{
if
(
p
instanceof
Bishop
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_blt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_blt60.png"
));
}
else
if
(
p
instanceof
King
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_klt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_klt60.png"
));
}
else
if
(
p
instanceof
Knight
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_nlt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_nlt60.png"
));
}
else
if
(
p
instanceof
Pawn
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_plt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_plt60.png"
));
}
else
if
(
p
instanceof
Queen
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_qlt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_qlt60.png"
));
}
else
if
(
p
instanceof
Rook
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_rlt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_rlt60.png"
));
}
}
else
{
if
(
p
instanceof
Bishop
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_bdt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_bdt60.png"
));
}
else
if
(
p
instanceof
King
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_kdt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_kdt60.png"
));
}
else
if
(
p
instanceof
Knight
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_ndt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_ndt60.png"
));
}
else
if
(
p
instanceof
Pawn
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_pdt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_pdt60.png"
));
}
else
if
(
p
instanceof
Queen
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_qdt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_qdt60.png"
));
}
else
if
(
p
instanceof
Rook
)
{
ret
=
ImageIO
.
read
(
new
File
(
"
D:/University/MyCodes/Intellij/ChessProject
/Chess/Chess_rdt60.png"
));
ret
=
ImageIO
.
read
(
new
File
(
"
.
/Chess/Chess_rdt60.png"
));
}
}
}
...
...
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