#TouhouDanmakufu[Plural]
#ScriptVersion[3]
#Title["stage 1 boss script"]
#Text[test5] 
#include "./3dstage1.txt"
#include "./names.txt"
#include "script/sample/nociception/my_system/BGMtasks.txt"


@Initialize{
    TPlural;
	name;
}
@MainLoop{

    yield;
}



task TPlural{
if (GetCommonData("Difficulty", 3) == 3){
    let dir = GetCurrentScriptDirectory();
    let obj = ObjEnemyBossScene_Create();
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./appear1.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Dialogtest.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Nonspell.txt");
    ObjEnemyBossScene_Add(obj, 1, dir ~ "./Spellcard1.txt");
	ObjEnemyBossScene_Add(obj, 2, dir ~ "./Nonspell2.txt");
    ObjEnemyBossScene_Add(obj, 3, dir ~ "./Spellcard3.txt");
	ObjEnemyBossScene_Add(obj, 3, dir ~ "./Nonspell3.txt");
	ObjEnemyBossScene_Add(obj, 4, dir ~ "./Spellcard5.txt");
	ObjEnemyBossScene_Add(obj, 4, dir ~ "./forfun.txt");
	ObjEnemyBossScene_Add(obj, 5, dir ~ "./Dialogtest2.txt");
    ObjEnemyBossScene_LoadInThread(obj);
    ObjEnemyBossScene_Regist(obj);
    while(!Obj_IsDeleted(obj)){
        yield;
    }
	}

if (GetCommonData("Difficulty", 2) == 2){
    let dir = GetCurrentScriptDirectory();
    let obj = ObjEnemyBossScene_Create();
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./appear1.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Dialogtest.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Nonspell.txt");
    ObjEnemyBossScene_Add(obj, 1, dir ~ "./Spellcard1.txt");
	ObjEnemyBossScene_Add(obj, 2, dir ~ "./Nonspell2.txt");
    ObjEnemyBossScene_Add(obj, 3, dir ~ "./Spellcard3.txt");
	ObjEnemyBossScene_Add(obj, 3, dir ~ "./Nonspell3.txt");
	ObjEnemyBossScene_Add(obj, 4, dir ~ "./Spellcard5.txt");
	ObjEnemyBossScene_Add(obj, 4, dir ~ "./forfun.txt");
	ObjEnemyBossScene_Add(obj, 5, dir ~ "./Dialogtest2.txt");
    ObjEnemyBossScene_LoadInThread(obj);
    ObjEnemyBossScene_Regist(obj);
    while(!Obj_IsDeleted(obj)){
        yield;
    }
	}

if (GetCommonData("Difficulty", 1) == 1){
    let dir = GetCurrentScriptDirectory();
    let obj = ObjEnemyBossScene_Create();
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./appear1.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Dialogtest.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Nonspell.txt");
    ObjEnemyBossScene_Add(obj, 1, dir ~ "./Spellcard1.txt");
	ObjEnemyBossScene_Add(obj, 2, dir ~ "./Nonspell2.txt");
    ObjEnemyBossScene_Add(obj, 3, dir ~ "./Spellcard3.txt");
	ObjEnemyBossScene_Add(obj, 3, dir ~ "./Nonspell3.txt");
	ObjEnemyBossScene_Add(obj, 4, dir ~ "./Spellcard5.txt");
	ObjEnemyBossScene_Add(obj, 5, dir ~ "./Dialogtest2.txt");
    ObjEnemyBossScene_LoadInThread(obj);
    ObjEnemyBossScene_Regist(obj);
    while(!Obj_IsDeleted(obj)){
        yield;
    }
	}
	
	
	if (GetCommonData("Difficulty", 0) == 0){
	let dir = GetCurrentScriptDirectory();
    let obj = ObjEnemyBossScene_Create();
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./appear1.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Dialogtest.txt");
	ObjEnemyBossScene_Add(obj, 0, dir ~ "./Nonspell.txt");
    ObjEnemyBossScene_Add(obj, 1, dir ~ "./Spellcard1.txt");
	ObjEnemyBossScene_Add(obj, 2, dir ~ "./Nonspell2.txt");
    ObjEnemyBossScene_Add(obj, 3, dir ~ "./Spellcard3.txt");
	ObjEnemyBossScene_Add(obj, 3, dir ~ "./Nonspell3.txt");
	ObjEnemyBossScene_Add(obj, 4, dir ~ "./Spellcard5.txt");
	ObjEnemyBossScene_Add(obj, 5, dir ~ "./Dialogtest2.txt");
    ObjEnemyBossScene_LoadInThread(obj);
    ObjEnemyBossScene_Regist(obj);
	while(!Obj_IsDeleted(obj)){
        yield;
    }
	}

    CloseScript(GetOwnScriptID());
}





