-
Notifications
You must be signed in to change notification settings - Fork 0
/
core.c
41 lines (30 loc) · 1.31 KB
/
core.c
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
//==============================================================================
// ファイル名 : core.c
// 概要 : Joh-Monの核となる動作を記述したファイル。
// 最終更新日 : 2014/01/20
// 更新者 : Yanagimachi Tenshi
// Encoding : UTF-8
//==============================================================================
/*******************************************************************************
* ヘッダインクルード
******************************************************************************/
#include "Joh-Mon.h"
#include "initialize.h"
#include "battle.h"
#include "result.h"
/*******************************************************************************
* 関数定義
******************************************************************************/
int main(int argc, char *argv[])
{
struct World world;
int result;
initWorld(&world); // 世界の初期化(パーツ・コマンドリスト生成など)
setPlayer(&world); // プレイヤの受付とモンスターの生成
do(judgment(&world, &result) != GAMEOVER) { // 終了判定
setCommand(&world); // 各プレイヤからコマンドを受け付ける
runAttack(&world); // コマンドの実行
}
showResult(result); // 対戦結果の表示
return 0;
}