Skip to content

Commit 4c10f47

Browse files
committed
corpo do readme, diagrama mvc, refatorando código
1 parent 4378e7d commit 4c10f47

File tree

5 files changed

+717
-5
lines changed

5 files changed

+717
-5
lines changed

README.md

Lines changed: 105 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,105 @@
1-
# Trab_OO2_Campo_Minado
2-
Repositório dedicado para o versionamento do campo minado desenvolvido usando os design patterns.
1+
<p align="center">
2+
<img alt="GitHub language count" src="https://img.shields.io/github/languages/count/MatMB115/minesweeper_mvc_patterns_com221?color=%2304D361">
3+
4+
<img alt="Repository size" src="https://img.shields.io/github/repo-size/MatMB115/minesweeper_mvc_patterns_com221">
5+
6+
<a href="https://github.com/MatMB115/minesweeper_mvc_patterns_com221/commits/main">
7+
<img alt="GitHub last commit" src="https://img.shields.io/github/last-commit/MatMB115/minesweeper_mvc_patterns_com221">
8+
</a>
9+
10+
<img alt="License" src="https://img.shields.io/badge/license-MIT-brightgreen">
11+
<a href="https://github.com/MatMB115/minesweeper_mvc_patterns_com221/stargazers">
12+
<img alt="Stargazers" src="https://img.shields.io/github/stars/MatMB115/minesweeper_mvc_patterns_com221?style=social">
13+
</a>
14+
</p>
15+
16+
<p align="center">
17+
<a href="https://github.com/MatMB115/minesweeper_mvc_patterns_com221">
18+
<img src="https://imgur.com/mLCTpqG.png" height="185" width="185" alt="MineSweep-logo" />
19+
</a>
20+
</p>
21+
22+
<p align="center">
23+
<a href="https://www.python.org/">
24+
<img align="center" alt="RepiMe-Flutter" height="30" width="40" src="https://cdn.jsdelivr.net/gh/devicons/devicon/icons/python/python-original-wordmark.svg">
25+
</a>
26+
</p>
27+
28+
# Minesweeper com designs pattern MVC e Strategy
29+
Campo minado guiado pelos padrões de projeto MVC e Strategy. O jogo foi desenvolvido com Python 3 e a interface gráfica utiliza a biblioteca Qt5 da linguagem.
30+
31+
---
32+
## Sobre
33+
34+
Conforme os conceitos abordados na disciplina de Programação Orientada Objetos II da Universidade Federal de Itajubá ministrada pelo professor [Phyllipe](https://github.com/phillima), a equipe desenvolveu um campo minado com a interface gráfica Qt5 aplicando os padrões de projeto MVC e Strategy.
35+
36+
37+
38+
As orientações estão divididas nos seguintes tópicos:
39+
40+
- [Funcionalidades](#funcionalidades-gear)
41+
- [MVC](#mvc)
42+
- [Strategy](#strategy-thinking)
43+
- [Pré-requisitos e configuração](#pré-requisitos-e-configuração-hammer_and_wrench)
44+
- [Layout](#layout-art)
45+
- [Tecnologias](#tecnologias-technologist)
46+
- [Contribuidores](#contribuidores)
47+
48+
---
49+
## Funcionalidades :gear:
50+
51+
- [x] Easy mode com MVC;
52+
- [x] Mid mode com MVC;
53+
- [x] Hard mode com MVC;
54+
- [x] Random mode (usuário insere as dimensões) com MVC;
55+
- [x] Implantar um timer básico;
56+
- [x] Timer utilizando os assets;
57+
- [x] Strategy para saves;
58+
- [x] Exportar save para JSON;
59+
- [x] Exportar save para CSV;
60+
- [x] Exportar save para TXT.
61+
62+
---
63+
## MVC :
64+
65+
O jogo conta com 4 classes principais além da main, a matriz do campo é composta pela classe cell...
66+
![MVCMinesweep](/class_diagram.png)
67+
68+
---
69+
## Strategy :thinking:
70+
71+
---
72+
## Pré-requisitos e configuração :hammer_and_wrench:
73+
No geral, para executar a aplicação é recomendado que o sistema já possua:
74+
75+
76+
---
77+
## Layout :art:
78+
Imagens do jogo aqui
79+
80+
---
81+
## Tecnologias :technologist:
82+
O ponto de início deste projeto foi um ambiente virtual python, as dependências utilizadas estão presentes abaixo.
83+
---
84+
Aplicação:
85+
86+
-> Python 3.10.8
87+
- pyQt5
88+
---
89+
Utilitários:
90+
91+
-> Dev
92+
- Visual Studio Code 1.73
93+
- PyCharm 2022.3
94+
---
95+
96+
## Contribuidores
97+
98+
<table>
99+
<tr>
100+
<td align="center"><a href="https://github.com/MatMB115"><img style="border-radius: 50%;" src="https://avatars.githubusercontent.com/u/63670910?v=4" width="100px;" alt=""/><br /><sub><b>Matheus Martins</b></sub></a><br /><a href="https://github.com/MatMB115?tab=repositories" title="Minesweep">:technologist:</a></td>
101+
<td align="center"><a href="https://github.com/ODBreno"><img style="border-radius: 50%;" src="https://avatars.githubusercontent.com/u/92598517?v=4" width="100px;" alt=""/><br /><sub><b>Breno Oliveira</b></sub></a><br /><a href="https://github.com/MatMB115/repime" title="RepiMe">:technologist:</a></td>
102+
<td align="center"><a href="https://github.com/thais-souza311"><img style="border-radius: 50%;" src="https://avatars.githubusercontent.com/u/84544053?v=4" width="100px;" alt=""/><br /><sub><b>Thais Souza</b></sub></a><br /><a href="https://github.com/thais-souza311" title="RepiMe">:technologist:</a></td>
103+
<td align="center"><a href="https://github.com/omateusluz"><img style="border-radius: 50%;" src="https://avatars.githubusercontent.com/u/78989307?v=4" width="100px;" alt=""/><br /><sub><b>Matheus Luz</b></sub></a><br /><a href="https://github.com/omateusluz" title="RepiMe">:technologist:</a></td>
104+
</tr>
105+
</table>

class_diagram.png

166 KB
Loading

minesweeper/controller.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ def __init__(self, model):
99
self.model = model
1010
self.model.set_controller(self)
1111

12-
def setView(self, view):
12+
def set_view(self, view):
1313
self.view = view
1414

1515
def left_click(self, x, y):

minesweeper/view.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def __init__(self, controller):
1717
self.menubar = None
1818
self.main_widget = None
1919
self.controller = controller
20-
self.controller.setView(self)
20+
self.controller.set_view(self)
2121
self.controller.start_new_game()
2222
self.createMainUI()
2323

@@ -86,7 +86,7 @@ def input_box_text(self, title, info):
8686
exit()
8787

8888
def input_box_int(self, title, info):
89-
metric_num, status = QInputDialog.getInt(self, title, info, min=1)
89+
metric_num, status = QInputDialog.getInt(self, title, info, min=6)
9090
if status:
9191
return metric_num
9292
else:

0 commit comments

Comments
 (0)