Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- script_enemy_main {
- #include_function ".\include.dnh"
- task TMain {
- SetLife(630); CreateLifebar(3, 1); dmgratemax=15; dmgrateup=1;
- SetMovePosition03(GetCenterX, GetCenterY-100, 15, 9); waitInv(60);
- cutin("Deathbringer "\""Infinite Being"\", cut, 0, 0, 512, 512);
- SetScore(1000000); wait(1); SetTimer(150);
- SetMovePosition03(GetCenterX, GetCenterY-75, 10, 9);
- Override(true, true, 30, 15, 7.5, 0);
- waitInv(120);
- attack_;
- attack0;
- attack1;
- attack2;
- attack3;
- attack4;
- }
- let phase = 0;
- task attack_ {
- SetCommonData("passedLast", -1);
- loop {
- let r = rand(-5,5);
- let n = [37, 37, 43, 43, 47, 57, 71][phase];
- let v = [3, 13/4, 7/2, 7/2, 7/2, 3, 5/2][phase];
- ascent(i in -n..n+1) { CreateShot02(GetX, GetY, 7, -90+i*v+r, -1/10, 2, 227, 0); }
- loop (20) {
- phase = 0;
- if((GetEnemyLife<630*9/10) || (GetTimer < 130)) { phase = 1; }
- if((GetEnemyLife<630*7/10) || (GetTimer < 110)) { phase = 2; }
- if((GetEnemyLife<630*5/10) || (GetTimer < 90)) { phase = 3; }
- if((GetEnemyLife<630*3/10) || (GetTimer < 70)) { phase = 4; }
- if((GetEnemyLife<630*2/10) || (GetTimer < 50)) { phase = 5; }
- if((GetTimer < 30)) { phase = 6; }
- if(GetEnemyLife<10&&GetEnemyLife>0){
- SetCommonData("passedLast", 1*(GetSpellCardBonusScore>0));
- AddLife(-GetLife);
- } wait(1);
- }
- }
- }
- task attack0 {
- let a = GetAngleToPlayer;
- loop {
- if(phase>=0) {
- ascent(i in 0..27) { CreateShot01(GetX, GetY, 3, a+i*360/27, 166, 10); }
- }
- a+=7; a%=360;
- wait(20);
- }
- }
- task attack1 {
- loop {
- let a = GetAngleToPlayer;
- loop(5) {
- if(phase>=1) {
- ascent(i in -2..3) { CreateShot01(GetX, GetY, 4, a+i*11, 218, 10); }
- }
- wait(5);
- }
- wait(45);
- }
- }
- task attack2 {
- let a = 90;
- loop {
- if(phase>=2) {
- ascent(i in 0..7) { CreateShot01(GetX, GetY, 2, a+i*360/7, 212, 10); }
- }
- wait(15);
- a+=pi*9/2;a%=360;
- }
- }
- task attack3 {
- let a_ = GetAngleToPlayer;
- let a = 0;
- loop {
- if(phase>=3) {
- CreateShot01(GetX, GetY, 3, a_+87*sin(a), 235, 15);
- }
- wait(5);
- a-=pi*7/2;a%=360;
- }
- }
- task attack4 {
- loop {
- if(phase>=4) { ascent(j in -1..2) { ascent(i in 0..2) {
- CreateShot01(GetX, GetY, pi-(|j|), GetAngleToPlayer+23*(i*2-1)+j*10, 254, 15);
- } } }
- wait(13);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment