Full boss battle (with music) implemented.

This commit is contained in:
kevinmonitor 2022-08-22 22:05:46 +07:00
parent 97eb85483c
commit af1977159c
28 changed files with 82 additions and 16 deletions

Binary file not shown.

View File

@ -150,7 +150,7 @@ task TExtendSystem(){
]; ];
if(GetCommonData("Difficulty", "Arcade") == "Arcade"){req = [20, 80, 200, 500, 800, 1200, 2500, 5000];} if(GetCommonData("Difficulty", "Hard") == "Hard"){req = [20, 80, 200, 500, 800, 1200, 2500, 5000];}
else{req = [15, 50, 100, 180, 300, 600, 1000, 2000, 4000];} else{req = [15, 50, 100, 180, 300, 600, 1000, 2000, 4000];}
let next = 0; let next = 0;
@ -237,8 +237,8 @@ function InitFrame()
ObjText_SetHorizontalAlignment(diffText, ALIGNMENT_CENTER); ObjText_SetHorizontalAlignment(diffText, ALIGNMENT_CENTER);
/* /*
if(GetCommonData("Difficulty", "Arcade") == "Arcade"){ if(GetCommonData("Difficulty", "Hard") == "Hard"){
ObjText_SetText(diffText, "Arcade Mode"); ObjText_SetText(diffText, "Hard Mode");
ObjText_SetFontColorTop(diffText, 0x8100CE); ObjText_SetFontColorTop(diffText, 0x8100CE);
ObjText_SetFontColorBottom(diffText,0xAC7DFF); ObjText_SetFontColorBottom(diffText,0xAC7DFF);
ObjText_SetFontBorderType(diffText, BORDER_FULL); ObjText_SetFontBorderType(diffText, BORDER_FULL);
@ -246,7 +246,7 @@ function InitFrame()
} }
else{ else{
ObjText_SetText(diffText, "Gentle Mode"); ObjText_SetText(diffText, "Normal Mode");
ObjText_SetFontColorTop(diffText, 0xFF993F); ObjText_SetFontColorTop(diffText, 0xFF993F);
ObjText_SetFontColorBottom(diffText,0xFFCFA6); ObjText_SetFontColorBottom(diffText,0xFFCFA6);
ObjText_SetFontBorderType(diffText, BORDER_FULL); ObjText_SetFontBorderType(diffText, BORDER_FULL);
@ -714,7 +714,7 @@ task TBossTimer
if(ObjEnemyBossScene_GetInfo(objScene, INFO_TIMERF) % 60 == 0){_Timeout();} if(ObjEnemyBossScene_GetInfo(objScene, INFO_TIMERF) % 60 == 0){_Timeout();}
ObjText_SetFontBorderColor(textTimer, 0xF0396C); ObjText_SetFontBorderColor(textTimer, 0xF0396C);
} }
else{} else{ObjText_SetFontBorderColor(textTimer, 0xA639F0); ObjText_SetFontSize(textTimer, 35);}
if(ObjMove_GetY(GetPlayerObjectID()) < GetStgFrameHeight()/6){ if(ObjMove_GetY(GetPlayerObjectID()) < GetStgFrameHeight()/6){
ObjRender_SetAlpha(textTimer, 60); ObjRender_SetAlpha(textTimer, 60);
} }

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 213 KiB

After

Width:  |  Height:  |  Size: 317 KiB

View File

@ -96,7 +96,7 @@ task TReplayIndexSelection()
/*SetReplayUserData("Starting Lives", GetCommonData("Starting Lives Selected", 5)); /*SetReplayUserData("Starting Lives", GetCommonData("Starting Lives Selected", 5));
SetReplayUserData("Player Team", GetReplayInfo(index, REPLAY_PLAYER_NAME)); SetReplayUserData("Player Team", GetReplayInfo(index, REPLAY_PLAYER_NAME));
SetReplayUserData("Difficulty", GetCommonData("Difficulty", "Arcade"));*/ SetReplayUserData("Difficulty", GetCommonData("Difficulty", "Hard"));*/
} }
else else
@ -326,7 +326,7 @@ task TNameEntry(let replayIndex)
{ {
SetReplayUserData("Starting Lives", GetCommonData("Starting Lives Selected", 5)); SetReplayUserData("Starting Lives", GetCommonData("Starting Lives Selected", 5));
SetReplayUserData("Player Team", GetCommonData("Player Team", "ByakMiko")); SetReplayUserData("Player Team", GetCommonData("Player Team", "ByakMiko"));
SetReplayUserData("Difficulty", GetCommonData("Difficulty", "Arcade")); SetReplayUserData("Difficulty", GetCommonData("Difficulty", "Hard"));
SetReplayUserData("Dialogue Skip", GetCommonData("Dialogue Skip Mode", 0)); SetReplayUserData("Dialogue Skip", GetCommonData("Dialogue Skip Mode", 0));
SaveReplay(replayIndex, userName); SaveReplay(replayIndex, userName);
SetScriptResult(RESULT_END); SetScriptResult(RESULT_END);

View File

@ -8,12 +8,26 @@
let csd = GetCurrentScriptDirectory(); let csd = GetCurrentScriptDirectory();
let obj = ObjEnemyBossScene_Create(); let obj = ObjEnemyBossScene_Create();
int objBGM = ObjSound_Create();
#include "script/KevinSystem/Universal_Lib.txt" #include "script/KevinSystem/Universal_Lib.txt"
#include "script/game/Stage_Background.dnh" #include "script/game/Stage_Background.dnh"
bool bossTrueStart = false;
float BGMRate = GetAreaCommonData("Config", "BGMVol", 100) * 0.01;
@Event{ @Event{
alternative (GetEventType())
case(EV_PAUSE_ENTER){
if (bossTrueStart) {ObjSound_Stop(objBGM);}
}
case(EV_PAUSE_LEAVE){
if (bossTrueStart) {ObjSound_Play(objBGM);}
}
} }
@Initialize{ @Initialize{
@ -25,7 +39,15 @@ let obj = ObjEnemyBossScene_Create();
else{} else{}
SetAutoDeleteObject(true); SetAutoDeleteObject(true);
_ScrollBackground();
ObjSound_Load(objBGM, "script/game/resourceLib/bossTheme.ogg");
ObjSound_SetSoundDivision(objBGM, SOUND_BGM);
ObjSound_SetResumeEnable(objBGM, true);
ObjSound_SetLoopEnable(objBGM, true);
ObjSound_SetLoopTime(objBGM, 0.00, 89.618);
ObjSound_SetVolumeRate(objBGM, 99*BGMRate);
PluralTask(); PluralTask();
} }
@ -55,14 +77,22 @@ task PluralTask(){
ObjEnemyBossScene_Add(obj, 0, csd ~ "Non3.dnh"); ObjEnemyBossScene_Add(obj, 0, csd ~ "Non3.dnh");
ObjEnemyBossScene_Add(obj, 0, csd ~ "Spell3.dnh"); ObjEnemyBossScene_Add(obj, 0, csd ~ "Spell3.dnh");
_ScrollBackground();
// Loading and registering the boss scene // Loading and registering the boss scene
ObjEnemyBossScene_LoadInThread(obj); ObjEnemyBossScene_LoadInThread(obj);
ObjEnemyBossScene_Regist(obj); ObjEnemyBossScene_Regist(obj);
bossTrueStart = true;
ObjSound_Play(objBGM);
while(!Obj_IsDeleted(obj)){ while(!Obj_IsDeleted(obj)){
yield; yield;
} }
ObjSound_Stop(objBGM);
bossTrueStart = false;
_ExplosionEffect(GetCommonData("Boss Position X", STG_WIDTH/2), GetCommonData("Boss Position Y", STG_WIDTH/2), PetalEffect); _ExplosionEffect(GetCommonData("Boss Position X", STG_WIDTH/2), GetCommonData("Boss Position Y", STG_WIDTH/2), PetalEffect);
SetAutoDeleteObject(true); SetAutoDeleteObject(true);
wait(120); wait(120);

View File

@ -69,7 +69,7 @@ int[] speedSpiral = [6, 8, 8];
bossObj = ObjEnemy_Create(OBJ_ENEMY_BOSS); bossObj = ObjEnemy_Create(OBJ_ENEMY_BOSS);
ObjEnemy_Regist(bossObj); ObjEnemy_Regist(bossObj);
ObjMove_SetPosition(bossObj, GetCommonData("Boss Position X", STG_WIDTH/2), GetCommonData("Boss Position Y", STG_HEIGHT/2)); ObjMove_SetPosition(bossObj, STG_WIDTH/2, -256);
ObjEnemy_SetMaximumDamage(bossObj, 999); ObjEnemy_SetMaximumDamage(bossObj, 999);
_RenderBoss(bossObj); _RenderBoss(bossObj);

Binary file not shown.

After

Width:  |  Height:  |  Size: 511 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 936 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 606 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 232 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

View File

@ -1,11 +1,15 @@
let bossBG = "script/game/resourceLib/BGFight.png"; let bossBG = "script/game/resourceLib/BGFight.png";
let sound = ObjSound_Create(); let sound = ObjSound_Create();
let soundWarn = ObjSound_Create();
let alphaMax = 255*((GetAreaCommonData("Config", "BGOpacity", 100))/100); let alphaMax = 255*((GetAreaCommonData("Config", "BGOpacity", 100))/100);
let blipVol = GetAreaCommonData("Config", "SEVol", 100) * 0.01; let blipVol = GetAreaCommonData("Config", "SEVol", 100) * 0.01;
ObjSound_Load(sound, "script/game/resourceLib/dialogueblip.wav"); ObjSound_Load(sound, "script/game/resourceLib/dialogueblip.wav");
ObjSound_Load(soundWarn, "script/game/resourceLib/warnSound.wav");
ObjSound_SetVolumeRate(sound, 100 * blipVol); ObjSound_SetVolumeRate(sound, 100 * blipVol);
ObjSound_SetVolumeRate(soundWarn, 100 * blipVol);
ObjSound_SetSoundDivision(sound, SOUND_SE); ObjSound_SetSoundDivision(sound, SOUND_SE);
ObjSound_SetSoundDivision(soundWarn, SOUND_SE);
//LoadSound("script/game/StageLib/dialogueblip.wav"); //LoadSound("script/game/StageLib/dialogueblip.wav");
@ -17,8 +21,8 @@ function <void> _ScrollBackground(){
ObjRender_SetPosition(BossImg, STG_WIDTH/2, STG_HEIGHT/2-150, 0); ObjRender_SetPosition(BossImg, STG_WIDTH/2, STG_HEIGHT/2-150, 0);
Obj_SetRenderPriorityI(BossImg, 24); Obj_SetRenderPriorityI(BossImg, 24);
ascent(i in 0..30){ ascent(i in 0..90){
ObjRender_SetAlpha(BossImg, Interpolate_Decelerate(0, alphaMax, i/30)); ObjRender_SetAlpha(BossImg, Interpolate_Decelerate(0, alphaMax, i/90));
yield; yield;
} }
@ -29,20 +33,52 @@ function <void> _ScrollBackground(){
function <void> Dialogue(){ function <void> Dialogue(){
ObjSound_Play(soundWarn);
wait(30);
int objText3 = CreateTextObject(
STG_WIDTH/2, STG_HEIGHT/3-60, 90,
" ", "Origami Mommy",
0xFF0031, 0xFF0031,
0x000000, 10,
71
);
int objText = CreateTextObject( int objText = CreateTextObject(
STG_WIDTH/2, 2*STG_HEIGHT/5+125, 45, STG_WIDTH/2, STG_HEIGHT/2-60, 45,
" ", "Origami Mommy", " ", "Origami Mommy",
0x9F9FFF, 0xDCD6FF, 0xAA0020, 0xF18FA2,
0x000000, 3, 0x390E2E, 6,
71
);
int objText2 = CreateTextObject(
STG_WIDTH/2, STG_HEIGHT/2+60, 45,
" ", "Origami Mommy",
0xAA0020, 0xF18FA2,
0x390E2E, 6,
71 71
); );
ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER); ObjText_SetHorizontalAlignment(objText, ALIGNMENT_CENTER);
TTextScroll(objText, "AN AWESOME VAMPIRE/IS CONFLICT WITH US//KEEP YOUR SEXINESS"); ObjText_SetHorizontalAlignment(objText2, ALIGNMENT_CENTER);
ObjText_SetHorizontalAlignment(objText3, ALIGNMENT_CENTER);
TTextScroll(objText3, "WARNING");
TTextScroll(objText, "AN AWESOME VAMPIRE/IS CONFLICT WITH US");
//wait(60);
TTextScroll(objText2, "KEEP YOUR SEXINESS");
Obj_Delete(objText); Obj_Delete(objText);
Obj_Delete(objText2);
Obj_Delete(objText3);
} }
@ -82,6 +118,6 @@ function <void> TTextScroll(int obj_, string text_) { //Makes text fill graduall
} }
dialogEnd = true; dialogEnd = true;
wait(90); wait(30);
} }

BIN
script/game/config.dat Normal file

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 464 KiB

After

Width:  |  Height:  |  Size: 586 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.