From b61ca302cc935326e9adabd22a7cb35684ced666 Mon Sep 17 00:00:00 2001 From: "chirs241097@gmail.com" Date: Tue, 25 Feb 2014 23:59:51 +0000 Subject: M trunk/CHANGELOG.TXT M trunk/levels.h --- levels.h | 696 +-------------------------------------------------------------- 1 file changed, 3 insertions(+), 693 deletions(-) (limited to 'levels.h') diff --git a/levels.h b/levels.h index 9eb219d..5d73cc1 100644 --- a/levels.h +++ b/levels.h @@ -3017,465 +3017,8 @@ void Level7Part20() } } //vvvvvvvvvvvvvvvvvvvvvv Old Levels vvvvvvvvvvvvvvvvvvvvvv// -/*void Level1Part2()//Simple tower8-discard -{ - frameleft=TwentySeconds;clrtime=5; - if (towcnt!=2&&towcnt!=0) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("Dev-version!!!"); - return; - } - ++frameskips; - if (frameskips<10&&!LOWFPS)return; - frameskips=0; - DBGColor=ColTrans(DBGColor,0xFFC0C030,3); - CreateTower8(400,300,1000,3,30,30,true); - CreateTower2(999,999,9999,0); - //Remember to hide BTarg after this level. - for (int i=1;i<=towcnt;++i) - if (tower[i].towerspr->GetColor()==0x80FFFFFF) - tower[i].towerspr->SetColor(0x00FFFFFF); - for (int i=1;i<=towcnt;++i) - if ((tower[i].towerspr->GetColor()>>24)<=0x80) - tower[i].towerspr->SetColor(tower[i].towerspr->GetColor()+0x01FFFFFF); - else - { - IfCallLevel=false; - ATarg.TargShow(); - LE_Active=true; - //Sky.Init(0xC0);Sky.SetFadein(); - return; - } -} -void Level1Part3()//Simple tower9-discard -{ - frameleft=TwentySeconds;clrtime=0; - if (towcnt!=1&&towcnt!=0) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("Dev-version!!!"); - return; - } - ++frameskips; - if (frameskips<10&&!LOWFPS)return; - frameskips=0; - CreateTower9(400,300,3000,2,2000,48,1000); - for (int i=1;i<=towcnt;++i) - if (tower[i].towerspr->GetColor()==0x80FFFFFF) - tower[i].towerspr->SetColor(0x00FFFFFF); - for (int i=1;i<=towcnt;++i) - if ((tower[i].towerspr->GetColor()>>24)<=0x80) - tower[i].towerspr->SetColor(tower[i].towerspr->GetColor()+0x01FFFFFF); - else - { - IfCallLevel=false; - BTarg.TargHide(); - Leaves.Init(0xF0);Leaves.Update();Leaves.SetFadeIn(); - return; - } -} -void Level1Part4()//Crowded board-used -{ - //Todo: Change the green tower to the orange one in Extreme mode - frameleft=AMinute;clrtime=1; - if (towcnt==1) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("A crowded board?"); - } - if (Current_Position==1) - { - ++part; - LE_Active=false;Leaves.SetFadeOut(); - ATarg.TargHide(); - pnt1=CreateTower3(10,10,50,20,1); - pnt2=CreateTower3(790,10,50,20,1); - CreateTower1(400,10,400,2); - } -} -void Level1Part5()//Crowded board-child -{ - if (!LOWFPS) - tower[pnt1].towerpos.x+=0.006,tower[pnt2].towerpos.x-=0.006; - else - tower[pnt1].towerpos.x+=0.006*17,tower[pnt2].towerpos.x-=0.006*17; - if (frameleft<=TwentySeconds) - { - CreateTower1(400.1,10,400,2,pi/36); - CreateTower1(399.9,10,400,2,-pi/36); - } -} -void Level1Part6()//Squash-used -{ - frameleft=AMinute;clrtime=1; - if (towcnt==5) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("Get out before you are squashed..."); - } - if (Current_Position==1) - { - ++part;squashrev=false; - ATarg.TargHide(); - CreateTower3(10,10,400,2,1); - CreateTower3(766,10,400,2,1); - CreateTower3(10,566,400,2,1); - CreateTower3(766,566,400,2,1); - CreateTower1(9,9,1000,1.5); - CreateTower1(767,11,1000,1.5); - CreateTower1(9,567,1000,1.5); - CreateTower1(767,567,1000,1.5); - } -} -void Level1Part7()//Squash-child -{ - if (!squashrev) - { - if (!LOWFPS) - { - tower[1].towerpos.x+=0.01; - tower[1].towerpos.y+=0.007354; - tower[2].towerpos.x-=0.01; - tower[2].towerpos.y+=0.007354; - tower[3].towerpos.x+=0.01; - tower[3].towerpos.y-=0.007354; - tower[4].towerpos.x-=0.01; - tower[4].towerpos.y-=0.007354; - } - else - { - tower[1].towerpos.x+=0.1; - tower[1].towerpos.y+=0.07354; - tower[2].towerpos.x-=0.1; - tower[2].towerpos.y+=0.07354; - tower[3].towerpos.x+=0.1; - tower[3].towerpos.y-=0.07354; - tower[4].towerpos.x-=0.1; - tower[4].towerpos.y-=0.07354; - } - } - else - { - if (!LOWFPS) - { - tower[1].towerpos.x-=0.01; - tower[1].towerpos.y-=0.007354; - tower[2].towerpos.x+=0.01; - tower[2].towerpos.y-=0.007354; - tower[3].towerpos.x-=0.01; - tower[3].towerpos.y+=0.007354; - tower[4].towerpos.x+=0.01; - tower[4].towerpos.y+=0.007354; - } - else - { - tower[1].towerpos.x-=0.1; - tower[1].towerpos.y-=0.07354; - tower[2].towerpos.x+=0.1; - tower[2].towerpos.y-=0.07354; - tower[3].towerpos.x-=0.1; - tower[3].towerpos.y+=0.07354; - tower[4].towerpos.x+=0.1; - tower[4].towerpos.y+=0.07354; - } - } - if (tower[1].towerpos.x>766||tower[1].towerpos.x<10)squashrev=!squashrev; -} -void Level1Part8()//?_trash-abused..--ignore before 13 -{ - frameleft=TenSeconds;clrtime=0; - if (towcnt==8) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("Dev-version!"); - } - if (Current_Position==1) - { - ++part; - ATarg.TargShow(); - posx=10,posy=10,doneredir=false; - } -} -void Level1Part9() -{ - if (!LOWFPS)++fskp;else fskp+=17; - if (fskp>30) - { - fskp=0; - if (posx<766) - { - posx+=12; - CreateBullet9(posx,posy,0,999999,1,999999); - } - else - { - if (posy<566) - { - posy+=12; - CreateBullet9(posx,posy,0,999999,1,999999); - } - else - if (!doneredir) - for (int i=1;i<=bulcnt;++i) - bullet[i].redir(ATarg.targpos),bullet[i].bulletspeed=4,doneredir=true; - } - } -} -void Level1Part10() -{ - frameleft=TenSeconds;clrtime=0; - DisableAllTower=false; - if (Current_Position==1) - { - ++part; - posx2=766,posy2=566,doneredir=false; - } -} -void Level1Part11() -{ - if (!LOWFPS)++fskp;else fskp+=17; - if (fskp>30) - { - fskp=0; - if (posx2>10) - { - posx2-=12; - CreateBullet9(posx2,posy2,0,999999,1,999999); - } - else - { - if (posy2>10) - { - posy2-=12; - CreateBullet9(posx2,posy2,0,999999,1,999999); - } - else - if (!doneredir) - for (int i=1;i<=bulcnt;++i) - bullet[i].redir(ATarg.targpos),bullet[i].bulletspeed=4,doneredir=true; - } - } -} -void Level1Part12() -{ - frameleft=TenSeconds;clrtime=0; - DisableAllTower=false; - if (Current_Position==1) - { - ++part; - posx=10,posy=10,posx2=766,posy2=566,doneredir=false; - } -} -void Level1Part13() -{ - if (!LOWFPS)++fskp;else fskp+=17; - if (fskp>60) - { - fskp=0; - if (posx2>10) - { - posx2-=24; - CreateBullet9(posx2,posy2,0,999999,1,999999); - } - else - { - if (posy2>10) - { - posy2-=24; - CreateBullet9(posx2,posy2,0,999999,1,999999); - } - else - if (!doneredir) - for (int i=1;i<=bulcnt;++i) - bullet[i].redir(ATarg.targpos),bullet[i].bulletspeed=2,doneredir=true; - } - if (posx<766) - { - posx+=24; - CreateBullet9(posx,posy,0,999999,1,999999); - } - else - { - if (posy<566) - { - posy+=24; - CreateBullet9(posx,posy,0,999999,1,999999); - } - } - - } -} -//let's start again.. -void Level1Part14()//?-discard -{ - frameleft=TwentySeconds;clrtime=0; - if (towcnt!=3&&bulcnt!=0) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("whassat..?"); - return; - } - ++frameskips; - if (frameskips<10&&!LOWFPS)return; - frameskips=0; - CreateTower1(400,300,200,4,0,false); - CreateTower1(399.9,300,200,4,-pi/36,false); - CreateTower1(400.1,300,200,4,pi/36,false); - for (int i=1;i<=towcnt;++i) - if (tower[i].towerspr->GetColor()==0x80FFFFFF) - tower[i].towerspr->SetColor(0x00FFFFFF); - for (int i=1;i<=towcnt;++i) - if ((tower[i].towerspr->GetColor()>>24)<=0x80) - tower[i].towerspr->SetColor(tower[i].towerspr->GetColor()+0x01FFFFFF); - else - { - IfCallLevel=false; - BTarg.TargHide(); - return; - } -} -void Level1Part15()//Rainbowtower-used -{ - frameleft=(AMinute+ThirtySeconds);clrtime=5; - if (bulcnt!=0&&towcnt!=1) - { - ClearAll(); - return; - } - DisableAllTower=false; - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("Rainbow tower..."); - return; - } - ++frameskips; - if (frameskips<10&&!LOWFPS)return; - frameskips=0; - towcnt=0; - deltadelta=pi/720; - CreateTower6(400,300,600,2,1000,3,72); - ++part; -} -void Level1Part16()//Rainbowtower-child -{ - ++frameskips; - if (tower[1].towertype==6) - { - if (frameskips>TenSeconds/5) - { - frameskips=0; - towcnt=0; - CreateTower9(400,300,600,2,1500,72,1200);//Orange - } - } - if (tower[1].towertype==9) - { - if (frameskips>TenSeconds/5) - { - frameskips=0; - towcnt=0; - CreateTower4(400,300,500,1,500);//Yellow - } - } - if (tower[1].towertype==4) - { - if (frameskips>TenSeconds/5) - { - frameskips=0; - towcnt=0; - CreateTower1(400,300,50,4);//Green - } - } - if (tower[1].towertype==1) - { - if (frameskips>TenSeconds/5) - { - frameskips=0; - towcnt=0; - CreateTower2(400,300,50,4);//Cyan - } - } - if (tower[1].towertype==2) - { - if (frameskips>TenSeconds/2) - { - frameskips=0; - towcnt=0; - CreateTower8(400,300,500,5,20,50);//Blue - } - } - if (tower[1].towertype==8) - { - if (frameskips>TenSeconds/5) - { - frameskips=0; - towcnt=0; - CreateTower5(400,300,50,5);//Purple - } - } - if (tower[1].towertype==5) - { - if (frameskips>TenSeconds/5) - { - frameskips=0; - towcnt=0; - CreateTower6(400,300,600,2,1000,3,72);//Red - } - } -} -void Level1Part17()//33*b+1*r-discard +/* +void Level1Part17()//33*b+1*r-discard? { frameleft=AMinute;clrtime=0; if (bulcnt!=0&&towcnt!=34) @@ -3540,76 +3083,6 @@ void Level1Part18()//Child of last level tower[1].towertimer=200; } } -int brk,pos; -bool rev; -void Level1Part19()//laser vertex-used -{ - frameleft=ThirtySeconds; - if (towcnt!=0)return (void)ClearAll(); - Lasercnt=12; - for (int i=1;i<=12;++i) - { - laser[i].Init(32); - laser[i].SetTexture(SprSheet,0,264,248,8); - laser[i].RenCtr.x=406,laser[i].RenCtr.y=306; - } - ++part; -} -void Level1Part20()//laser vertex-child -{ - bool shot=false; - if (++brk>=100)brk=0,shot=true,++pos; - if (pos==32) - { - pos=0;rev=!rev; - for (int i=1;i<=bulcnt;++i) - if (bullet[i].bulletspeed<1e-5) - bullet[i].bulletaccel=0.001, - bullet[i].limv=2.5; - } - for (int i=1;i<=12;++i) - { - double initrad=pi/6.0f*(i-1); - double dist; - for (int j=0;j<32;++j) - { - dist=j*Resd; - double trad; - if (rev)trad=initrad-j*pi/36.0f;else trad=initrad+j*pi/36.0f; - vector2d t,tt,s; - t.x=cos(trad)*dist; - t.y=sin(trad)*dist; - dist=(j+1)*Resd; - if (rev)trad=initrad-(j+1)*pi/36.0f;else trad=initrad+(j+1)*pi/36.0f; - tt.x=cos(trad)*dist;tt.y=sin(trad)*dist; - tt.x-=t.x;tt.y-=t.y;trad=tt.x;tt.x=tt.y;tt.y=-trad; - trad=sqrt(sqr(tt.x)+sqr(tt.y)); - tt.x/=trad;tt.y/=trad; - //pos: 0~8, mult:0~8 - //pos: 24~32, mult: 8~0 - if (pos>=24) - tt.x*=(32-pos)/1.5f,tt.y*=(32-pos)/1.5f; - else - if (pos<=8) - tt.x*=pos/1.5f,tt.y*=pos/1.5f; - else - tt.x*=5.33f,tt.y*=5.33f; - //We only consider collisions when pos is between 9 and 23. - s.x=t.x+tt.x;s.y=t.y+tt.y; - if (j==31) - for (int k=31;k8&&pos<23) - laser[i].EnableColl=true; - else - laser[i].EnableColl=false; - } -} void Level1Part21()//Minesweeper?- { frameleft=ThirtySeconds; @@ -3636,167 +3109,4 @@ void Level1Part22()//Minesweeper?-child } } } -void Level1Part23()//The unbreakable jail?-used -{ - frameleft=ThirtySeconds; - if (bulcnt!=0)return (void)ClearAll(); - Lasercnt=0; - CTarg.Init(18,75,5.0f); - DisableAllTower=false; - CreateTower1(30,10,500,2); - CreateTower1(746,10,500,2); - CreateTower1(30,556,500,2); - CreateTower1(746,556,500,2); - ++part; -} -void Level1Part24()//child -{ - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - CTarg.SetRange(CTarg.GetRange()-0.002f); - CTarg.Update(); -} -double DTCircle; -BCircle Circles[20]; -int CCnt; -void Level1Part25()//Great circles-used -{ - towcnt=0; - frameleft=Infinity; - Circles[0].Init(444,20*pi/50000.0f,6,vector2d(400,300)); - Circles[1].Init(444,-20*pi/50000.0f,6,vector2d(400,300)); - CCnt=1; - DTCircle=0.0f; - ++part; -} -void Level1Part26()//Great circles-child1 -{ - frameleft=Infinity; - DTCircle+=hge->Timer_GetDelta(); - //Create New Circles here. - if (DTCircle>1&&CCnt<3) - { - Circles[2].Init(444,10*pi/50000.0f,12,vector2d(400,300)); - Circles[3].Init(444,-10*pi/50000.0f,12,vector2d(400,300)); - CCnt=3; - } - if (DTCircle>2&&CCnt<5) - { - Circles[4].Init(444,8*pi/50000.0f,18,vector2d(400,300)); - Circles[5].Init(444,-8*pi/50000.0f,18,vector2d(400,300)); - CCnt=5; - } - if (DTCircle>3&&CCnt<7) - { - Circles[6].Init(444,8*pi/50000.0f,27,vector2d(400,300)); - Circles[7].Init(444,-8*pi/50000.0f,27,vector2d(400,300)); - CCnt=7; - } - if (DTCircle>4&&CCnt<9) - { - Circles[8].Init(444,6*pi/50000.0f,45,vector2d(400,300)); - Circles[9].Init(444,-6*pi/50000.0f,45,vector2d(400,300)); - CCnt=9; - } - if (DTCircle>5&&CCnt<11) - { - Circles[10].Init(444,6*pi/50000.0f,60,vector2d(400,300)); - Circles[11].Init(444,-6*pi/50000.0f,60,vector2d(400,300)); - CCnt=11; - } - if (DTCircle>5&&CCnt<13) - { - Circles[12].Init(444,3*pi/50000.0f,96,vector2d(400,300)); - Circles[13].Init(444,-3*pi/50000.0f,96,vector2d(400,300)); - CCnt=13; - } - if (Circles[0].GetRange()>=50)//6 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[0].SetRange(Circles[0].GetRange()-0.1), - Circles[1].SetRange(Circles[1].GetRange()-0.1); - } - if (Circles[2].GetRange()>=100&&CCnt>=3)//12 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[2].SetRange(Circles[2].GetRange()-0.1), - Circles[3].SetRange(Circles[3].GetRange()-0.1); - } - if (Circles[4].GetRange()>=150&&CCnt>=5)//18 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[4].SetRange(Circles[4].GetRange()-0.1), - Circles[5].SetRange(Circles[5].GetRange()-0.1); - } - if (Circles[6].GetRange()>=210&&CCnt>=7)//27 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[6].SetRange(Circles[6].GetRange()-0.1), - Circles[7].SetRange(Circles[7].GetRange()-0.1); - } - if (Circles[8].GetRange()>=270&&CCnt>=9)//45 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[8].SetRange(Circles[8].GetRange()-0.1), - Circles[9].SetRange(Circles[9].GetRange()-0.1); - } - if (Circles[10].GetRange()>=320&&CCnt>=11)//60 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[10].SetRange(Circles[10].GetRange()-0.1), - Circles[11].SetRange(Circles[11].GetRange()-0.1); - } - if (Circles[12].GetRange()>=380&&CCnt>=13)//96 - { - int times=1;if (LOWFPS)times=17; - for (int i=1;i<=times;++i) - Circles[12].SetRange(Circles[12].GetRange()-0.1), - Circles[13].SetRange(Circles[13].GetRange()-0.1); - } - else - { - if (CCnt>=13)++part; - for (int i=1;i<=CCnt;++i) - Circles[i].SetDT(i*pi); - } - for (int i=0;i<=CCnt;++i)Circles[i].Update(); -} -void Level1Part27()//Great circles-child2 -{ - frameleft=Infinity; - for (int i=0;i<=CCnt;++i) - { - if (i==0||i==1)Circles[i].SetRange(50+10*sin(Circles[i].GetDT())); - if (i==2||i==3)Circles[i].SetRange(100+10*sin(Circles[i].GetDT())); - if (i==4||i==5)Circles[i].SetRange(150+10*sin(Circles[i].GetDT())); - if (i==6||i==7)Circles[i].SetRange(210+20*sin(Circles[i].GetDT())); - if (i==8||i==9)Circles[i].SetRange(270+20*sin(Circles[i].GetDT())); - if (i==10||i==11)Circles[i].SetRange(320+20*sin(Circles[i].GetDT())); - if (i==12||i==13)Circles[i].SetRange(380+30*sin(Circles[i].GetDT())); - Circles[i].Update(); - } -} -void Level1Part28()//? -{ - if (bulcnt) - { - ClearAll(); - return; - } - if (IfShowTip) - { - IfShowTip=false; - FadeTip=false; - Current_Position=2; - ShowTip("End of the TestBed version!"); - return; - } - Current_Position=0; - gui->Enter(); -}*/ +*/ -- cgit v1.2.3