Access over 20 million homework & study documents

Report

Content type
User Generated
Rating
Showing Page:
1/4
Report:
This report subtleties the fulfillment of our Othello program concerning the
fundamental and extra prerequisites, the plan and execution of the
program and any known issues with the last program. Notwithstanding this
report, every part has presented an individual report enumerating their
group commitments, outline of provenance expressing which pieces of
code they composed and any individual issues they encountered and how
they addressed them.
Implementation Details
Our program has finished every one of the essential, simple and medium
details. We have likewise added network play and different AI challenges as
a hard expansion.
Fundamental:
Implement game mechanics in AI.hs where in borad the execution happens
Our fundamental game works with setting and catching pieces. Our
principle strategy to catch pieces is to check each of the 8 bearings and
produce a rundown of positions in those ways for pieces that ought to be
flipped. The rundowns are created by circling through until we either get to
the furthest limit of the board around there or we see a piece that is a
similar shading. In the event that it gets as far as possible without
discovering a piece of a similar shading then a vacant rundown is returned
as not pieces are flipped, else it stops once it sees a piece of similar shading
and returns a rundown of the multitude of positions before it halted. At
that point with each of the 8 records from the 8 headings, we flip each
piece in those positions.
For setting pieces, we straightforward watch that that position doesn't as of
now contain a piece and that the move will make pieces be flipped by
checking the length of the posList.
Implement the designs
We had drawing with gleam pictures by drawing a huge square as the
board and lines to divide each positions. The pieces were simply filled
circles that were either dark or white. Be that as it may, since we have
moved attracting to utilize bitmaps, none of the code for drawing gleam
pictures is in the last accommodation.
See bitmaps

Sign up to view the full document!

lock_open Sign Up
Showing Page:
2/4
Implement suitable occasion overseers
When clicking, we first watch that the spot clicked isn't outside the board.
At first we had a bug with players having the option to put pieces outside of
the drawn board so this check forestalls that.
Next we need to utilize either the makeMove capacity or startMove work.
startmove is utilized for reversi start, which permits players to pick where to
put their 2 beginning pieces toward the beginning of the game.
The capacities snapX and snapY convert the mouse arranges that are
tapped on screen to framework organizes that are utilized in our back end.
On the off chance that the move clicked is substantial, handleInput will
return the world with the new move made.
Similarly we have watches for the various keys a player could press to
change the alternatives in game or do in game activities, for example,
restart the game or save the game.
Implement a move generator and assessment in AI.hs
Our move generator basically returns the rundown of accessible positions.
It is hard to create just moves that are acceptable in the generator, so how
great moves are is resolved in the assess capacity and terrible moves are
not sifted through in the move generator as the point of this strategy is to
track down every one of the potential moves, not the best.
Our AI utilizes a minimax tree search to get the most ideal move. He
expects the adversary will likewise take the most ideal action for them as
indicated by his calculation.
assessment work is a heuristic. We give the corner positions a higher worth and
the situations close to corners a negative worth. The sides of the board additionally
get a somewhat higher worth. In any case each piece he controls gets one worth.
Losing the game additionally gives an incredibly adverse worth, so he will consistently
attempt to abstain from losing on the off chance that he can see the finish of the
game. This is so that will focus on taking the corners and sides, while compelling his
adversaries to take the situations close to the corners. These qualities are fairly
subjective yet appears to do truly well during our play testing, though he wasn't doing
a long time before we added these heuristics to his assessment. On the off chance
that we had additional time we would have jumped at the chance to of added various
forms of with various weightings for various styles of play.

Sign up to view the full document!

lock_open Sign Up
Showing Page:
3/4

Sign up to view the full document!

lock_open Sign Up
End of Preview - Want to read all 4 pages?
Access Now
Unformatted Attachment Preview
Report: This report subtleties the fulfillment of our Othello program concerning the fundamental and extra prerequisites, the plan and execution of the program and any known issues with the last program. Notwithstanding this report, every part has presented an individual report enumerating their group commitments, outline of provenance expressing which pieces of code they composed and any individual issues they encountered and how they addressed them. Implementation Details Our program has finished every one of the essential, simple and medium details. We have likewise added network play and different AI challenges as a hard expansion. Fundamental: • Implement game mechanics in AI.hs where in borad the execution happens ◦ Our fundamental game works with setting and catching pieces. Our principle strategy to catch pieces is to check each of the 8 bearings and produce a rundown of positions in those ways for pieces that ought to be flipped. The rundowns are created by circling through until we either get to the furthest limit of the board around there or we see a piece that is a similar shading. In the event that it gets as far as possible without discovering a piece of a similar ...
Purchase document to see full attachment
User generated content is uploaded by users for the purposes of learning and should be used following Studypool's honor code & terms of service.

Anonymous
I was struggling with this subject, and this helped me a ton!

Studypool
4.7
Trustpilot
4.5
Sitejabber
4.4

Similar Documents