Re: Introducing MankalaEngine
Albert Astals Cid <[email protected]> Tue, 23 Jul 2024 23:32:43 +0200
| Newsgroups | gmane.comp.kde.devel.games |
|---|---|
| Message-ID | <2800937.1YQoVHgtvk@xps15> |
El dimarts, 23 de juliol del 2024, a les 18:57:56 (CEST), Jo=C3=A3o Gouveia= va=20 escriure: > Hi everyone, >=20 > I've been developing MankalaEngine, a library for creating computerized > opponents for Mancala games, as part of my GSoC project. >=20 > In the coming weeks, I'll be developing a GUI for playing Mancala that us= es > this engine, with the objective of integrating both projects into KDE. >=20 > You can check out the library at MankalaEngine > <https://invent.kde.org/joaotgouveia/mankalaengine>. Any feedback is > greatly appreciated. Good work! Runinng make install installs the wrong things=20 https://pastebin.com/raw/1PS1kczY You probably want to rename some of the functions that return bool to isXXX= ,=20 see these two functions finishGame gameOver by the name it would seem they both do almost the same? Now if the second is called=20 isGameOver It's much clearer what it really does Same for validMove, with that name it would seem it's part of some hint sys= tem=20 that will return a valid move, while if the name is isValidMode, it's much= =20 clearer that you give it a move and returns yes/no. If the idea is making this a public library (as oposed as something that wi= ll=20 just live inside the game itself) it is possible a good idea to use d-point= er/ pimpl for the classes, i.e. Rules should not have the private members direc= tly=20 in the class but hidden in a Private class, search the internet, there's=20 extensive documentation about that. Cheers, Albert >=20 > If you're interested, you can also check out my blog posts documenting the > library's development at joaotgouveia.com.