-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathlanguages.json
101 lines (101 loc) · 8.23 KB
/
languages.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
{
"en": {
"langdesc": "English 🇺🇸",
"app_name": "Tic Tac Toe",
"advice": "Note:",
"advice_msg": "X will always play first!",
"restart": "Restart",
"author": "Author: Vivaldo Roque",
"install": "Install",
"contact_text": "Contact",
"about_text": "About",
"home_text": "Home",
"game_mode_msg": "Choose between \"X\" or \"O\"",
"game_level_msg": "Choose the difficulty level",
"easy_level": "Beginner",
"intermediate_level": "Intermediate",
"hardcore_level": "Hardcore",
"X": "Player X's turn",
"O": "Player O's turn",
"draw": "Draw",
"XW": "Player X won!",
"OW": "Player O won!",
"contact_1": "Contact Me",
"contact_2": "Other Links",
"about_title_1": "Tic tac Toe",
"about_msg_1": "In decision theory, minimax (or minmax) is a method to minimize the maximum possible loss. It can be thought of as maximizing the minimum gain (maximin). You start with two 0-0 theory players of games, covering both cases in which players take alternate paths (by rounds) or simultaneously. The concept can be extended to more complex games and to decision making in the presence of uncertainties. In this case, there is no other player, the consequences of decisions depend on unknown factors.",
"about_title_2": "Tic tac toe",
"about_msg_2": "A simple version of the minimax algorithm handles games like tic-tac-toe, in which each player can win, lose, or draw. If player A can win with one move, that's his best move. Player B identifies that one move will lead to a situation where the opponent can win in the next move, and that there is another move that could lead to a situation where the opponent can at most tie, so the latter is the best move After a few rounds, it is easy to identify which is the best move. The minimax algorithm helps to find the best move by walking through the valid options, starting at the end of the game. At each step, it is assumed that the player maximizer is trying to maximize his chances of winning, while in the next round the minimizing player is trying to minimize the chances of this happening (by maximizing the chances that he himself will win). and the lowest scores the minimizer can make that one have.",
"about_title_3": "Performance and Optimizations",
"about_msg_3": "The mimimax algorithm in Tic tac toe (or in other types of games) can do a lot of processing, which can make the algorithm slow, so it must be important to make optimizations so that it is performed correctly while running the game. For this, alpha-beta pruning can be used. It can also be important, especially on devices with low processing power such as cell phones, or even on more powerful devices, that the codes are optimized for to avoid unnecessary processing and time expenses because as this algorithm does a lot of processing, especially in the analysis of the first games, such expenses can be greatly increased and cause a great impact on the performance drop.",
"about_title_4": "Algorithm",
"about_msg_4": "The minimax algorithm with depth limit (using a heuristic to finish scanning after a given depth) is shown below, in pseudocode.",
"code": [
"function minimax(node, depth, maximizingPlayer) is\n",
" if depth = 0 or node is a terminal node then\n",
" return the heuristic value of node\n",
" if maximizingPlayer then\n",
" value := −∞\n",
" for each child of node do\n",
" value := max(value, minimax(child, depth − 1, FALSE))\n",
" return value\n",
" else (* minimizing player *)\n",
" value := +∞\n",
" for each child of node do\n",
" value := min(value, minimax(child, depth − 1, TRUE))\n",
" return value\n"
]
},
"pt": {
"langdesc": "Português 🇵🇹",
"app_name": "Tic Tac Toe",
"advice": "Nota:",
"advice_msg": "X sempre jogará primeiro!",
"restart": "Reiniciar",
"author": "Autor: Vivaldo Roque",
"install": "Instalar",
"contact_text": "Contato",
"about_text": "Sobre",
"home_text": "Início",
"game_mode_msg": "Escolha entre \"X\" ou \"O\"",
"game_level_msg": "Escolha o nível de dificuldade",
"easy_level": "Iniciante",
"intermediate_level": "Intermediário",
"hardcore_level": "Hardcore",
"X": "Vez do jogador X",
"O": "Vez do jogador O",
"draw": "Empate",
"XW": "Jogador X venceu!",
"OW": "Jogador O venceu!",
"contact_1": "Entre Em Contacto",
"contact_2": "Outros Links",
"about_title_1": "Tic tac Toe, jogo da velha ou jogo do galgo",
"about_msg_1": "Em teoria da decisão, o minimax (ou minmax) é um método para minimizar a possível perda máxima. Pode ser considerado como a maximização do ganho mínimo (maximin). Começa-se com dois jogadores 0-0 da teoria dos jogos, cobrindo ambos os casos em que os jogadores tomam caminhos alternados (por rodadas) ou simultaneamente. Pode-se estender o conceito para jogos mais complexos e para tomada de decisão na presença de incertezas. Nesse caso, não existe outro jogador, as consequências das decisões dependem de fatores desconhecidos.",
"about_title_2": "Jogo da velha",
"about_msg_2": "Uma versão simples do algoritmo minimax lida com jogos como o jogo da velha, no qual cada jogador pode ganhar, perder ou empatar. Se o jogador A pode vencer com um movimento, esse é o seu melhor movimento. Se o jogador B identifica que um movimento levará a uma situação em que o adversário pode ganhar no próximo movimento, e que existe outro movimento que poderá levar a uma situação em que o adversário pode, no máximo, empatar, então, este último é o melhor movimento para ele. Após algumas rodadas, é fácil identificar qual é o melhor movimento. O algoritmo minimax ajuda a encontrar a melhor jogada, ao se caminhar pelas opções válidas, a partir do fim do jogo. A cada passo, assume-se que o jogador maximizador está tentando maximizar as suas chances de ganhar, enquanto na próxima rodada o jogador minimizador está tentando minimizar as chances de isso acontecer (maximizando as chances de que ele próprio ganhe). O maximizador precisa escolher uma jogada que tem a maior dentre as menores pontuações que o minimizador pode fazer aquele ter.",
"about_title_3": "Desempenho e otimizações",
"about_msg_3": "O algorítimo mimimax no Jogo da Velha(ou em outros tipos de jogos) pode fazer muito processamento, o que pode fazer o algorítimo ser lento, por isso, deve ser importante fazer-se otimizações para que ele seja efetuado de forma rápida durante a execução do jogo. Para isso pode ser usado por exemplo a Poda alfa-beta. Também pode ser importante, principalmente em dispositivos com baixo poder de processamento como celulares, ou até em dispositivos mais potentes, que os códigos sejam otimizados para evitar-se gastos com processamento e tempo desnecessários pois como esse algoritmo faz muito processamento, principalmente nas análises das primeiras partidas, tais gastos podem ser muito aumentados e causarem um grande impacto na queda de desempenho.",
"about_title_4": "Algoritmo",
"about_msg_4": "O algoritmo minimax com limite de profundidade (usando uma heurística para terminar o vasculhamento após uma dada profundidade) é mostrado abaixo, em pseudocódigo.",
"code": [
"SE nó é um nó terminal OU profundidade = 0 ENTÃO\n",
" RETORNE o valor da heurística do nó\n",
" SENÃO SE maximizador é FALSE ENTÃO\n",
" α ← +∞\n",
" PARA CADA filho DE nó\n",
" α ← min(α, minimax(filho, profundidade-1,true))\n",
" FIM PARA\n",
" RETORNE α\n",
" SENÃO\n",
" //Maximizador\n",
" α ← -∞\n",
" //Escolher a maior dentre as perdas causadas pelo minimizador\n",
" PARA CADA filho DE nó\n",
" α ← max(α, minimax(filho, profundidade-1,false))\n",
" FIM PARA\n",
" RETORNE α\n",
" FIM SE\n",
" FIM ROTINA\n"
]
}
}