Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Games
KShisen
Commits
e3fc8690
Commit
e3fc8690
authored
May 10, 2016
by
Frederik Schwarzer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix drawing of first edge on 3-edge connections.
parent
d4a9594d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
1 deletion
+6
-1
src/board.cpp
src/board.cpp
+1
-1
src/possiblemove.cpp
src/possiblemove.cpp
+4
-0
src/possiblemove.h
src/possiblemove.h
+1
-0
No files found.
src/board.cpp
View file @
e3fc8690
...
...
@@ -1215,7 +1215,7 @@ int Board::findPath(TilePos const & tilePos1, TilePos const & tilePos2, Possible
int
tempY
=
tilePos1
.
y
()
+
dy
.
at
(
i
);
while
(
isValidPosWithOutline
(
TilePos
(
tempX
,
tempY
))
&&
field
(
TilePos
(
tempX
,
tempY
))
==
EMPTY
)
{
if
((
simplePath
=
findSimplePath
(
TilePos
(
tempX
,
tempY
),
tilePos2
,
possibleMoves
))
>
0
)
{
possibleMoves
.
back
().
path
().
prepend
(
tilePos1
);
possibleMoves
.
back
().
prepend
Tile
(
tilePos1
);
numberOfPaths
+=
simplePath
;
}
tempX
+=
dx
.
at
(
i
);
...
...
src/possiblemove.cpp
View file @
e3fc8690
...
...
@@ -96,6 +96,10 @@ Path PossibleMove::slide() const
{
return
m_slide
;
}
void
PossibleMove
::
prependTile
(
TilePos
const
tilePos
)
{
m_path
.
prepend
(
tilePos
);
}
}
// vim: expandtab:tabstop=4:shiftwidth=4
...
...
src/possiblemove.h
View file @
e3fc8690
...
...
@@ -44,6 +44,7 @@ public:
Path
path
()
const
;
bool
hasSlide
()
const
;
Path
slide
()
const
;
void
prependTile
(
TilePos
const
tilePos
);
private:
Path
m_path
;
///< path used to connect the two tiles
...
...
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