NarumiSTG_HyperSnowDrifter/script/Gay_Package.dnh

1509 lines
75 KiB
Plaintext
Raw Permalink Normal View History

2023-01-26 11:34:56 +00:00
<EFBFBD><EFBFBD>#qg<71>e>_U^<5E><>[Package]
#Title["be gay do crimes"]
#Text["NOOOO I DON'T WANNA MAKE MENUS *dies*"]
// Font installation: Anke Calligraph, Connecting Chain Handserif, Unispace, etc.
string pathPlayer = "";
string pathStage = "";
string[] PlayerArray =
["script/player/PrideJam_ByakMiko/ByakMiko_Main.dnh",
"script/player/PrideJam_RinnoRemi/RinnoRemi_Main.dnh"];
string[] StageArray =
["script/game/Stage_Arcade.dnh",
"script/game/Stage_Gentle.dnh"];
float BGMRate = GetAreaCommonData("Config", "BGMVol", 100) * 0.01;
int objTitleBGM = ObjSound_Create();
@Initialize
{
StartScript("script/KevinSystem/Init.dnh");
AddArchiveFile("script/game.dat");
AddArchiveFile("script/KevinSystem.dat");
ObjSound_Load(objTitleBGM, "script/game/packageLib/MusicTitle.mp3");
ObjSound_SetSoundDivision(objTitleBGM, SOUND_BGM);
ObjSound_SetResumeEnable(objTitleBGM, true);
ObjSound_SetLoopEnable(objTitleBGM, true);
ObjSound_SetVolumeRate(objTitleBGM, 75*BGMRate);
if(IsCommonDataAreaExists("PIV") == false){
CreateCommonDataArea("PIV");
SetAreaCommonData("PIV", "currentvalue", 10000);
}
else{
SetAreaCommonData("PIV", "currentvalue", 10000);
}
if(IsCommonDataAreaExists("ScriptID") == false){
CreateCommonDataArea("ScriptID");
SetAreaCommonData("ScriptID", "SystemID", 0);
SetAreaCommonData("ScriptID", "ItemID", 0);
}
TInstallFont();
LanguageSelect();
let diffIndex = 0;
let playerIndex = 0;
}
let dirSystem = "script/KevinSystem/";
int lang = GetCommonData("Language", 0);
function TInstallFont{
/*
// JP Text
InstallFont(dirSystem ~ "./font/FOT-NewCinemaAStd-D_1.otf");
InstallFont(dirSystem ~ "./font/Corporate-Logo-Rounded.otf");
InstallFont(dirSystem ~ "./font/OtsutomeFont_Ver3.ttf");
// English Text
InstallFont(dirSystem ~ "./font/Revue Regular.ttf");
InstallFont(dirSystem ~ "./font/Uni Sans Heavy.otf");
InstallFont(dirSystem ~ "./font/Exotic 350 Demi Bold BT.ttf");
InstallFont(dirSystem ~ "./font/unispace rg.ttf");
InstallFont(dirSystem ~ "./font/Connecting Chain Handserif.ttf");
InstallFont(dirSystem ~ "./font/AnkeCall.ttf");
// Misc
InstallFont(dirSystem ~ "./font/origa___.ttf");
*/
string[] FontList = GetFilePathList("script/KevinSystem/font/");
for each(string font in ref FontList){
InstallFont(font);
}
}
// Initialize common data: Configurations, high scores for difficulties and players
/* CONFIG
BGM Volume
Sound Volume
Starting Lives Setting (0 to 999) (but why would you want to set your starting lives to 0??????)
Background Opacity (255 to 0, disables background rendering if at 0)
Dialogue Skip Setting (ON/OFF)
*/
// Load/create common data for config
if(LoadCommonDataAreaA2("Config", "script/game/config.dat") == false){
CreateCommonDataArea("Config");
SetAreaCommonData("Config", "BGMVol", 100);
SetAreaCommonData("Config", "SEVol", 100);
SetAreaCommonData("Config", "StartingLife", 3);
SetAreaCommonData("Config", "BGOpacity", 100); // By percentage
SetAreaCommonData("Config", "DialogueSkip", 0); // 0: no, 1: yes
SetAreaCommonData("Config", "PlayerShotOpacity", 60);
2023-02-08 06:21:04 +00:00
//SetAreaCommonData("Config", "BGMSelect", 0); // O: Yal, 1: Wareya
SetAreaCommonData("Config", "ExplosionOpacity", 100);
2023-01-26 11:34:56 +00:00
SetAreaCommonData("Config", "ItemOpacity", 60);
// 1.01a
SetAreaCommonData("Config", "EffectCut", 0);
SaveCommonDataAreaA2("Config", "script/game/config.dat");
}
else{
LoadCommonDataAreaA2("Config", "script/game/config.dat");
}
// High Score
if(LoadCommonDataAreaA2("Data", "script/game/data.dat") == false){
CreateCommonDataArea("Data");
SetAreaCommonData("Data", "High Score", 0);
SaveCommonDataAreaA2("Data", "script/game/data.dat");
}
else{
LoadCommonDataAreaA2("Data", "script/game/data.dat");
}
@MainLoop
{
lang = GetCommonData("Language", 0);
yield;
}
@Finalize
{
}
// Lol mkm
function CreateTextObject(
float mx, my, size,
string text, font,
int colorTop, colorBottom,
int borderColor, borderWidth,
int renderPriority
){
let obj = ObjText_Create();
ObjText_SetText(obj, text);
ObjText_SetFontSize(obj, size);
ObjText_SetFontType(obj, font);
ObjText_SetFontColorTop(obj, colorTop);
ObjText_SetFontColorBottom(obj, colorBottom);
ObjText_SetFontBorderType(obj, BORDER_FULL);
ObjText_SetFontBorderColor(obj, borderColor);
ObjText_SetFontBorderWidth(obj, borderWidth);
Obj_SetRenderPriorityI(obj, renderPriority);
ObjRender_SetX(obj, mx);
ObjRender_SetY(obj, my);
return obj;
}
function <int> _Create2DImage(imgpath, int[] rectarray){
int imgname = ObjPrim_Create(OBJ_SPRITE_2D);
ObjPrim_SetTexture(imgname, imgpath);
ObjSprite2D_SetSourceRect(imgname, rectarray);
ObjSprite2D_SetDestCenter(imgname);
//ObjRender_SetPosition(imgname, positionstart)
return imgname;
}
function DigitToCommaArray(num){ //Natashinitai
let srcStr = IntToString(num);
let res = [];
let nChar = 0;
for(let i = length(srcStr) - 1; i >= 0; i--){
res = [srcStr[i]] ~ res;
nChar++;
if(nChar % 3 == 0 && i > 0) res = "," ~ res;
}
return res;
}
//----------------------------------------------------
// <00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
task LanguageSelect(){
int image = _Create2DImage("script/game/PackageLib/DISCLAIMER.png", [0, 0, 1920, 1080]);
LoadTextureEx(image, true, true);
Obj_SetRenderPriorityI(image, 0);
ObjSprite2D_SetDestRect(image, 0, 0, 1920, 1080);
let bEndTitleScene = false;
task TMenuItem(
let index,
float mx, my, size,
string text
)
{
let objText = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0x070076, size/10,
2
);
let objSelect = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0x070076, size/10,
2
);
//ObjText_SetMaxWidth(objText, GetScreenWidth());
ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
//ObjText_SetMaxWidth(objSelect, GetScreenWidth);
ObjText_SetHorizontalAlignment(objSelect, ALIGNMENT_CENTER);
ObjRender_SetBlendType(objSelect, BLEND_ADD_RGB);
while(!bEndTitleScene)
{
Obj_SetVisible(objSelect, index == selectIndex);
yield;
}
Obj_Delete(objText);
Obj_Delete(objSelect);
}
let INDEX_ENG = 0;
let selectIndex = 0;//x<><78>bMOn
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0M<30>n
let mx = GetScreenWidth()/2;
let my = 7*GetScreenHeight()/8;
let texts = ["Press CONFIRM/SHOT to Continue."];
var countMenu = length(texts);
ascent(var iText in 0 .. countMenu)
{
TMenuItem(iText, mx, my, 40, texts[iText]);
my += 120;
}
// Create Extend Text
//<00>0<EFBFBD>0<EFBFBD>rKaL0<4C>0<EFBFBD>0<EFBFBD>0<EFBFBD>0U0<55>0<EFBFBD>0~0g0<67>__j
while(GetVirtualKeyState(VK_OK) != KEY_FREE){yield;}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>Qt
let frameKeyHold = 0;//<00>0<EFBFBD>0<EFBFBD>bW0c0q0j0W0<57>0<EFBFBD>0<EFBFBD>0<EFBFBD>0pe
loop
{
//zl<7A>[
if(GetVirtualKeyState(VK_OK) == KEY_PUSH)
{
TTitleScene();
break;
}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>y<EFBFBD>R
if(GetVirtualKeyState(VK_UP) == KEY_PUSH)
{
selectIndex--;
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_PUSH)
{
selectIndex++;
}
else if(GetVirtualKeyState(VK_UP) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex--;
}
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex++;
}
}
else
{
frameKeyHold = 0;
}
if(selectIndex < 0)
{
selectIndex = countMenu - 1;
}
else
{
selectIndex %= countMenu;
}
yield;
}
bEndTitleScene = true;
//Obj_Delete(objText);
Obj_Delete(image);
}
task TTitleScene
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0B}<7D>N<EFBFBD>0<EFBFBD>0<EFBFBD>0
float startY = GetScreenHeight()/2;
if(!ObjSound_IsPlaying(objTitleBGM)){ObjSound_Play(objTitleBGM);}
if(IsCommonDataAreaExists("PIV") == false){
CreateCommonDataArea("PIV");
SetAreaCommonData("PIV", "currentvalue", 10000);
}
else{
SetAreaCommonData("PIV", "currentvalue", 10000);
}
let objText = CreateTextObject(
GetScreenWidth()/2, 0.75*GetScreenHeight()/5, 50,
"", "Otsutome_font Bold",
0xFFFFFF, 0xFFFFFF,
0xC02456, 60/10,
2
);
ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
/*ObjText_SetText(objText,
"[font sz=150 oc=(78, 102, 255)]qg<71>e7lVn<56>f[r][font sz=90 oc=(0, 26, 190)]RAMPAGE OF THE STRONGEST!"
);*/
int image = _Create2DImage("script/game/PackageLib/TitleImage_Base.png", [0, 0, 1920, 1080]);
LoadTextureEx(image, true, true);
Obj_SetRenderPriorityI(image, 0);
ObjSprite2D_SetDestRect(image, 0, 0, 1920, 1080);
int image2 = _Create2DImage("script/game/PackageLib/Title.png", [0, 0, 1920, 1080]);
LoadTextureEx(image2, true, true);
ObjRender_SetY(image2, startY);
Obj_SetRenderPriorityI(image2, 1);
ObjSprite2D_SetDestCenter(image2);
let bEndTitleScene = false;
let objScore = CreateTextObject(
GetScreenWidth()/2, 8*GetScreenHeight()/9, 45,
"", "Unispace",
0xFFFFFF, 0xFFE8A6,
0xFF9700, 45/10,
2
);
ObjText_SetHorizontalAlignment(objScore, ALIGNMENT_CENTER);
int skor = GetAreaCommonData("Data", "High Score", 0);
// yandev???
if (skor >= 4000000000){
ObjText_SetText(objScore,
"YOU ARE THE STRONGEST!!!!!! " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
else if (skor >= 4000000000){
ObjText_SetText(objScore,
"WOAH! INCREDIBLE!? " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
else if (skor >= 2500000000){
ObjText_SetText(objScore,
"HALL OF FAME: " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
else if (skor >= 1000000000){
ObjText_SetText(objScore,
"DEVIL'S RECORD: " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
else if (skor >= 500000000){
ObjText_SetText(objScore,
"RECORD OF VICTORY: " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
else if (skor > 0){
ObjText_SetText(objScore,
"HIGH SCORE: " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
else{
ObjText_SetText(objScore,
"HIGH SCORE: " ~ DigitToCommaArray(GetAreaCommonData("Data", "High Score", 0))
);
}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
task TMenuItem(
let index,
float mx, my, size,
string text
)
{
let objText = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0x070076, size/10,
2
);
let objSelect = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0x070076, size/10,
2
);
//ObjText_SetMaxWidth(objText, GetScreenWidth());
ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
//ObjText_SetMaxWidth(objSelect, GetScreenWidth);
ObjText_SetHorizontalAlignment(objSelect, ALIGNMENT_CENTER);
ObjRender_SetBlendType(objSelect, BLEND_ADD_RGB);
Obj_SetVisible(objSelect, false);
while(!bEndTitleScene)
{
if(index == selectIndex){
ObjText_SetFontBorderWidth(objText, size/6);
ObjText_SetFontSize(objText, size*1.15);
ObjText_SetFontBorderColor(objText, 0xD080FF);
}
else{
ObjText_SetFontBorderWidth(objText, size/10);
ObjText_SetFontSize(objText, size);
ObjText_SetFontBorderColor(objText, 0x775FB7);
}
yield;
}
Obj_Delete(objText);
Obj_Delete(objSelect);
}
let INDEX_START = 0;
let INDEX_MANUAL = 1;
let INDEX_REPLAY = 2;
let INDEX_CONFIG = 3;
let INDEX_QUIT = 4;
let selectIndex = 0;//x<><78>bMOn
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0M<30>n
let mx = 3*GetScreenWidth()/4;
let my = 2.6*GetScreenHeight()/5;
let texts = ["START GAME", "MANUAL UNDER CONSTRUCTION...", "VIEW REPLAY", "OPTIONS", "END GAME"];
var countMenu = length(texts);
ascent(var iText in 0 .. countMenu)
{
TMenuItem(iText, mx, my, 48, texts[iText]);
my += 60;
}
//<00>0<EFBFBD>0<EFBFBD>rKaL0<4C>0<EFBFBD>0<EFBFBD>0<EFBFBD>0U0<55>0<EFBFBD>0~0g0<67>__j
while(GetVirtualKeyState(VK_OK) != KEY_FREE){yield;}
async{
float ang = 90;
ObjRender_SetX(image2, GetScreenWidth()/2);
ObjRender_SetY(image2, GetScreenHeight()/2 + 60 * sin(ang));
while(!bEndTitleScene && !Obj_IsDeleted(image2) && !Obj_IsDeleted(image)){
ObjRender_SetY(image2, GetScreenHeight()/2 + 60 * sin(ang));
ang += 1.5;
yield;
}
}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>Qt
let frameKeyHold = 0;//<00>0<EFBFBD>0<EFBFBD>bW0c0q0j0W0<57>0<EFBFBD>0<EFBFBD>0<EFBFBD>0pe
loop
{
//zl<7A>[
if(GetVirtualKeyState(VK_OK) == KEY_PUSH)
{
if(selectIndex == INDEX_START)
{
SetCommonData("Difficulty", "Standard");
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
ObjSound_Stop(objTitleBGM);
}
if(selectIndex == INDEX_MANUAL)
{
SetCommonData("Difficulty", "Standard");
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
}
else if(selectIndex == INDEX_REPLAY)
{
TReplaySelectScene();
}
else if(selectIndex == INDEX_CONFIG)
{
TConfigScene();
}
else if(selectIndex == INDEX_QUIT)
{
ClosePackage();
}
break;
}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>y<EFBFBD>R
if(GetVirtualKeyState(VK_UP) == KEY_PUSH)
{
selectIndex--;
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_PUSH)
{
selectIndex++;
}
else if(GetVirtualKeyState(VK_UP) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex--;
}
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex++;
}
}
else
{
frameKeyHold = 0;
}
if(selectIndex < 0)
{
selectIndex = countMenu - 1;
}
else
{
selectIndex %= countMenu;
}
yield;
}
bEndTitleScene = true;
Obj_Delete(image);
Obj_Delete(image2);
Obj_Delete(objText);
Obj_Delete(objScore);
}
// Configurations
task TConfigScene{
// Credit: Kobito
int image = _Create2DImage("script/game/PackageLib/TitleImage_Base.png", [0, 0, 1920, 1080]);
LoadTextureEx(image, true, true);
Obj_SetRenderPriorityI(image, 0);
ObjSprite2D_SetDestRect(image, 0, 0, 1920, 1080);
let bEndTitleScene = false;
// BGM, SE, Life, BG, Skip, PlayerShot, Item
let settingDefault = [100, 100, 3, 100, 60, 60, 0];
let setting = [0, 0, 0, 0, 0, 0, 0];
let settingMax = [100, 100, 999, 100, 100, 100, 3];
let holdInterval = [2, 2, 1, 2, 2, 2, 30];
setting[0] = GetAreaCommonData("Config", "BGMVol", 100);
setting[1] = GetAreaCommonData("Config", "SEVol", 100);
setting[2] = GetAreaCommonData("Config", "StartingLife", 3);
setting[3] = GetAreaCommonData("Config", "BGOpacity", 255);
setting[4] = GetAreaCommonData("Config", "PlayerShotOpacity", 60);
setting[5] = GetAreaCommonData("Config", "ItemOpacity", 60);
setting[6] = GetAreaCommonData("Config", "EffectCut", 0);
let selectIndex = 0;
var countMenu = 8;
let texts = [0, 0, 0, 0, 0, 0, 0, 0];
let objWarning = CreateTextObject(
GetScreenWidth()/2, 10*GetScreenHeight()/12, [38, 48][lang],
["High scores are only saved with 3 starting lives or fewer.[r]Press X/Cancel to save settings and return to the menu.",
"<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<1C><1D><13>_0<5F>0`0Q0<51>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0o0<18>2<EFBFBD>W0~0Y00[r]X/CANCEL<1A><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0h0<68>0<EFBFBD>0<EFBFBD>0<EFBFBD>0k00^<5E>0"][lang], "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0xFF6D64, 35/10,
2
);
ObjText_SetHorizontalAlignment(objWarning, ALIGNMENT_CENTER);
function <int> TMenuItem(
let index,
float mx, my, size,
string text
)
{
let objText = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0x000000, size/10,
2
);
//ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
async{
while(!bEndTitleScene)
{
if(index == selectIndex){ObjRender_SetColor(objText, 255, 255, 255);}
else{ObjRender_SetColor(objText, 100, 100, 100);}
yield;
}
Obj_Delete(objText);
}
return objText;
}
float mx = GetScreenWidth()/2-GetScreenWidth()/5;
float my = 1.5*GetScreenHeight()/12;
ascent(i in 0..8){texts[i] = TMenuItem(i, mx, my+i*GetScreenHeight()/15, 45, "");}
ObjText_SetText(texts[7], ["Reset to Default", "DEFAULT"][lang]);
function ChangeSetting(a, b){
setting[a] += b;
if(setting[a] < 0){setting[a] = settingMax[a];}
else if(setting[a] > settingMax[a]){setting[a] = 0;}
}
let configText = [
["BGM Volume: ", "SFX Volume:", "Starting Lives:", "Background Opacity:", "Player Shot Opacity:", "Item Opacity: ", "Effect Cut Level: "],
["BGM Vol: ", "SFX Vol: ", "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0: ", "̀ofn0<0F>f:", "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0n0<0F>f: ", "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0n0<0F>f:", "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0:"]
];
function UpdateTexts{
ObjText_SetText(texts[0], configText[lang][0]~" " ~ IntToString(setting[0]));
ObjText_SetText(texts[1], configText[lang][1]~" " ~ IntToString(setting[1]));
ObjText_SetText(texts[2], configText[lang][2]~" " ~ IntToString(setting[2]));
ObjText_SetText(texts[3], configText[lang][3]~" " ~ IntToString(setting[3]) ~ "%");
alternative(setting[4])
case(0){ObjText_SetText(texts[4], configText[lang][4]~" " ~ IntToString(setting[4]) ~ [" (Why???)", " (j0<6A>0g0???)"][lang]);}
case(60){ObjText_SetText(texts[4],configText[lang][4]~" " ~ IntToString(setting[4]) ~ [" (Recommended)", " (<00>c<EFBFBD><63>)"][lang]);}
case(100){ObjText_SetText(texts[4],configText[lang][4]~" " ~ IntToString(setting[4]) ~ [" (Eye-Blinding)", " (<06>
N)"][lang]);}
others{ObjText_SetText(texts[4], configText[lang][4]~" " ~ IntToString(setting[4]));}
alternative(setting[5])
case(0){ObjText_SetText(texts[5], configText[lang][5]~" " ~ IntToString(setting[5]) ~ [" (Why???)", " (j0<6A>0g0???)"][lang]);}
case(60){ObjText_SetText(texts[5], configText[lang][5]~" " ~ IntToString(setting[5]) ~ [" (Recommended)", " (<00>c<EFBFBD><63>)"][lang]);}
case(100){ObjText_SetText(texts[5], configText[lang][5]~" " ~ IntToString(setting[5]) ~ [" (Eye-Blinding)", " (<06>
N)"][lang]);}
others{ObjText_SetText(texts[5], configText[lang][5]~" " ~ IntToString(setting[5]));}
alternative(setting[6])
case(0){ObjText_SetText(texts[6], configText[lang][6]~ " " ~ IntToString(setting[6]) ~ [" (Full Effects)", " (hQ萨0<E890A8>0<EFBFBD>0<EFBFBD>0<EFBFBD>0)"][lang]);}
case(1){ObjText_SetText(texts[6], configText[lang][6]~ " " ~ IntToString(setting[6]) ~ [" (No Item Popups)", " (<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0X0<58>0j0D0)"][lang]);}
case(2){ObjText_SetText(texts[6], configText[lang][6]~ " " ~ IntToString(setting[6]) ~ [" (No Explosion Effects)", " (rzv<7A>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0X0<58>0j0D0)"][lang]);}
case(3){ObjText_SetText(texts[6], configText[lang][6]~ " " ~ IntToString(setting[6]) ~ [" (No Effects)", " (<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0X0<58>0j0D0)"][lang]);}
others{ObjText_SetText(texts[6], configText[lang][6]~ " " ~ IntToString(setting[6]));}
}
UpdateTexts();
while(GetVirtualKeyState(VK_OK) != KEY_FREE){yield;}
let frameKeyHold = 0;
let frameKeyHoldSide = 0;
loop{
UpdateTexts();
if(GetVirtualKeyState(VK_CANCEL) == KEY_PUSH){
TTitleScene();
break;
}
// Select option to configure
if(GetVirtualKeyState(VK_UP) == KEY_PUSH){selectIndex--;}
else if(GetVirtualKeyState(VK_DOWN) == KEY_PUSH){selectIndex++;}
else if(GetVirtualKeyState(VK_UP) == KEY_HOLD){
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0))){selectIndex--;}
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_HOLD){
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0))){selectIndex++;}
}
else{frameKeyHold = 0;}
if(selectIndex < 0) {selectIndex = countMenu - 1;}
else{selectIndex %= countMenu;}
if(GetVirtualKeyState(VK_RIGHT) == KEY_HOLD || GetVirtualKeyState(VK_LEFT) == KEY_HOLD){frameKeyHoldSide++;}
else{frameKeyHoldSide = 0;}
if(GetVirtualKeyState(VK_RIGHT) == KEY_PUSH || GetVirtualKeyState(VK_RIGHT) == KEY_HOLD){
if(GetVirtualKeyState(VK_RIGHT) == KEY_PUSH || (frameKeyHoldSide >= 30 && frameKeyHoldSide % holdInterval[selectIndex] == 0)){
if (selectIndex >= 9){}
else{ChangeSetting(selectIndex, 1);}
}
}
else if(GetVirtualKeyState(VK_LEFT) == KEY_PUSH || GetVirtualKeyState(VK_LEFT) == KEY_HOLD){
if(GetVirtualKeyState(VK_LEFT) == KEY_PUSH || (frameKeyHoldSide >= 30 && frameKeyHoldSide % holdInterval[selectIndex] == 0)){
if (selectIndex >= 9){}
else{ChangeSetting(selectIndex, -1);}
}
}
if(selectIndex == 7 && GetVirtualKeyState(VK_OK) == KEY_PUSH){
ascent(i in 0..6){
setting[i] = settingDefault[i];
selectIndex = 0;
}
}
SetAreaCommonData("Config", "BGMVol", setting[0]);
SetAreaCommonData("Config", "SEVol", setting[1]);
SetAreaCommonData("Config", "StartingLife", setting[2]);
SetAreaCommonData("Config", "BGOpacity", setting[3]);
SetAreaCommonData("Config", "PlayerShotOpacity", setting[4]);
SetAreaCommonData("Config", "ItemOpacity", setting[5]);
SetAreaCommonData("Config", "EffectCut", setting[6]);
ObjSound_SetVolumeRate(objTitleBGM, 75*GetAreaCommonData("Config", "BGMVol", 100)*0.01);
ObjText_SetText(texts[7], ["Reset to Default", "DEFAULT"][lang]);
ObjText_SetText(objWarning,0["High scores are only saved with 3 starting lives or fewer.[r]Press X/Cancel to save settings and return to the menu.",0"<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<1C><1D><13>_0<5F>0`0Q0<51>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0o0<18>2<EFBFBD>W0~0Y00[r]X/CANCEL<1A><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0h0<68>0<EFBFBD>0<EFBFBD>0<EFBFBD>0k00^<5E>0"][lang]);
//SetSoundDivisionVolumeRate(SOUND_BGM, GetAreaCommonData("Config", "BGMVol", 100)*0.01);
//SetSoundDivisionVolumeRate(SOUND_SE, GetAreaCommonData("Config", "SEVol", 100)*0.01);
yield;
}
SaveCommonDataAreaA2("Config", "script/game/config.dat");
bEndTitleScene = true;
Obj_Delete(image);
Obj_Delete(objWarning);
}
// Manual
task TManualScene(){
bool bEndTitleScene = false;
int image = _Create2DImage("script/game/PackageLib/PlaceholderTitleImage_Player.png", [0, 0, 1920, 1080]);
LoadTextureEx(image, true, true);
Obj_SetRenderPriorityI(image, 0);
ObjRender_SetAlpha(image, 255/2);
ObjSprite2D_SetDestRect(image, 0, 0, 1920, 1080);
int imageManual = _Create2DImage(["script/game/PackageLib/Manual.png", "script/game/PackageLib/Manual_JP.png"][lang], [0, 0, 1920, 1080]);
LoadTextureEx(imageManual, true, true);
Obj_SetRenderPriorityI(imageManual, 1);
ObjRender_SetAlpha(imageManual, 255);
ObjSprite2D_SetDestRect(imageManual, 0, 0, 1920, 1080);
Obj_SetVisible(imageManual, false);
//Obj_SetVisible(imgArcade, false);
//Obj_SetVisible(imgGentle, false);
//<00>0<EFBFBD>0<EFBFBD>rKaL0<4C>0<EFBFBD>0<EFBFBD>0<EFBFBD>0U0<55>0<EFBFBD>0~0g0<67>__j
while(GetVirtualKeyState(VK_OK) != KEY_FREE){yield;}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>Qt
let frameKeyHold = 0;//<00>0<EFBFBD>0<EFBFBD>bW0c0q0j0W0<57>0<EFBFBD>0<EFBFBD>0<EFBFBD>0pe
loop
{
Obj_SetVisible(imageManual, true);
if(GetVirtualKeyState(VK_CANCEL) == KEY_PUSH){
TTitleScene();
break;
}
yield;
}
bEndTitleScene = true;
Obj_Delete(image);
Obj_Delete(imageManual);
}
//----------------------------------------------------
// <00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
task TDifficultySelect(){
bool bEndTitleScene = false;
int image = _Create2DImage("script/game/PackageLib/PlaceholderTitleImage_Player.png", [0, 0, 1920, 1080]);
LoadTextureEx(image, true, true);
Obj_SetRenderPriorityI(image, 0);
ObjSprite2D_SetDestRect(image, 0, 0, 1920, 1080);
//Obj_SetVisible(imgArcade, false);
//Obj_SetVisible(imgGentle, false);
task TMenuItem(
let index,
float mx, my, size,
string text
)
{
let objText = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0xAA0E2B, size/10,
2
);
let objSelect = CreateTextObject(
mx, my, size,
text, "<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<08><>0<EFBFBD>0<EFBFBD>0<EFBFBD>0 <09> ver2 Bold",
0xFFFFFF, 0xFFFFFF,
0xAA0E2B, size/10,
2
);
//ObjText_SetMaxWidth(objText, GetScreenWidth()/4);
ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
//ObjText_SetMaxWidth(objSelect, GetScreenWidth()/4);
ObjText_SetHorizontalAlignment(objSelect, ALIGNMENT_CENTER);
ObjRender_SetBlendType(objSelect, BLEND_ADD_RGB);
while(!bEndTitleScene)
{
Obj_SetVisible(objSelect, index == selectIndex);
yield;
}
Obj_Delete(objText);
Obj_Delete(objSelect);
}
let INDEX_NORMAL = 0;
let INDEX_HARD = 1;
let INDEX_LUNATIC = 2;
let selectIndex = 0;//x<><78>bMOn
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0M<30>n
let mx = GetScreenWidth()/2;
let my = 1*GetScreenHeight()/5;
let texts = [
[
"[font oc=(0, 147, 213) sz=90]Normal Mode[r][font oc=(50, 76, 156)]A lighthearted difficulty[r][font oc=(50, 76, 156)]for beginners and intermediate players.",
"[font oc=(220, 0, 219) sz=90]Hard Mode[r][font oc=(125, 14, 170)]A challenging difficulty[r][font oc=(125, 14, 170)]for ambitious players.",
"[font oc=(227, 0, 0) sz=90]Lunatic Mode[r][font oc=(114, 55, 46)]You can choose this, but why would you?"
],
[
"[font oc=(0, 147, 213) sz=90]Normal Mode[r][font oc=(50, 76, 156)]R<>_<05>n0_0<5F>0n0Y<30>K0j0<6A>0<EFBFBD>0<EFBFBD>0g0Y00",
"[font oc=(220, 0, 219) sz=90]Hard Mode[r][font oc=(125, 14, 170)]a2k<32>vj0 T<>Nn0_0<5F>0n0<6E><30>W0D0<44>0<EFBFBD>0<EFBFBD>0g0Y00",
"[font oc=(227, 0, 0) sz=90]Lunatic Mode[r][font oc=(114, 55, 46)]j0<6A>0g0?"
]
];
var countMenu = length(texts[lang]);
for(int iText = 0; iText <= 2; iText++)
{
TMenuItem(iText, mx, my, 40, texts[lang][iText]);
my += 240;
}
//<00>0<EFBFBD>0<EFBFBD>rKaL0<4C>0<EFBFBD>0<EFBFBD>0<EFBFBD>0U0<55>0<EFBFBD>0~0g0<67>__j
while(GetVirtualKeyState(VK_OK) != KEY_FREE){yield;}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>Qt
let frameKeyHold = 0;//<00>0<EFBFBD>0<EFBFBD>bW0c0q0j0W0<57>0<EFBFBD>0<EFBFBD>0<EFBFBD>0pe
loop
{
if(GetVirtualKeyState(VK_CANCEL) == KEY_PUSH){
TTitleScene();
break;
}
else if(GetVirtualKeyState(VK_OK) == KEY_PUSH)
{
if(selectIndex == INDEX_NORMAL)
{
SetCommonData("Difficulty", "Normal");
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
}
else if(selectIndex == INDEX_HARD)
{
SetCommonData("Difficulty", "Hard");
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
}
else if(selectIndex == INDEX_LUNATIC)
{
SetCommonData("Difficulty", "Lunatic");
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
}
break;
}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>y<EFBFBD>R
if(GetVirtualKeyState(VK_UP) == KEY_PUSH)
{
selectIndex--;
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_PUSH)
{
selectIndex++;
}
else if(GetVirtualKeyState(VK_UP) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex--;
}
}
else if(GetVirtualKeyState(VK_DOWN) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex++;
}
}
else
{
frameKeyHold = 0;
}
if(selectIndex < 0)
{
selectIndex = countMenu - 1;
}
else
{
selectIndex %= countMenu;
}
yield;
}
bEndTitleScene = true;
Obj_Delete(image);
}
task TPlayerSelect(){
bool bEndTitleScene = false;
int image = _Create2DImage("script/game/PackageLib/PlaceholderTitleImage_Player.png", [0, 0, 1920, 1080]);
LoadTextureEx(image, true, true);
Obj_SetRenderPriorityI(image, 0);
ObjSprite2D_SetDestRect(image, 0, 0, 1920, 1080);
int imgByakMiko = _Create2DImage("script/game/PackageLib/ByakMiko_Select.png", [0, 0, 1800, 1080]);
LoadTextureEx(imgByakMiko, true, true);
Obj_SetRenderPriorityI(imgByakMiko, 2);
ObjRender_SetPosition(imgByakMiko, GetScreenWidth()/2, 2*GetScreenHeight()/5+120, 0);
ObjRender_SetScaleXYZ(imgByakMiko, 0.84);
int imgRinnoRemi = _Create2DImage("script/game/PackageLib/RinnoRemi_Select.png", [0, 0, 1800, 1080]);
LoadTextureEx(imgRinnoRemi, true, true);
Obj_SetRenderPriorityI(imgRinnoRemi, 2);
ObjRender_SetPosition(imgRinnoRemi, GetScreenWidth()/2, 2*GetScreenHeight()/5+120, 0);
ObjRender_SetScaleXYZ(imgRinnoRemi, 0.84);
Obj_SetVisible(imgByakMiko, false);
Obj_SetVisible(imgRinnoRemi, false);
task TMenuItem(
let index,
float mx, my, size,
string text
)
{
let objText = CreateTextObject(
mx, my, size,
text, "Unispace",
0xFFFFFF, 0xFFFFFF,
0xAA0E2B, size/10,
2
);
let objSelect = CreateTextObject(
mx, my, size,
text, "Unispace",
0xFFFFFF, 0xFFFFFF,
0xAA0E2B, size/10,
2
);
//ObjText_SetMaxWidth(objText, GetScreenWidth());
ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
//ObjText_SetMaxWidth(objSelect, GetScreenWidth);
ObjText_SetHorizontalAlignment(objSelect, ALIGNMENT_CENTER);
ObjRender_SetBlendType(objSelect, BLEND_ADD_RGB);
while(!bEndTitleScene)
{
Obj_SetVisible(objSelect, false);
Obj_SetVisible(objText, false);
yield;
}
Obj_Delete(objText);
Obj_Delete(objSelect);
}
let INDEX_BYAKMIKO = 0;
let INDEX_RINNOREMI = 1;
let selectIndex = 0;//x<><78>bMOn
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0M<30>n
let mx = GetScreenWidth()/3;
let my = 2*GetScreenHeight()/5;
let texts = ["Byakuren Hijiri &[r]Toyosatomimi no Miko", "Rinnosuke Morichika &[r]Remilio Scarlet"];
var countMenu = length(texts);
ascent(var iText in 0 .. countMenu)
{
TMenuItem(iText, mx, my, 35, texts[iText]);
mx *= 2;
}
//<00>0<EFBFBD>0<EFBFBD>rKaL0<4C>0<EFBFBD>0<EFBFBD>0<EFBFBD>0U0<55>0<EFBFBD>0~0g0<67>__j
while(GetVirtualKeyState(VK_OK) != KEY_FREE){yield;}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>Qt
let frameKeyHold = 0;//<00>0<EFBFBD>0<EFBFBD>bW0c0q0j0W0<57>0<EFBFBD>0<EFBFBD>0<EFBFBD>0pe
loop
{
if(GetVirtualKeyState(VK_CANCEL) == KEY_PUSH){
TTitleScene();
break;
}
else if(GetVirtualKeyState(VK_OK) == KEY_PUSH)
{
if(selectIndex == INDEX_BYAKMIKO)
{
pathPlayer = PlayerArray[0];
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
}
else if(selectIndex == INDEX_RINNOREMI)
{
pathPlayer = PlayerArray[1];
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
}
break;
}
if(selectIndex == INDEX_BYAKMIKO)
{
Obj_SetVisible(imgByakMiko, true);
Obj_SetVisible(imgRinnoRemi, false);
}
else if(selectIndex == INDEX_RINNOREMI)
{
Obj_SetVisible(imgRinnoRemi, true);
Obj_SetVisible(imgByakMiko, false);
}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>y<EFBFBD>R
if(GetVirtualKeyState(VK_LEFT) == KEY_PUSH)
{
selectIndex--;
}
else if(GetVirtualKeyState(VK_RIGHT) == KEY_PUSH)
{
selectIndex++;
}
else if(GetVirtualKeyState(VK_LEFT) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex--;
}
}
else if(GetVirtualKeyState(VK_RIGHT) == KEY_HOLD)
{
frameKeyHold++;
if(frameKeyHold == 30 || (frameKeyHold > 30 && (frameKeyHold % 10 == 0)))
{
selectIndex++;
}
}
else
{
frameKeyHold = 0;
}
if(selectIndex < 0)
{
selectIndex = countMenu - 1;
}
else
{
selectIndex %= countMenu;
}
yield;
}
bEndTitleScene = true;
Obj_Delete(image);
Obj_Delete(imgByakMiko);
Obj_Delete(imgRinnoRemi);
}
task TStageScene(let pathReplay, let pathPlayer, let pathLives, let modeDialog, bool isRetry)
{
let dirCurrent = GetCurrentScriptDirectory();
let dirModule = GetModuleDirectory();
if(IsCommonDataAreaExists("PIV") == false){
CreateCommonDataArea("PIV");
SetAreaCommonData("PIV", "currentvalue", 10000);
}
else{
SetAreaCommonData("PIV", "currentvalue", 10000);
}
//--------------------------------
//;ub<75>w<EFBFBD><77>y
RenderSceneToTransitionTexture();
TTransition();
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0RgS
InitializeStageScene();
if(length(pathReplay) > 0)
{
SetStageReplayFile(pathReplay);
}
//--------------------------------
//Rg<>0<EFBFBD>0<EFBFBD>0<EFBFBD>0-<2D><>[
let indexStage = 0; //<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
SetStageIndex(indexStage);
SetStageMainScript("script/game/Boss_Plural.dnh");
SetStagePlayerScript("script/player/Chimata/Chimata_Main.dnh");
SetCommonData("Starting Lives", pathLives);
if(!isRetry){SetCommonData("Dialogue Skip Mode", modeDialog);}
else{}
StartStageScene();
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>d\O
loop
{
//--------------------------------
//NBf\Pbk<62>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
if(GetVirtualKeyState(VK_PAUSE) == KEY_PUSH)
{
let resPause = RunPauseScene();
alternative(resPause)
case(RESULT_RETRY)
{
//gRK0<4B>0<EFBFBD>0<EFBFBD>0<EFBFBD>vY0
if(!IsReplay())
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
TerminateStageScene();
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
return;
}
}
case(RESULT_END)
{
//NBf\Pbk-Nn0B}<7D>N
TerminateStageScene();
}
}
if(!IsReplay() && GetKeyState(KEY_BACK) == KEY_PUSH)
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
TerminateStageScene();
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0), false);
return;
}
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>[<5B>N<EFBFBD>_a0
let stgSceneState = GetStageSceneState();
if(stgSceneState == STAGE_STATE_FINISHED)
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0B}<7D>NP}<7D>g<EFBFBD>0<EFBFBD>S<EFBFBD>_
let stageResult = GetStageSceneResult();
alternative(stageResult)
case(STAGE_RESULT_CLEARED)
{
TEndScene();
break;
}
case(STAGE_RESULT_PLAYER_DOWN)
{
//<00><>_j<5F>k_j0
TEndScene();
break;
}
case(STAGE_RESULT_BREAK_OFF)
{
TTitleScene();
break;
}
}
yield;
}
TTransition();
}
//----------------------------------------------------
// B}<7D>N<EFBFBD>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
task TEndScene()
{
if(IsReplay())
{
TTitleScene();
return;
}
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0B}<7D>N<EFBFBD>Qt
FinalizeStageScene();
//--------------------------------
//B}<7D>N<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0w<30><77>R
let dirModule = GetModuleDirectory();
let pathScript = "script/KevinSystem/kevin_system/Kevin_EndScene.txt";
let idScript = LoadScript(pathScript);
StartScript(idScript);
while(!IsCloseScript(idScript))
{
yield;
}
//--------------------------------
//B}<7D>N<EFBFBD>0<EFBFBD>0<EFBFBD>0P}<7D>g<EFBFBD>Qt
let result = GetScriptResult(idScript);
alternative(result)
case(RESULT_SAVE_REPLAY)
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>OX[
TReplaySaveScene();
}
case(RESULT_END)
{
//<00>QuB}<7D>N
TTitleScene();
}
case(RESULT_RETRY)
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
TStageScene("", "TBA", GetAreaCommonData("Config", "StartingLife", 3), GetAreaCommonData("Config", "DialogueSkip", 0),false);
}
}
//----------------------------------------------------
// NBf\Pbk<62>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
function RunPauseScene()
{
RenderSceneToTransitionTexture();
PauseStageScene(true);
let dirModule = GetModuleDirectory();
let pathScript = "script/KevinSystem/kevin_system/Kevin_Pause.txt";
//--------------------------------
//NBf\Pbk<62>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0w<30><77>R
let idScript = LoadScript(pathScript);
StartScript(idScript);
while(!IsCloseScript(idScript))
{
yield;
}
PauseStageScene(false);
let res = GetScriptResult(idScript);
return res;
}
//----------------------------------------------------
// <00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
task TReplaySelectScene()
{
LoadReplayList();
let dirCurrent = GetCurrentScriptDirectory();
let pathScript = "script/ExRumia/ExRumia_Package_ReplaySelectScene.txt";
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0w<30><77>R
let idScript = LoadScript(pathScript);
StartScript(idScript);
while(!IsCloseScript(idScript))
{
yield;
}
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x<30><78>b<EFBFBD>0<EFBFBD>0<EFBFBD>0P}<7D>g<EFBFBD>Qt
LoadReplayList();
let result = GetScriptResult(idScript);
let resultStage, resultTeam;
if(result == 99999999*69420)
{
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x0;b<>0
TTitleScene();
//ObjSound_Stop(objTitleBGM);
}
else
{
let resultPath = GetReplayInfo(result, REPLAY_FILE_PATH);
if(GetReplayUserData(result, "Difficulty") == "Normal"){SetCommonData("Difficulty", "Normal");}
else if(GetReplayUserData(result, "Difficulty") == "Hard"){SetCommonData("Difficulty", "Hard");}
else if(GetReplayUserData(result, "Difficulty") == "Lunatic"){SetCommonData("Difficulty", "Lunatic");}
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>Qu<><75><EFBFBD>Y
TStageScene(
resultPath,
"TBA",
GetReplayUserData(result, "Starting Lives"),
GetReplayUserData(result, "Dialogue Skip"),
false
);
ObjSound_Stop(objTitleBGM);
}
}
//----------------------------------------------------
// <00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>OX[<5B>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
task TReplaySaveScene()
{
LoadReplayList();
let dirModule = GetModuleDirectory();
let pathScript = dirModule ~ "script/KevinSystem/kevin_system/Kevin_ReplaySave.txt";
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>OX[<5B>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0w<30><77>R
let idScript = LoadScript(pathScript);
StartScript(idScript);
while(!IsCloseScript(idScript))
{
yield;
}
//--------------------------------
//<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0x0w<30><77>y
TTitleScene();
}
//----------------------------------------------------
// ;ub<75>w<EFBFBD><77>y<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0
//----------------------------------------------------
function RenderSceneToTransitionTexture()
{
//<00>s(Wn0<6E>0<EFBFBD>0<EFBFBD>0<EFBFBD>Q<EFBFBD>[<5B>0;ub<75>w<EFBFBD><77>y(u<>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0k0<6B>c;u
let textureName = GetTransitionRenderTargetName();
RenderToTextureA1(textureName, 0, 100, true);
}
task TTransition
{
let textureName = GetTransitionRenderTargetName();
let objImage = ObjPrim_Create(OBJ_SPRITE_2D); //2D<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0ub
Obj_SetRenderPriorityI(objImage, 100); //<00>c;u*QHQ<48>^<5E>0-<2D><>[
ObjPrim_SetTexture(objImage, textureName); //<00>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0<EFBFBD>0-<2D><>[
ObjSprite2D_SetSourceRect(objImage, 0, 0, 1920, 1080);
ObjSprite2D_SetDestRect(objImage, 0, 0, 1920, 1080);
let alpha = 255;
while(alpha > 0)
{
ObjRender_SetAlpha(objImage, alpha);
alpha -= 16;
yield;
}
Obj_Delete(objImage);
}