Example #1
0
void showGraph(int x[],int y,int z){

	int i, j;//ループ用
	for(i=0;i<y;i++){

		if(i==z || i== z+1){

			DrawFormatStringToHandle( 0, 40+20*i, GetColor(0, 255, 0), FontHandle1, "[%02d] %2d | ",i,x[i]);

			for(j=0;j<x[i];j++){
				DrawFormatStringToHandle( 90+j*bw, 40+20*i, GetColor(0, 255, 0), FontHandle1, "■");

			}

		}else{
			DrawFormatStringToHandle( 0, 40+20*i, GetColor(255, 255, 255), FontHandle1, "[%02d] %2d | ",i,x[i]);
			for(j=0;j<x[i];j++){
				DrawFormatStringToHandle( 90+bw*j, 40+20*i, GetColor(255, 255, 255), FontHandle1, "■");

			}


		}
	}
}
Example #2
0
void CBoard::draw(int point, int quota, std::string statement1, std::string statement2) {

	// 背景画像
	DrawGraph(0, 0, ghandle_background, TRUE);

	// 箱が通る線
	DrawBox(0, 295, 800, 305, blue, TRUE);
	DrawBox(450, 295, 600, 305, red, TRUE);

	// 説明文
	DrawFormatStringToHandle(30, 120, white, font3, "ベルトレーラーが光っている時,");
	DrawFormatStringToHandle(30, 150, white, font3, "答えが正解だと思ったらZキーを押そう。");
	DrawFormatStringToHandle(30, 180, white, font3, "違うと思ったらスルーだ!");

	// 得点表示
	DrawFormatStringToHandle(600, 500, white, font1, "得点:");

	if(point > quota) DrawFormatStringToHandle(690, 500, light_blue, font1, "%d", point);

	else if(point == quota) DrawFormatStringToHandle(690, 500, white, font1, "%d", point);

	else DrawFormatStringToHandle(690, 500, light_red, font1, "%d", point);
		
	// ノルマ表示
	DrawFormatStringToHandle(50, 500, white, font1, "ノルマ: %d", quota);

	// 問題文表示
	DrawFormatStringToHandle(50, 50, white, font1, statement1.c_str());
	DrawFormatStringToHandle(50, 80, white, font1, statement2.c_str());

}
Example #3
0
void CBoard::result(int point, int quota) {

	// 結果発表画面の表示(半透明にする)
	SetDrawBlendMode(DX_BLENDMODE_ALPHA, 10);
	DrawGraph(0, 250, ghandle_result_background, TRUE);
	SetDrawBlendMode(DX_BLENDMODE_NOBLEND, 0);

	// ノルマクリアかそうでないか
	if(point >= quota) DrawFormatStringToHandle(250, 275, white, font2, "ノルマクリア!"); 

	else DrawFormatStringToHandle(250, 275, white, font2, "再挑戦しよう!");

}
Example #4
0
//文字を描画
void DrawImpl::textLine(const Vector2& pos, int color, int fontHandle, const std::string &str, int alpha, HorizontalPlace::en fh, VerticalPlace::en fv, int blendMode){
	Vector2 dPos(0, 0);
	if (fh == HorizontalPlace::en::center){
		dPos.x -= GetDrawFormatStringWidthToHandle(fontHandle, "%s", str.c_str()) / 2.0;
	}
	else if (fh == HorizontalPlace::en::right){
		dPos.x -= GetDrawFormatStringWidthToHandle(fontHandle, "%s", str.c_str());
	}
	if (fv == VerticalPlace::en::center){
		dPos.y -= GetFontSizeToHandle(fontHandle) / 2.0;
	}
	else if (fv == VerticalPlace::en::bottom){
		dPos.y -= GetFontSizeToHandle(fontHandle);
	}

	SetDrawBlendMode(blendMode, alpha);

	size_t preNum = 0;
	size_t num = 0;
	while (1){
		preNum = num;
		num = str.find('\n', num);
		DrawFormatStringToHandle(pos.x + dx + dPos.x, pos.y + dy + dPos.y, color, fontHandle, "%s", str.substr(preNum, num - preNum).c_str());
		if (num == std::string::npos){
			break;
		}
		else{
			dPos += Vector2(0, GetFontSizeToHandle(fontHandle));
			num++;
		}
	}
	textDrawLog.set(pos, color, fontHandle, alpha, blendMode);
}
Example #5
0
//テキストとその背景に
void DrawImpl::textBox(const Vector2& pos, int color, int fontHandle, const std::string &str, int alpha, HorizontalPlace::en fh, VerticalPlace::en fv, const Vector2 &boxMargeV2, int boxColor, int boxAlpha, int blendMode, int boxBlendMode){
	Vector2 dPos(0, 0);
	Vector2 fontSize = Vector2(
		GetDrawFormatStringWidthToHandle(fontHandle, "%s", str.c_str()),
		GetFontSizeToHandle(fontHandle)
		);
	if (fh == HorizontalPlace::en::center){
		dPos.x -= fontSize.x / 2.0;
	}
	else if (fh == HorizontalPlace::en::right){
		dPos.x -= fontSize.x;
	}
	if (fv == VerticalPlace::en::center){
		dPos.y -= fontSize.y / 2.0;
	}
	else if (fv == VerticalPlace::en::bottom){
		dPos.y -= fontSize.y;
	}
	Vector2 shift(-(int)fh * fontSize.x * 0.5, -(int)fv * fontSize.y * 0.5);
	Vector2 leftTop(pos.x + dx + dPos.x, pos.y + dy + dPos.y);
	Draw.box(leftTop - boxMargeV2 * 0.5, leftTop + fontSize + boxMargeV2 * 0.5, boxColor, boxAlpha);
	SetDrawBlendMode(blendMode, alpha);
	DrawFormatStringToHandle(leftTop.x, leftTop.y, color, fontHandle, "%s", str.c_str());
	textDrawLog.set(leftTop, color, fontHandle, alpha, blendMode);
}
Example #6
0
void MessageWindow::Draw() {
	BaseWindow::Draw();
	//DrawFormatStringToHandle(APosition_LT.x + CharShowWait, APosition_LT.y + CharShowWait, 0xFFFFFF, Font, (NowText + (ShowingIsFinish && !MessagesAreEmpty ? _T("▼") : _T(""))).c_str());
	// テキストが空なら何もしないでreturn
	if (NowText.empty()) {
		return;
	}
	// 文の先頭が何番目であるか
	int TopChar = 0;
	// 文の終了位置が何番目であるか
	int EndChar = 0;
	// 改行しながら表示
	for (int LineCount = 0; TopChar < NowText.size(); ++LineCount) {
		// 改行位置を探す
		EndChar = NowText.find_first_of(_T("\n"), TopChar);
		// 見つからなければ、終端を最後にする
		if (EndChar == mine::tstring::npos) {
			EndChar = NowText.size() - 1;
		}
		// 指定された範囲で描画
		DrawFormatStringToHandle(APosition_LT.x + Message_DefaultInterval, APosition_LT.y + Message_DefaultInterval + LineCount * (GetDrawFormatStringWidthToHandle(Font, _T("あ"))), 0xFFFFFF, Font, (NowText.substr(TopChar, EndChar - TopChar + 1) + (ShowingIsFinish && !MessagesAreEmpty && EndChar == NowText.size() - 1 ? _T("▼") : _T(""))).c_str());
		// 先頭を現在の終端の次に
		TopChar = EndChar + 1;
	}

	//DrawString(-1000, 100, Texts.front().c_str(), 0xFF0000);
}
void MessageProcessorUnit::Draw()
{

	if (Counter){
		DrawGraph(0,0,(*dataBase->menuGraph)(1), TRUE);
		DrawFormatStringToHandle(360, WINDOW_HEIGHT - 180, 0xFFFFFF, (*dataBase->font)(20), "%s", message.back().MessageText.c_str());
	}
}
Example #8
0
void result::draw(){
	SetDrawBlendMode( DX_BLENDMODE_ALPHA , 100 ) ;	SetDrawBright(255,255,255);
	DrawRotaGraph(400, 300, 1, 0, GHandle[11] , 1);

	SetDrawBlendMode( DX_BLENDMODE_ALPHA , 255 ) ;	SetDrawBright(255,255,255);
	int stry = 60;
	int wdx;
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[1],  "RESULT"));
	DrawFormatStringToHandle((int)400-wdx, (int)stry, 0xFFFFFF, FontHandle[1] , "RESULT") ;
	stry+= 80;
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[1],  "倒したゾンビ数: %d", ptr->menemy->dienum));
	DrawFormatStringToHandle((int)400-wdx, (int)stry, 0xFFFFFF, FontHandle[1] , "倒したゾンビ数: %d", ptr->menemy->dienum) ;
	stry+= 80;
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[1],  "累積経験値: %d", ptr->mplayer->expsum));
	DrawFormatStringToHandle((int)400-wdx, (int)stry, 0xFFFFFF, FontHandle[1] , "累積経験値: %d", ptr->mplayer->expsum) ;
	stry+= 80;
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[1],  "被ダメージ回数: %d", ptr->menemy->damagenum));
	DrawFormatStringToHandle((int)400-wdx, (int)stry, 0xFFFFFF, FontHandle[1] , "被ダメージ回数: %d", ptr->menemy->damagenum) ;
	stry+= 80;
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[1],  "総合スコア: %ld", ptr->menemy->dienum*1000 + ptr->mplayer->expsum*10 - ptr->menemy->damagenum*200));
	DrawFormatStringToHandle((int)400-wdx, (int)stry, 0xFFFFFF, FontHandle[1] , "総合スコア: %ld", ptr->menemy->dienum*1000 + ptr->mplayer->expsum*10 - ptr->menemy->damagenum*200) ;
	
	SetDrawBlendMode( DX_BLENDMODE_ALPHA , (int)(128+128*sin(keika*0.05) ) ) ;	
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[1],  "THANK YOU FOR PLAYING!!"));
	DrawFormatStringToHandle((int)400-wdx, (int)460, 0xFFFFFF, FontHandle[1] , "THANK YOU FOR PLAYING!!") ;
	
	SetDrawBlendMode( DX_BLENDMODE_ALPHA , 255 ) ;	SetDrawBright(255,255,255);
	wdx = (int)(0.5 *GetDrawFormatStringWidthToHandle(FontHandle[0],  "[スペースキーで終了]"));
	DrawFormatStringToHandle((int)400-wdx, (int)550, 0xFF8800, FontHandle[0] , "[スペースキーで終了]") ;

	ptr->meffect->draw();
}
Example #9
0
void Clear_Draw()
{
	DrawRotaGraph(WIDTH/2, HEIGHT/2,1.0,0, clear_image,true, 0);
	DrawFormatStringToHandle(250, 360, GetColor(255,127,39), CScoreFont, "ヒキョリ: %6d km", score);
	for (int i = 0; i < 3; i++)
	{
		DrawGraph(Menu_clear[i].x + 42 - 76, Menu_clear[i].y + 9 - 27, Menu_clear[i].image, true);
		DrawFormatString(Menu_clear[i].x, Menu_clear[i].y, Menu_clear[i].color, Menu_clear[i].name);
	}
}
Example #10
0
void graph_key(){
	graph_back();

	DrawStringToHandle(140,120,"弾幕段位認定",color[0],font[3]);

	DrawStringToHandle(245,240,"決定",color[0],font[1]);
	DrawFormatStringToHandle(390,240,color[0],font[1],"%d",configpad.shot);

	DrawStringToHandle(190,280,"キャンセル",color[0],font[1]);
	DrawFormatStringToHandle(390,280,color[0],font[1],"%d",configpad.bom);

	DrawStringToHandle(205,320,"低速移動",color[0],font[1]);
	DrawFormatStringToHandle(390,320,color[0],font[1],"%d",configpad.slow);

	DrawStringToHandle(225,360,"ポーズ",color[0],font[1]);
	DrawFormatStringToHandle(390,360,color[0],font[1],"%d",configpad.start);

	DrawStringToHandle(180,410,"タイトルに戻る",color[0],font[1]);
	DrawStringToHandle(140,240+(menu_state*40),"→",color[0],font[1]);
}
Example #11
0
//---------------------------------------------------------------------
void SaveloadDraw::drawSavedataTime(int savedata_pos)
{
    int num = savedata_pos + saveload_state->getPage() * SaveloadData::getSavedataNum();
    DrawFormatStringToHandle(
        SaveloadData::getSavedataPosX(savedata_pos) + 370,
        SaveloadData::getSavedataPosY(savedata_pos) + 90,
        color_font,
        font_time,
        "%s %s",
        SaveData::getInstance()->getSaveDay(num).c_str(),
        SaveData::getInstance()->getSaveTime(num).c_str());
}
Example #12
0
void Weapon_Draw(){
	//武器画像の表示
	LoadGraphScreen(0, 0, "hand.jpg", TRUE);
	LoadGraphScreen(300, 330, "machine2.jpg", TRUE);
	LoadGraphScreen(0, 450, "sniper.jpg", TRUE);
	LoadGraphScreen(300, 450, "shotgun.jpg", TRUE);
	//DrawFormatString(0, 120, BLACK, "%d", weapon_flag);
	//DrawFormatString(0, 120, BLACK, "%d", weapon_select);


	DrawStringToHandle(300, 5, "使いたい武器の番号を", RED, font_handle);
	DrawStringToHandle(300, 35, "キーボードで入力してください", RED, font_handle);
	DrawStringToHandle(260, 420, "�@", BLACK, font_handle2);
	DrawStringToHandle(310, 420, "�A", BLACK, font_handle2);
	DrawStringToHandle(260, 450, "�B", BLACK, font_handle2);
	DrawStringToHandle(310, 450, "�C", BLACK, font_handle2);

	DrawStringToHandle(300, 85, "Aさんが選んだ武器は", RED, font_handle);
	DrawFormatStringToHandle(360, 115, RED, font_handle, "%sです", chara_select_weapon);
	DrawStringToHandle(300, 145, "Bさんが選んだ武器は", RED, font_handle);
	DrawFormatStringToHandle(360, 175, RED, font_handle, "%sです", enemy_select_weapon);
}
Example #13
0
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
{
	SetOutApplicationLogValidFlag(FALSE);//Log.txtを生成しないように設定
	ChangeWindowMode(TRUE);//非全画面にセット
	SetGraphMode(SCREEN_WIDTH, SCREEN_HEIGHT, 32);//画面サイズ指定
	if (DxLib_Init() == 1) { return -1; }//初期化に失敗時にエラーを吐かせて終了
	SetDrawScreen(DX_SCREEN_BACK);//描画先を裏画面に


	fontHandle = CreateFontToHandle("Segoe UI", 20, 5, DX_FONTTYPE_ANTIALIASING_4X4);//フォントを読み込み

	std::vector<Enemy> vec;

	while (ProcessMessage() == 0)
	{
		ClearDrawScreen();//裏画面消す

		GetMousePoint(&mouseX, &mouseY); //マウス座標更新
		keyUpdate();//(自作関数)キー更新

		// Zキーが押されたらランダムな座標に敵を生成
		if (keyState[KEY_INPUT_Z] == 1) {
			vec.emplace_back(Enemy(GetRand(SCREEN_WIDTH), GetRand(SCREEN_HEIGHT))); // 敵をインスタンス化
		}

		// 画面外の敵を削除
		auto iter = vec.begin();
		while (iter != vec.end()) {
			if (iter->x < 0 || iter->x > SCREEN_WIDTH || iter->y < 0 || iter->y > SCREEN_HEIGHT) { //画面外に出ているか確認
				iter = vec.erase(iter);
			}
			else {
				iter++;
			}
		}

		for (auto i = vec.begin(); i < vec.end(); i++) {
			i->update();
		}
		for (auto i = vec.begin(); i < vec.end(); i++) {
			i->draw();
		}

		DrawFormatStringToHandle(20, 20, GetColor(255, 255, 255), fontHandle, "Zキーで敵を生成 敵の数:%d", vec.size());

		ScreenFlip();//裏画面を表画面にコピー
	}

	DxLib_End();
	return 0;
}
Example #14
0
//---------------------------------------------------------------------
void SaveloadDraw::drawSavedataText(int savedata_pos)
{
    int num = savedata_pos + saveload_state->getPage() * SaveloadData::getSavedataNum();
    int scenario_num = SaveData::getInstance()->getScenarioPos(num);
    std::string text = AllScenarioData::getInstance()->getText(scenario_num);

    DrawFormatStringToHandle(
        SaveloadData::getSavedataPosX(savedata_pos) + 195,
        SaveloadData::getSavedataPosY(savedata_pos) + 37,
        color_font,
        font_text,
        "%s",
        text.substr(0, 38).c_str());
    if (text.length() >= 38) {
        DrawFormatStringToHandle(
            SaveloadData::getSavedataPosX(savedata_pos) + 195,
            SaveloadData::getSavedataPosY(savedata_pos) + 57,
            color_font,
            font_text,
            "%s",
            text.substr(38, 38).c_str());
    }
}
Example #15
0
//リザルト画面
void gameover()
{
	DrawFormatStringToHandle(80,100,GetColor(255,100,255),font_result,"Your score:  %d  ",score);
	DrawFormatStringToHandle(100,350,GetColor(255,100,255),font_result,"Please Enter Key…");
	
	if(TweetFlag())
	{ DrawFormatStringToHandle(100,450,GetColor(255,100,255),font_result,"Xキーでつぶやく"); }
//	if(first_shotflag == false)
//	{
//		DrawFormatStringToHandle(100,200,GetColor(255,100,255),font_result,"Non Shooter!");
//	}
	
	char c_score[50];

	wsprintf(c_score,"スコアは %d 点です。 ",score);

	if(end_m_flag == false)
	{
		PlaySoundMem(end_m,DX_PLAYTYPE_BACK);
		end_m_flag = true;
	}
	if(CheckHitKey(KEY_INPUT_RETURN))
	{
		syokikaflag = true;
	}
	if(TweetFlag()==true && CheckHitKey(KEY_INPUT_X)==1)
	{
		SetUseIMEFlag(true);
		ChildWindow(c_score,"works/Sankaku/top.html");
		syokikaflag = true;
	}
	fopen_s(&pt,"high.dat","w");
	ango = highscore^0x9fb26ac;
	fprintf(pt,"%d",ango);
	fclose(pt);

}
Example #16
0
//スペル文字・残り時間の描画
void graph_cut(char *string,int length){//スペル名、下線部の長さ
	int t = spcount;

	if(t >= 0 && t < 100){
		DrawStringToHandle(100,215,string,color[0],font[0]);
		DrawLine(100,232,100+length,232,color[2]);
	}

	else{
		DrawStringToHandle(FX,FY,string,color[0],font[0]);
		DrawLine(FX,FY+17,FX+length,FY+17,color[2]);
	}

	DrawFormatStringToHandle(395,FY,color[0],font[0],"%d",(1860-spcount)/60);
}
Example #17
0
Scene* Menu::Update(){
	SetDrawBlendMode(DX_BLENDMODE_ALPHA, 128);
	DrawBox(0, 0, MainLoop::WINDOW_WIDTH, MainLoop::WINDOW_HEIGHT, GetColor(0, 0, 0), TRUE);
	SetDrawBlendMode(DX_BLENDMODE_NOBLEND, 0);
	
	int menuLeft = MainLoop::WINDOW_WIDTH / 2 - GetDrawStringWidth("[X-KEY]:START", strlen("[X-KEY]:START")) / 2;

	DrawFormatStringToHandle(menuLeft, MainLoop::WINDOW_HEIGHT / 2 - 50, GetColor(255, 255, 255), mFontHandle, "[Z-KEY]:RESUME");
	DrawFormatStringToHandle(menuLeft, MainLoop::WINDOW_HEIGHT / 2, GetColor(255, 255, 255), mFontHandle, "[X-KEY]:RESTART");
	DrawFormatStringToHandle(menuLeft, MainLoop::WINDOW_HEIGHT / 2 + 50, GetColor(255, 255, 255), mFontHandle, "[C-KEY]:TITLE");

	//シーケンス処理
	Scene* next = this;
	if (CheckHitKey(KEY_INPUT_Z) != 0){
		next = new Play(mParent);
	}
	else if (CheckHitKey(KEY_INPUT_X) != 0){
		next = new OnePlayGame();
	}
	else if (CheckHitKey(KEY_INPUT_C) != 0){
		next = new Title();
	}
	return next;
}
Example #18
0
//文字を描画・位置指定
void DrawImpl::textPlace(const Vector2& pos, int color, int fontHandle, const std::string &str, int alpha, HorizontalPlace::en fh, VerticalPlace::en fv, int blendMode){
	SetDrawBlendMode(blendMode, alpha);
	Vector2 dPos(0, 0);
	if (fh == HorizontalPlace::en::center){
		dPos.x -= GetDrawFormatStringWidthToHandle(fontHandle, "%s", str.c_str()) / 2.0;
	}
	else if (fh == HorizontalPlace::en::right){
		dPos.x -= GetDrawFormatStringWidthToHandle(fontHandle, "%s", str.c_str());
	}
	if (fv == VerticalPlace::en::center){
		dPos.y -= GetFontSizeToHandle(fontHandle) / 2.0;
	}
	else if (fv == VerticalPlace::en::bottom){
		dPos.y -= GetFontSizeToHandle(fontHandle);
	}
	DrawFormatStringToHandle(pos.x + dx + dPos.x, pos.y + dy + dPos.y, color, fontHandle, "%s", str.c_str());
	textDrawLog.set(pos, color, fontHandle, alpha, blendMode);
}
Example #19
0
void graph_manual(){
	graph_back();

	switch(menu_state){
		case 0:
			DrawStringToHandle(200,40,"このゲームは",color[0],font[1]);
			DrawStringToHandle(25,120,"このゲームは、弾幕STG(シューティングゲーム)である「東方project」を",color[0],font[0]);
			DrawStringToHandle(25,140,"イメージして制作された、弾幕避けゲームです。",color[0],font[0]);

			DrawStringToHandle(25,180,"プレイヤーは自機を操作し、敵の放つ弾を避け続けてください。",color[0],font[0]);
			DrawStringToHandle(25,200,"10枚のスペルを認定ゲージ(画面右に表示)が尽きないように避け続ける",color[0],font[0]);
			DrawStringToHandle(25,220,"ことができればクリアとなります!",color[0],font[0]);

			DrawStringToHandle(25,280,"全部で4段階の難易度を用意しているので、自分の実力や好みに合わせて",color[0],font[0]);
			DrawStringToHandle(25,300,"選択してください。",color[0],font[0]);

			DrawStringToHandle(25,340,"高い難易度のクリアを目指すのもよし、",color[0],font[0]);
			DrawStringToHandle(25,360,"低い難易度を極めて高ランクを叩きだすのもよしです!",color[0],font[0]);
			break;
		case 1:
			DrawStringToHandle(215,40,"ルール説明",color[0],font[1]);
			DrawStringToHandle(30,110,"認定ゲージを切らさずに10枚のスペルを避け続けることができればクリ",color[0],font[0]);
			DrawStringToHandle(30,130,"ア、途中で認定ゲージが尽きてしまうとゲームオーバーになります。",color[0],font[0]);

			DrawStringToHandle(30,170,"認定ゲージは敵との接触や被弾によって減少し、グレイズ(判定ギリギ",color[0],font[0]);
			DrawStringToHandle(30,190,"リで弾にかすること)によって少しずつ回復していきます。",color[0],font[0]);
			DrawStringToHandle(30,210,"TYPE Bの自機はこのグレイズによる認定ゲージの回復量にボーナスが",color[0],font[0]);
			DrawStringToHandle(30,230,"つきます。",color[0],font[0]);

			DrawStringToHandle(30,270,"また、自機狙い・ワインダー・サイズの小さな弾などは受けるダメージ",color[0],font[0]);
			DrawStringToHandle(30,290,"が少なめに、大弾は受けるダメージが多めになっているので注意しまし",color[0],font[0]);
			DrawStringToHandle(30,310,"ょう。",color[0],font[0]);

			DrawStringToHandle(30,350,"ゲームオーバーになった場合は全体と比べて生き残った時間の割合で、",color[0],font[0]);
			DrawStringToHandle(30,370,"クリアした場合はプレイ内容によって決まる総合達成度と、総合達成度",color[0],font[0]);
			DrawStringToHandle(30,390,"から判定されるクリアランクがリザルト画面に表示されます。",color[0],font[0]);
			DrawStringToHandle(30,410,"(クリアランクは総合達成度に応じてD〜AAAまで用意されています。)",color[0],font[0]);
			break;
		case 2:
			DrawStringToHandle(215,40,"難易度説明",color[0],font[1]);

			DrawStringToHandle(30,85,"EASY",color[0],font[4]);
			DrawStringToHandle(30,110,"一番簡単な難易度です。普段からSTGをやっている人には物足りなく感",color[0],font[0]);
			DrawStringToHandle(30,130,"じる難易度ですが、STGをやったことのない人・やるけど苦手な人はま",color[0],font[0]);
			DrawStringToHandle(30,150,"ずこの難易度からプレイしてみて練習してみましょう。",color[0],font[0]);

			DrawStringToHandle(30,180,"NORMAL",color[3],font[4]);
			DrawStringToHandle(30,205,"比較的簡単な方で、標準的な難易度です。ノーマルシューターの人で",color[0],font[0]);
			DrawStringToHandle(30,225,"あればある程度やればクリアが可能になると思います。ノーマルだか",color[0],font[0]);
			DrawStringToHandle(30,245,"らといってSTG未経験の人が迂闊に選択すると痛い目を見ますよ?",color[0],font[0]);

			DrawStringToHandle(30,275,"HARD",color[2],font[4]);
			DrawStringToHandle(30,300,"そこそこ難しい難易度です。HARD以上からは新たな弾幕パターンが追加",color[0],font[0]);
			DrawStringToHandle(30,320,"されるスペルもありますが、ノーマルシュ−ターの人でも十分挑戦でき",color[0],font[0]);
			DrawStringToHandle(30,340,"る難易度だとは思います。LUNATICへの橋渡し・予行演習にもどうぞ。",color[0],font[0]);

			DrawStringToHandle(30,370,"LUNATIC",color[7],font[4]);
			DrawStringToHandle(30,395,"お約束の難易度です。これで伝わらない人は挑戦しない方が無難です。",color[0],font[0]);
			DrawStringToHandle(30,415,"鬼畜難易度ではないので、気合力のある人や鍛えられたシューターであ",color[0],font[0]);
			DrawStringToHandle(30,435,"ればクリアできるはずです。でも、一般人にとってはたぶんクソゲー。",color[0],font[0]);
			break;
		case 3:
			DrawStringToHandle(185,40,"自機タイプ説明",color[0],font[1]);

			DrawStringToHandle(30,100,"TYPE A",color[0],font[4]);
			DrawStringToHandle(30,130,"標準的な機体、霊夢互換です。当たり判定が少し小さくなります。",color[0],font[0]);
			DrawStringToHandle(30,150,"当たり判定縮小化はクリア狙いでも高ランク狙いでも腐りにくい能力で",color[0],font[0]);
			DrawStringToHandle(30,170,"扱いやすいので、迷ったらこのタイプを選べば間違いないでしょう。",color[0],font[0]);

			DrawStringToHandle(30,210,"TYPE B",color[0],font[4]);
			DrawStringToHandle(30,240,"グレイズによる認定ゲージの上昇量が増加し、加えて低空飛行時に被弾",color[0],font[0]);
			DrawStringToHandle(30,260,"した時の認定ゲージの減少量が軽減されます。グレイズを稼げるスペル",color[0],font[0]);
			DrawStringToHandle(30,280,"での回復や終盤戦の低空飛行の粘り強さが強力なクリア向け機体です。",color[0],font[0]);

			DrawStringToHandle(30,320,"TYPE C",color[0],font[4]);
			DrawStringToHandle(30,350,"TYPE AとTYPE Bどちらのボーナスも受けられない代わりにランク上昇",color[0],font[0]);
			DrawStringToHandle(30,370,"に必要な総合達成度が少し軽減されます。安定したクリアができれば、",color[0],font[0]);
			DrawStringToHandle(30,390,"高ランクを取得しやすくなる機体です。また、この機体でのみ極めて高",color[0],font[0]);
			DrawStringToHandle(30,410,"い総合達成度でクリアするとAAA+ランクを取得することができます。",color[0],font[0]);
			break;
		case 4:
			DrawStringToHandle(245,40,"ヒント",color[0],font[1]);
			DrawStringToHandle(30,100,"・認定ゲージが30%未満の時には低空飛行状態となって受けるダメージ",color[0],font[0]);
			DrawStringToHandle(30,120," が減少します。最後まで諦めずに避け続けましょう。",color[0],font[0]);

			DrawStringToHandle(30,150,"・総合達成度は、より多くの認定ゲージを残した状態でクリアすること",color[0],font[0]);
			DrawStringToHandle(30,170," で上昇します。その他にも、多くのスペルボーナス(1回も被弾せず",color[0],font[0]);
			DrawStringToHandle(30,190," にスペルをやりすごすことでボーナスが獲得できます)の獲得数やグ",color[0],font[0]);
			DrawStringToHandle(30,210," レイズの回数に応じて上昇していきます。",color[0],font[0]);

			DrawStringToHandle(30,240,"・Spell5は米粒弾のワインダーに合わせて敵の周りを左回りに、",color[0],font[0]);
			DrawStringToHandle(30,260," Spell8は米粒弾または楔弾のワインダーに合わせて敵の正面を左右",color[0],font[0]);
			DrawStringToHandle(30,280," に動きましょう。この2スペルはワインダーに巻き込まれると手痛い",color[0],font[0]);
			DrawStringToHandle(30,300," ダメージを受けるのでワインダーを最優先で避けていきましょう。",color[0],font[0]);

			DrawStringToHandle(30,330,"・Spell7は見た目は変化しますがそのまま大弾が迫ってきています。",color[0],font[0]);
			DrawStringToHandle(30,350," 見かけに騙されず、弾との適切な距離を保ちましょう。",color[0],font[0]);

			DrawStringToHandle(30,380,"・Spell9は難易度によってパターンと対策が大きく異なります。",color[0],font[0]);
			DrawStringToHandle(30,400," NORMAL以下は2列を同時に相手にしないような場所を探しましょう。",color[0],font[0]);
			DrawStringToHandle(30,420," HARD以上は一定間隔で出現する大弾からの大ダメージをできるだけ",color[0],font[0]);
			DrawStringToHandle(30,440," 減らしましょう。低速移動が禁止されている点にも注意です。",color[0],font[0]);
			break;
		case 5:
			DrawStringToHandle(210,40,"クレジット",color[0],font[1]);
			DrawStringToHandle(135, 90,"プログラミング他いろいろ",color[0],font[4]);
			DrawStringToHandle(245,120,"Mrtanaka",color[0],font[4]);
			DrawStringToHandle(210,165,"ライブラリ使用",color[0],font[4]);
			DrawStringToHandle(225,195,"DXライブラリ",color[0],font[4]);
			DrawStringToHandle(130,240,"プログラム参考・画像素材",color[0],font[4]);
			DrawStringToHandle(105,270,"「龍神録プログラミングの館」様",color[0],font[4]);
			DrawStringToHandle(210,300,"(http://dixq.net/rp/)",color[0],font[0]);
			DrawStringToHandle(240,335,"効果音素材",color[0],font[4]);
			DrawStringToHandle( 85,365,"そのへんから拾ってきたフリー素材",color[0],font[4]);
			DrawStringToHandle(185,410,"スペシャルサンクス",color[0],font[4]);
			DrawStringToHandle(127,440,"テストプレイヤーのみなさん",color[0],font[4]);
			break;
		case 6:
			DrawStringToHandle(230,40,"コメント",color[0],font[1]);
			DrawStringToHandle(30, 80," どうも初めまして、Mrtanakaと申します。",color[0],font[0]);
			DrawStringToHandle(30,100,"普段はルナシューターから音ゲーマー(SDVX)、プロデューサー、提督、",color[0],font[0]);
			DrawStringToHandle(30,120,"クッキー職人、大学生…と、忙しい毎日を過ごしています。",color[0],font[0]);
			DrawStringToHandle(30,140," この作品は、私の「1人の東方シューターとしていつか二次創作かオリ",color[0],font[0]);
			DrawStringToHandle(30,160,"ジナルのSTGを制作してみたい…」という野望の第一ステップとしてゲー",color[0],font[0]);
			DrawStringToHandle(30,180,"ムシステムや弾幕の構築方法を学ぼうと実験的に制作されたものです。",color[0],font[0]);
			DrawStringToHandle(30,200," しっかりとしたSTGを用意するのはどうせ無理だろうと思い、ちょっ",color[0],font[0]);
			DrawStringToHandle(30,220,"とした弾幕ミニゲームというジャンルに落ち着いた今作ですが、ゲーム",color[0],font[0]);
			DrawStringToHandle(30,240,"を作るという行為自体が初めてであった故、随分と苦労させられました。",color[0],font[0]);
			DrawStringToHandle(30,260," さて、さらっと軽いノリで制作された(はずなのにけっこう時間かかっ",color[0],font[0]);
			DrawStringToHandle(30,280,"ている)今作ですが、どうだったでしょうか?私としては、今作のテーマ",color[0],font[0]);
			DrawStringToHandle(30,300,"として気合避け系の弾幕ばかりの構成となっていたので、個人差が出たり",color[0],font[0]);
			DrawStringToHandle(30,320,"人によってはつまらない感じになったかなーとは思っていますが…",color[0],font[0]);
			DrawStringToHandle(30,340," よければ、「ここの弾幕はどうだった」「これはノーマルじゃない」",color[0],font[0]);
			DrawStringToHandle(30,360,"などといった感想を伝えてくれると、すっごい嬉しいです。適切な難易度",color[0],font[0]);
			DrawStringToHandle(30,380,"の調整についても、これから学んでいきたいですね。",color[0],font[0]);
			DrawStringToHandle(30,400," 最後に、わざわざこんなところまで読んでくれた素敵な貴方に感謝。",color[0],font[0]);
			DrawStringToHandle(30,420," それでは、素敵な弾幕ライフを…",color[0],font[0]);

			DrawStringToHandle(215,450,"Mrtanaka(@Mrtanaka1)",color[0],font[0]);
			break;
	}
	DrawFormatStringToHandle(590,460,color[0],font[2],"P %d/7",menu_state+1);
}
Example #20
0
//メインループ
void mymain()
{

	if(syokaiflag == false)
	{
		highscore_syori();
		syokaiflag = true;
	}
	if(set_graph == false)
	{
		load_files();
	}
	if(logoflag == false && file_count <41)
	{
		logo();
	}
	else if(file_count == 0)
	{
		option();

		if(option_flag == false)
		{
			if(syokikaflag == true)
			{
				syokika();
				syokikaflag = false;
			}


			if(game_endflag == false)
			{
				if(game_startflag == true)
				{
					wall();
				}
				

				if(game_startflag == false)
				{
					StopSoundMem(end_m);
					start_menu();
				}
				DrawGraph(0,0,g_wall,TRUE);
				move_myship();
				botten();
				drawshot();
				if(game_startflag == true)
				{
					ball();
					ball_hantei();
					shot_hantei();
					jiki_hantei();
					sky_jouken();
					skyfish();
					shot_sky();
					
					
					if(level == level_melo)
					{
						start_melo = false;
						level_melo += 5;
						if(melo_s == 1)
						{
							melo_s+=2;
						}
						if(melo_s == 2)
						{
							melo_s+=2;
						}
						if(melo_s == 0)
						{
							melo_s += shot_kaisuu%2+1;
						}
						if(melo_s > 5)
						{
							start_melo = true;
							melo_s = 5;
						}
					}

					if(start_melo == false)
					{
						
						StopSoundMem(bgm[0]);
						StopSoundMem(bgm[1]);
						StopSoundMem(bgm[2]);
						StopSoundMem(bgm[3]);
						StopSoundMem(bgm[4]);
						PlaySoundMem(bgm[melo_s],DX_PLAYTYPE_LOOP);
						start_melo = true;
					}
				}

				DrawGraph(0,0,g_wall_soto,TRUE);

				if(score >= 1999999999)
				{
					score = 1999999999;
				}
				if(score >= highscore)
				{
					highscore = score;
				}
				DrawFormatStringToHandle(200,463,GetColor(255,100,255),font_score,"HIGHSCORE: %d",highscore);
				DrawFormatStringToHandle(200,447,GetColor(255,100,255),font_score,"    SCORE: %d",score);
				DrawFormatStringToHandle(24,454,GetColor(255,122,0),font_lv,"Lv. %d",level);
				if(combo >= 4)
				{
					DrawFormatStringToHandle(500,454,GetColor(122,122,255),font_lv,"%d HIT!",combo);
				}
			}
			else if(game_endflag == true)
			{
				gameover();

			}
		}
		get_option();
	}

}
Example #21
0
void graph_result(){
	graph_board();//ボードの描画

	if(count >= 120){
		if(func_state == 3)
			DrawStringToHandle(170,80,"CLEAR",color[0],font[1]);
		else
			DrawStringToHandle(140,80,"GAME OVER",color[0],font[1]);

		DrawStringToHandle(125,160,"難易度",color[0],font[0]);
		switch(stage){
			case 0:
				DrawStringToHandle(295,160,"EASY",color[0],font[0]);
				break;
			case 1:
				DrawStringToHandle(290,160,"NORMAL",color[3],font[0]);
				break;
			case 2:
				DrawStringToHandle(295,160,"HARD",color[2],font[0]);
				break;
			case 3:
				DrawStringToHandle(275,160,"LUNATIC",color[7],font[0]);
				break;
			case 4:
				DrawStringToHandle(295,160,"皆伝",color[0],font[0]);
		}
	}

	if(count >= 180){
		DrawStringToHandle(125,190,"グレイズ回数",color[0],font[0]);
		DrawFormatStringToHandle(290,190,color[0],font[0],"%d",ch.graze);
		DrawStringToHandle(330,190,"回",color[0],font[0]);
	}

	if(count >= 240){
		DrawStringToHandle(125,220,"スペル取得数",color[0],font[0]);
		DrawFormatStringToHandle(310,220,color[0],font[0],"%d",spell);
		DrawStringToHandle(330,220,"回",color[0],font[0]);
	}

	if(count >= 300){
		DrawStringToHandle(125,250,"総合達成度",color[0],font[0]);
		if(func_state == 3){
			int dif[4]={1,3,6,10};//グレイズボーナスの難易度別基準
			int grb = (ch.graze/dif[stage] < 200)? ch.graze/dif[stage]:200;//グレイズボーナス

			ch.grade = int(100 + ((spell*20)+grb)*(ch.percent/100));
		}
		else
			ch.grade = (scount*100)/19800;
		DrawFormatStringToHandle(300,250,color[0],font[0],"%d",ch.grade);
		DrawFormatStringToHandle(330,250,color[0],font[0],"%");

		DrawStringToHandle(125,295,"ランク",color[0],font[0]);
		if(type == 2){
			if(ch.grade >= 250){
				DrawFormatStringToHandle(260,285,color[5],font[1],"AAA+");
			}
			else if(ch.grade >= 200){
				DrawFormatStringToHandle(275,285,color[5],font[1],"AAA");
			}
			else if(ch.grade >= 140){
				DrawFormatStringToHandle(290,285,color[5],font[1],"AA");
			}
			else if(ch.grade >= 100){
				DrawFormatStringToHandle(305,285,color[5],font[1],"A");
			}
			else if(ch.grade >= 60){
				DrawFormatStringToHandle(305,285,color[4],font[1],"B");
			}
			else if(ch.grade >= 30){
				DrawFormatStringToHandle(305,285,color[7],font[1],"C");
			}
			else{
				DrawFormatStringToHandle(305,285,color[0],font[1],"D");
			}
		}
		else{
			if(ch.grade >= 210){
				DrawFormatStringToHandle(275,285,color[5],font[1],"AAA");
			}
			else if(ch.grade >= 150){
				DrawFormatStringToHandle(290,285,color[5],font[1],"AA");
			}
			else if(ch.grade >= 100){
				DrawFormatStringToHandle(305,285,color[5],font[1],"A");
			}
			else if(ch.grade >= 70){
				DrawFormatStringToHandle(305,285,color[4],font[1],"B");
			}
			else if(ch.grade >= 40){
				DrawFormatStringToHandle(305,285,color[7],font[1],"C");
			}
			else{
				DrawFormatStringToHandle(305,285,color[0],font[1],"D");
			}
		}
	}

	if(count >= 330){
		DrawStringToHandle(155,350,"もう一度挑戦する",color[0],font[0]);
		DrawStringToHandle(160,390,"タイトルに戻る",color[0],font[0]);
		DrawStringToHandle(160,430,"リプレイの再生",color[0],font[0]);
		DrawStringToHandle(140,350+(menu_state*40),"→",color[0],font[0]);

		if(ch.grade>=100.0){
			switch(stage){
			case 0:
				DrawStringToHandle(475,190,"EASYクリア",color[0],font[0]);
				DrawStringToHandle(470,210,"おめでとう!",color[0],font[0]);
				DrawStringToHandle(470,260,"慣れてきたら",color[0],font[0]);
				DrawStringToHandle(480,280,"NORMALにも",color[0],font[0]);
				DrawStringToHandle(455,300,"挑戦してみよう!",color[0],font[0]);
				break;
			case 1:
				DrawStringToHandle(465,190,"NORMALクリア",color[0],font[0]);
				DrawStringToHandle(470,210,"おめでとう!",color[0],font[0]);
				DrawStringToHandle(460,260,"余裕があるなら",color[0],font[0]);
				DrawStringToHandle(470,280,"HARDクリアを",color[0],font[0]);
				DrawStringToHandle(455,300,"目指してみよう!",color[0],font[0]);
				break;
			case 2:
				DrawStringToHandle(480,190,"HARDクリア",color[0],font[0]);
				DrawStringToHandle(475,210,"おめでとう!",color[0],font[0]);
				DrawStringToHandle(445,260,"なかなかやりますね",color[0],font[0]);
				DrawStringToHandle(455,280,"貴方にLUNATICは",color[0],font[0]);
				DrawStringToHandle(455,300,"攻略できるかな?",color[0],font[0]);
				break;
			case 3:
				DrawStringToHandle(460,190,"LUNATICクリア",color[0],font[0]);
				DrawStringToHandle(470,210,"おめでとう!",color[0],font[0]);
				DrawStringToHandle(450,260,"難易度選択画面で",color[0],font[0]);
				DrawStringToHandle(460,280,"LキーとRキーを",color[0],font[0]);
				DrawStringToHandle(430,300,"1秒間押し続けると…?",color[0],font[0]);
				break;
			case 4:
				DrawStringToHandle(475,190,"皆伝クリア",color[0],font[0]);
				DrawStringToHandle(470,210,"おめでとう!",color[0],font[0]);
				DrawStringToHandle(480,260,"もう貴方、",color[0],font[0]);
				DrawStringToHandle(425,280,"人間じゃないでしょう?",color[0],font[0]);
				break;
			}
		}
		//推移グラフ
		DrawFormatStringToHandle(475,330,color[0],font[1],"Graph");
		for(int i = 0;(i < 99)&&(ch.percent_graph[i] > 0);i++){
			//推移保持配列から値の取り出し
			int y1 = ch.percent_graph[i];
			int y2 = ch.percent_graph[i+1];
			//取り出した2点の線引き
			DrawLine(475+i,470-y1,475+(i+1),470-y2,color[2]);
		}
		DrawLine(475,470,475,370,color[0]);
		DrawLine(475,470,575,470,color[0]);
	}
}
Example #22
0
void showHeader(int x  ,int y){

	DrawFormatStringToHandle(0,0,GetColor(255,255,255),FontHandle1, "[##] data | compare = %d swap = %d",x,y);
	DrawFormatStringToHandle(0,20,GetColor(255,255,255),FontHandle1, " ------------------------------------------------------------------------",x,y);

}
Example #23
0
//文字を描画
void DrawImpl::text(const Vector2& pos, int color, int fontHandle, const std::string &str, int alpha, int blendMode){
	SetDrawBlendMode(blendMode, alpha);
	DrawFormatStringToHandle(pos.x + dx, pos.y + dy, color, fontHandle, "%s", str.c_str());
	textDrawLog.set(pos, color, fontHandle, alpha, blendMode);
}
Example #24
0
void CBoard::select(int select_num) {

	int cursole[8] = {100, 140, 180, 220, 260, 300, 340, 380};

	// 背景画像
	DrawGraph(0, 0, ghandle_background, TRUE);

	if(savedata[0] == true) DrawFormatStringToHandle(10, 110, light_blue, font3, "Cleared!");
    if(select_num == 0) DrawFormatStringToHandle(100, 100, light_red, font1, "問題1  ジャンル: 理系  ノルマ: %d", quota[0]);
	else DrawFormatStringToHandle(100, 100, white, font1, "問題1  ジャンル: 理系  ノルマ: %d", quota[0]);

	if(savedata[1] == true) DrawFormatStringToHandle(10, 150, light_blue, font3, "Cleared!");
    if(select_num == 1) DrawFormatStringToHandle(100, 140, light_red, font1, "問題2  ジャンル: 文系  ノルマ: %d", quota[1]);
	else DrawFormatStringToHandle(100, 140, white, font1, "問題2  ジャンル: 文系  ノルマ: %d", quota[1]);

	if(savedata[2] == true) DrawFormatStringToHandle(10, 190, light_blue, font3, "Cleared!");
    if(select_num == 2) DrawFormatStringToHandle(100, 180, light_red, font1, "問題3  ジャンル: 文系  ノルマ: %d", quota[2]);
	else DrawFormatStringToHandle(100, 180, white, font1, "問題3  ジャンル: 文系  ノルマ: %d", quota[2]);

	if(savedata[3] == true) DrawFormatStringToHandle(10, 230, light_blue, font3, "Cleared!");
    if(select_num == 3) DrawFormatStringToHandle(100, 220, light_red, font1, "問題4  ジャンル: 文系  ノルマ: %d", quota[3]);
	else DrawFormatStringToHandle(100, 220, white, font1, "問題4  ジャンル: 文系  ノルマ: %d", quota[3]);

	if(savedata[4] == true) DrawFormatStringToHandle(10, 270, light_blue, font3, "Cleared!");
    if(select_num == 4) DrawFormatStringToHandle(100, 260, light_red, font1, "問題5  ジャンル: アニメ・ゲーム  ノルマ: %d", quota[4]);
	else DrawFormatStringToHandle(100, 260, white, font1, "問題5  ジャンル: アニメ・ゲーム  ノルマ: %d", quota[4]);

	if(savedata[5] == true) DrawFormatStringToHandle(10, 310, light_blue, font3, "Cleared!");
    if(select_num == 5) DrawFormatStringToHandle(100, 300, light_red, font1, "問題6  ジャンル: アニメ・ゲーム  ノルマ: %d", quota[5]);
	else DrawFormatStringToHandle(100, 300, white, font1, "問題6  ジャンル: アニメ・ゲーム  ノルマ: %d", quota[5]);

	if(savedata[6] == true) DrawFormatStringToHandle(10, 350, light_blue, font3, "Cleared!");
    if(select_num == 6) DrawFormatStringToHandle(100, 340, light_red, font1, "問題7  ジャンル: ノンジャンル  ノルマ: %d", quota[6]);
	else DrawFormatStringToHandle(100, 340, white, font1, "問題7  ジャンル: ノンジャンル  ノルマ: %d", quota[6]);

	if(savedata[7] == true) DrawFormatStringToHandle(10, 390, light_blue, font3, "Cleared!");
    if(select_num == 7) DrawFormatStringToHandle(100, 380, light_red, font1, "問題8  ジャンル: 理系  ノルマ: %d", quota[7]);
	else DrawFormatStringToHandle(100, 380, white, font1, "問題8  ジャンル: 理系  ノルマ: %d", quota[7]);

}
Example #25
0
//文字の右上の座標を指定して文字を描画
void DrawImpl::rightText(const Vector2& pos, int color, int fontHandle, const std::string &str, int alpha, int blendMode){
	SetDrawBlendMode(blendMode, alpha);
	int wd = GetDrawFormatStringWidthToHandle(fontHandle, "%s", str.c_str());
	DrawFormatStringToHandle(pos.x + dx - wd, pos.y + dy, color, fontHandle, "%s", str.c_str());
}