//DISSIDIA UPEO FINAL FANTASY 3
//DISSIDIA UPEO FINAL FANTASY 3とは?
//DISSIDIA UPEO FINAL FANTASY 2の続編であり、
//DISSIDIA UPEO FINAL FANTASY 2の後の新名たちを描いた物語であり、
//中学で起きた実話を元にして作られています。
//新名サイドの視点の為、実際の事実と異なる場合もあります。
/*
時間軸:
DISSIDIA UPEO FINAL FANTASY(無印) -- 2009/3 ~ 2009/7
DISSIDIA UPEO FINAL FANTASY 2 -- 2009/3 ~ 2010/1
DISSIDIA UPEO FINAL FANTASY 3 -- 2010/2 ~ 2010/6
*/
//ストーリー・敵の名前などを晒すといろいろとまずいので勘弁してください><
//作成:新名 哲成
//標準ライブラリ
#include <stdio.h>
#include <stdlib.h>
#include <string>
//関数のプロトタイプ宣言
void Conversation( char [ ] ) ;
void Battle( int ,int ) ;
void Conversation( char [ ] ) ;
void Lines( int ,char [ ] ) ;
char Line1[ 64 ] ;
char Line2[ 64 ] ;
typedef struct Member{
int Lv;
char Name[ 64 ] ;
char Job[ 32 ] ;
int HP;
int MP;
int AP;
int GP;
int SpAP;
int SpGP;
int Magic;
} ;
Member Members[ 100 ] = {
1 ,"新名~満足~" ,"中学1年生" , 100 , 100 , 10 , 10 , 10 , 10 ,10 ,
1 ,"新名~精神破滅~" ,"中学2年生" , 50 , 50 , 5 , 5 , 5 , 5 , 5 ,
} ;
/***********************************************************
Function name : 文字列整形関数
Syntax : void Conversation(char Words[64])
Arguments : char Words[64]
Return : なし
Version : 1.20
Date : 2012/2/2
Author : 新名
Comment : 64文字未満の文字列の整形表示
************************************************************/
void Conversation( char Words[ 64 ] ) {
/*TranscriptionWords = TrWords*/
char TrWords[ 64 ] ;
int i= 0 ;
strcpy ( TrWords,Words) ;
do {
++ i;
if ( TrWords[ i] == '\0 ' ) {
for ( ; i<= 62 ; ++ i) {
TrWords[ i] = ' ' ;
}
TrWords[ 63 ] = '\0 ' ;
}
} while ( TrWords[ i] ! = '\0 ' ) ;
printf ( "[[%s]]▽" ,TrWords) ;
getchar ( ) ;
}
void Battle( int PlayerNum,int EnemyNum) {
int i;
int NameSize = strlen ( Members[ PlayerNum] .Name ) ;
printf ( "%sが勝負を仕掛けてきた!!\n " ,Members[ EnemyNum] .Name ) ;
Lines( NameSize,Line1) ;
Lines( NameSize,Line2) ;
while ( 1 ) {
getchar ( ) ;
system ( "cls" ) ;
printf ( "-----%sのステータス------ -----%sのステータス-----\n " ,Members[ PlayerNum] .Name ,Members[ EnemyNum] .Name ) ;
printf ( "|レベル :%25d| |レベル :%25d|\n " ,Members[ PlayerNum] .Lv ,Members[ EnemyNum] .Lv ) ;
printf ( "|Job :%25s| |Job :%25s|\n " ,Members[ PlayerNum] .Job ,Members[ EnemyNum] .Job ) ;
printf ( "|HP :%25d| |HP :%25d|\n " ,Members[ PlayerNum] .HP ,Members[ EnemyNum] .HP ) ;
printf ( "|MP :%25d| |MP :%25d|\n " ,Members[ PlayerNum] .MP ,Members[ EnemyNum] .HP ) ;
printf ( "|AP :%25d| |AP :%25d|\n " ,Members[ PlayerNum] .AP ,Members[ EnemyNum] .AP ) ;
printf ( "|GP :%25d| |GP :%25d|\n " ,Members[ PlayerNum] .GP ,Members[ EnemyNum] .GP ) ;
printf ( "|SpAP :%25d| |SpAP :%25d|\n " ,Members[ PlayerNum] .SpAP ,Members[ EnemyNum] .SpAP ) ;
printf ( "|SpGP :%25d| |SpGP :%25d|\n " ,Members[ PlayerNum] .SpGP ,Members[ EnemyNum] .SpGP ) ;
printf ( "-----%s----------------- -----%s--------------------\n " ,Line1,Line2) ;
}
}
void Lines( int NameSize,char Line[ 64 ] ) {
int i;
for ( i= 0 ; i<= NameSize; ++ i)
Line[ i] = '-' ;
Line[ i+ 1 ] = '\0 ' ;
}
/***********************************************************
Function name : メイン関数
Syntax : int main(void)
Arguments : なし
Return : 0
Version : 1.00
Date :
Author : 新名
************************************************************/
int main( void )
{
while ( 1 ) {
int Selection= 0 ;
int i;
int SizeCount;
printf ( "モードを選んでください。\n " ) ;
printf ( "1:ストーリーモード、2:バトルモード\n " ) ;
scanf ( "%d" ,& Selection) ;
if ( Selection== 1 ) {
} else if ( Selection== 2 ) {
int PlayerNum= - 1 ;
int EnemyNum= - 1 ;
printf ( "キャラクタを選択してください。\n " ) ;
for ( SizeCount= 0 ; Members[ SizeCount] .Lv ! = 0 ; ++ SizeCount) ;
for ( i= 0 ; i< SizeCount; ++ i) {
printf ( "%d:%s\n " ,i,Members[ i] .Name ) ;
}
while ( PlayerNum== - 1 ) {
printf ( ">" ) ;
scanf ( "%d" ,& PlayerNum) ;
}
system ( "cls" ) ;
printf ( "敵キャラクタを選択してください。\n " ) ;
for ( i= 0 ; i< SizeCount; ++ i) {
if ( i ! = PlayerNum)
printf ( "%d:%s\n " ,i,Members[ i] .Name ) ;
}
while ( EnemyNum== - 1 ) {
printf ( ">" ) ;
scanf ( "%d" ,& EnemyNum) ;
}
system ( "cls" ) ;
Battle( PlayerNum,EnemyNum) ;
}
}
return 0 ;
}
Ly9ESVNTSURJQSBVUEVPIEZJTkFMIEZBTlRBU1kgMwovL0RJU1NJRElBIFVQRU8gRklOQUwgRkFOVEFTWSAz44Go44Gv77yfCi8vRElTU0lESUEgVVBFTyBGSU5BTCBGQU5UQVNZIDLjga7ntprnt6jjgafjgYLjgorjgIEKLy9ESVNTSURJQSBVUEVPIEZJTkFMIEZBTlRBU1kgMuOBruW+jOOBruaWsOWQjeOBn+OBoeOCkuaPj+OBhOOBn+eJqeiqnuOBp+OBguOCiuOAgQovL+S4reWtpuOBp+i1t+OBjeOBn+Wun+ipseOCkuWFg+OBq+OBl+OBpuS9nOOCieOCjOOBpuOBhOOBvuOBmeOAggovL+aWsOWQjeOCteOCpOODieOBruimlueCueOBrueCuuOAgeWun+mam+OBruS6i+Wun+OBqOeVsOOBquOCi+WgtOWQiOOCguOBguOCiuOBvuOBmeOAggovKgrmmYLplpPou7jvvJoKCURJU1NJRElBIFVQRU8gRklOQUwgRkFOVEFTWSjnhKHljbAp44CALS0gMjAwOS8zIO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sICA1LCAgNSwgIDUsICA1LCA1LAp9OwoKLyoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqCiAgICBGdW5jdGlvbiBuYW1lIDog5paH5a2X5YiX5pW05b2i6Zai5pWwCiAgICBTeW50YXggICAgICAgIDogdm9pZCBDb252ZXJzYXRpb24oY2hhciBXb3Jkc1s2NF0pCiAgICBBcmd1bWVudHMgICAgIDogY2hhciBXb3Jkc1s2NF0KICAgIFJldHVybiAgICAgICAgOiDjgarjgZcKICAgIFZlcnNpb24gICAgICAgOiAxLjIwCiAgICBEYXRlICAgICAgICAgIDogMjAxMi8yLzIKICAgIEF1dGhvciAgICAgICAgOiDmlrDlkI0KICAgIENvbW1lbnQgICAgICAgOiA2NOaWh+Wtl+acqua6gOOBruaWh+Wtl+WIl+OBruaVtOW9ouihqOekugoqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiovCgp2b2lkIENvbnZlcnNhdGlvbihjaGFyIFdvcmRzWzY0XSl7CgkvKlRyYW5zY3JpcHRpb25Xb3JkcyA9IFRyV29yZHMqLwoJY2hhciBUcldvcmRzWzY0XTsKCWludCBpPTA7CgoJc3RyY3B5KFRyV29yZHMsV29yZHMpOwoKCWRvewoJCSsraTsKCQlpZihUcldvcmRzW2ldPT0nXDAnKXsKCQkJZm9yKDtpPD02MjsrK2kpewoJCQkJVHJXb3Jkc1tpXT0nICc7CgkJCX0KCQkJVHJXb3Jkc1s2M109J1wwJzsKCQl9Cgl9d2hpbGUoVHJXb3Jkc1tpXSE9J1wwJyk7CgoJcHJpbnRmKCJbWyVzXV3ilr0iLFRyV29yZHMpOwoJZ2V0Y2hhcigpOwp9Cgp2b2lkIEJhdHRsZShpbnQgUGxheWVyTnVtLGludCBFbmVteU51bSl7CglpbnQgaTsKCWludCBOYW1lU2l6ZSA9IHN0cmxlbihNZW1iZXJzW1BsYXllck51bV0uTmFtZSk7C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cbiIsTWVtYmVyc1tQbGF5ZXJOdW1dLkdQLE1lbWJlcnNbRW5lbXlOdW1dLkdQKTsKCQlwcmludGYoInxTcEFQCTolMjVkfCAgICAgfFNwQVAJICAgOiUyNWR8XG4iLE1lbWJlcnNbUGxheWVyTnVtXS5TcEFQLE1lbWJlcnNbRW5lbXlOdW1dLlNwQVApOwoJCXByaW50ZigifFNwR1AJOiUyNWR8ICAgICB8U3BHUAkgICA6JTI1ZHxcbiIsTWVtYmVyc1tQbGF5ZXJOdW1dLlNwR1AsTWVtYmVyc1tFbmVteU51bV0uU3BHUCk7CgkJcHJpbnRmKCItLS0tLSVzLS0tLS0tLS0tLS0tLS0tLS0gICAgIC0tLS0tJXMtLS0tLS0tLS0tLS0tLS0tLS0tLVxuIixMaW5lMSxMaW5lMik7Cgl9Cn0KCnZvaWQgTGluZXMoaW50IE5hbWVTaXplLGNoYXIgTGluZVs2NF0pewoJaW50IGk7CgkKCWZvcihpPTA7aTw9TmFtZVNpemU7KytpKQkKCQlMaW5lW2ldPSctJzsKCUxpbmVbaSsxXT0nXDAnOwp9CgovKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioKICAgIEZ1bmN0aW9uIG5hbWUgOiDjg6HjgqTjg7PplqLmlbAKICAgIFN5bnRheCAgICAgICAgOiBpbnQgbWFpbih2b2lkKQogICAgQXJndW1lbnRzICAgICA6IOOBquOBlwogICAgUmV0dXJuICAgICAgICA6IDAKICAgIFZlcnNpb24gICAgICAgOiAxLjAwCiAgICBEYXRlICAgICAgICAgIDogCiAgICBBdXRob3IgICAgICAgIDog5paw5ZCNCioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKi8KaW50IG1haW4odm9pZCkKewoJd2hpbGUoMSl7CgkJaW50IFNlbGVjdGlvbj0wOwoJCWludCBpOwoJCWludCBTaXplQ291bnQ7CgoJCXByaW50Zigi44Oi44O844OJ44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