Jump to content

Photo

Final Boss


  • Please log in to reply
5 replies to this topic

#1 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 27 September 2017 - 03:04 PM

Sup everyone. i wanted to ask you a script for the final boss of the game with special death animation.

 

AbsorbDarkness ffc

 

The first thing the final boss will do is to absorb alot darkness in the room (even if there's no darkness) and then use his Darkness Power to create a flash with a white screen for a moment and the flash will disappears show the player the final form of the Final boss. (I planning to use 4 phase for the Final boss so only the final one will make a special death animation.)

 

MayathDemon ffc

 

Once the final fight begins Link must find a way to vanish the Darkness so Link must use the Light Arrow before attack the final boss with the sword. (He cannot attack the demon when his body is protected by the Darkness or else he'll take serious damages.

 

His attacks order will not be determined because he'll use random attacks. Here's attack order to Argument 1 to Argument 5.

 

Geant Laser: the boss will start to teleport everywhere for some minutes and after a few seconds of his apparitions he'll shoot 1 to 5 lasers and he'll go at the middle of the room to stop the attack.

 

Darkness: He'll shoot sometimes some Darkness (3 in total) and they'll start to chase Link until they disappears or until they touch and take some damages to Link until 10 secs. The Darkness could stay immobile to make some confusions and serve as obstacles. 

 

Fire ball: (Breath) He'll occasionaly shot Link with many fire ball the boss will breath. More the boss take damages more the attack will become faster and dangerous. 

 

Explosion: The boss will become red and he'll charge his attack to create an explosion to hit Link to take him a serious damage. A dangerous attack that Link must avoid before the boss finish to charge his attack.

 

Sword of Darkness: If the boss is in the half of his life he'll start to use more his sword to slash Link. He can throw his sword to hit Link. If the sword hit a No Flying Enemy Combo type then the sword will stucks on the wall and then the boss will run to get his sword back. If Link is on his way he'll take 10 hearts damages. 

 

Argument 6: Before his death animation a string will be playing before he die. His Death Animation could be the explosion like another boss but except there will be a earthquake with falling rocks and bulders and then the boss will create a geant explosion making the full room in the explosion light and then active a Autowarp A. 

 

Here's the script with Moosh's helps so the script could be compatible with the boss script.

const int LW_LIGHTARROW = 39; //Light arrow weapon type
const int SPR_LIGHTARROW = 102; //Light arrow sprite

const int SFX_LIGHTARROW = 1; //Sound when a light arrow is fired
const int SFX_LIGHTARROWIMPACT = 32; //Sound when a light arrow hits

const int C_LIGHTARROWRING = 0x11; //Color of light arrow explosion

item script LightArrowItem{
	void run(int msg, int mpcost, int damage){
		int str[] = "LightArrowFFC";
		int ffcs = Game->GetFFCScript(str);
		if(CountFFCsRunning(ffcs)==0){
			int args[8] = {mpcost, damage};
			RunFFCScript(ffcs, args);
		}
	}
}

ffc script LightArrowFFC{
	void run(int mpcost, int damage){
		int mpAdjust = mpcost*(Game->Generic[GEN_MAGICDRAINRATE]/2);
		if(Link->MP>=mpAdjust){
			Game->PlaySound(SFX_LIGHTARROW);
			Link->MP -= mpAdjust;
			lweapon lightArrow = CreateLWeaponAt(LW_LIGHTARROW, Link->X+InFrontX(Link->Dir, 0), Link->Y+InFrontY(Link->Dir, 0));
			lightArrow->UseSprite(SPR_LIGHTARROW);
			lightArrow->Dir = Link->Dir;
			if(lightArrow->Dir>DIR_DOWN)
				lightArrow->Tile++;
			if(lightArrow->Dir==DIR_DOWN)
				lightArrow->Flip = 2;
			else if(lightArrow->Dir==DIR_LEFT)
				lightArrow->Flip = 1;
			lightArrow->Step = 400;
			lightArrow->Damage = damage;
			int trailCounter;
			int impactX = lightArrow->X+8;
			int impactY = lightArrow->Y+8;
			int angle;
			if(Link->Dir==DIR_UP)
				angle = -90;
			else if(Link->Dir==DIR_LEFT)
				angle = 180;
			else if(Link->Dir==DIR_DOWN)
				angle = 90;
			angle += Rand(-30, 30);
			while(lightArrow->isValid()){
				trailCounter = (trailCounter+1)%360;
				if(trailCounter%4==0){
					lweapon trail = CreateLWeaponAt(LW_SCRIPT10, lightArrow->X, lightArrow->Y);
					trail->OriginalTile = lightArrow->OriginalTile;
					trail->Tile = lightArrow->Tile;
					trail->Flip = lightArrow->Flip;
					trail->CSet = lightArrow->CSet;
					trail->DeadState = 16;
					trail->DrawStyle = DS_PHANTOM;
				}
				impactX = lightArrow->X+8;
				impactY = lightArrow->Y+8;
				if(Screen->isSolid(lightArrow->X+8, lightArrow->Y+8))
					lightArrow->DeadState = 0;
				Waitframe();
			}
			Game->PlaySound(SFX_LIGHTARROWIMPACT);
			for(int i=0; i<10; i++){
				Screen->Circle(4, impactX, impactY, 20-i*2, C_LIGHTARROWRING, 1, 0, 0, 0, true, 128); 
				Waitframe();
			}
			int scaleA = Rand(30, 50)/10;
			int scaleB = Rand(30, 100)/100;
			for(int i=0; i<20; i++){
				int op = 128;
				if(i>16)
					op = 64;
				for(int j=0; j<3; j++){
					Screen->Ellipse(4, impactX, impactY, i*scaleB+j*2, i*scaleA+j*2, C_LIGHTARROWRING, 1, impactX, impactY, angle, false, op);
				}
				Waitframe();
			}
		}
	}
}

const int LIGHTARROWDARKNESS_FREQ = 20; //How many frames between Link taking damage in darkness
const int LIGHTARROWDARKNESS_DAMAGE = 32; //How much damage Link takes
const int C_LIGHTARROWDARKNESS = 0x08; //Color of darkness

ffc script LightArrowDarknessCombo{
	void run(int flag){
		bool darknessTile[176];
		int darknessLevel[176];
		for(int i=0; i<176; i++){
			if(ComboFI(i, flag)){
				darknessTile[i] = true;
				darknessLevel[i] = 12;
			}
		}
		int darknessCounter = LIGHTARROWDARKNESS_FREQ;
		while(true){
			bool inDarkness;
			if(darknessTile[ComboAt(Link->X+8, Link->Y+8)]){
				inDarkness = true;
			}
			for(int i=Screen->NumLWeapons(); i>=1; i--){
				lweapon l = Screen->LoadLWeapon(i);
				if(l->ID==LW_LIGHTARROW){
					for(int x=0; x<=15; x=Min(x+8, 15)){
						for(int y=0; y<=15; y=Min(y+8, 15)){
							if(darknessTile[ComboAt(l->X+x, l->Y+y)])
								darknessTile[ComboAt(l->X+x, l->Y+y)] = false;
							if(y==15)
								break;
						}
						if(x==15)
							break;
					}
				}
			}
			for(int i=0; i<176; i++){
				if(darknessLevel[i]>0){
					if(!darknessTile[i])
						darknessLevel[i]-=0.25;
					int j = 8;
					for(int k=0; k<3; k++){
						Screen->Circle(4, ComboX(i)+8+Rand(-j, j), ComboY(i)+8+Rand(-j, j), darknessLevel[i]+Rand(-4, 4), C_LIGHTARROWDARKNESS, 1, 0, 0, 0, true, 64);
					}
				}
			}
			if(inDarkness){
				darknessCounter--;
				if(darknessCounter<=0){
					darknessCounter = LIGHTARROWDARKNESS_FREQ;
					Link->HP -= LIGHTARROWDARKNESS_DAMAGE;
					Link->HitDir = -1;
					Game->PlaySound(SFX_OUCH);
					Link->Action = LA_GOTHURTLAND;
				}
			}
			else
				darknessCounter = LIGHTARROWDARKNESS_FREQ;
			Waitframe();
		}
	}
} 

A exemple quest could help me.


Edited by Sans, 27 September 2017 - 03:06 PM.


#2 PixElvis

PixElvis

    Creative?

  • Members
  • Real Name:Elvis
  • Pronouns:He / Him
  • Location:Dominican Republic

Posted 28 September 2017 - 07:38 PM

Wow,is very long,I sure this will awesome playing,when you post the Quest or Demo.

I want to play your Demo,When  post your game? :)



#3 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 28 September 2017 - 07:44 PM

i already did post the demo of the quest 


  • PixElvis likes this

#4 PixElvis

PixElvis

    Creative?

  • Members
  • Real Name:Elvis
  • Pronouns:He / Him
  • Location:Dominican Republic

Posted 28 September 2017 - 07:58 PM

The New Demo you posted?  :wow:


Edited by >ELV002<, 28 September 2017 - 08:01 PM.


#5 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 28 September 2017 - 08:01 PM

Yep


  • PixElvis likes this

#6 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 30 September 2017 - 08:53 PM

But anyway i'll use the boss script for the final boss so i'll wait the boss script to test correctly the final boss see if he'll work perfectly like the demo quest.
(I hope i'll finish the quest soon.)


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users