script_enemy_main {
    let phase = 1;
    let angle = 90;
    let rank = GetSpeed;
    let arg = GetArgument()/2;
    let time=-arg;
    @Initialize(){
        SetLife( 10 );
        SetSpeed(0);
        SetAngle(90);
    }
    @MainLoop {
        if(time>arg){VanishEnemy;}
        time++;
    }
    @Finalize() {
    }
    @DrawLoop {
        let a=rank;
        if(time<0){a*=(arg+time)/arg}
        DrawText("x"~RealToIntString(a+1)~"",GetX,GetY,arg,255);
    }

function RealToIntString(let num){
   if(num<0){num=0;}
   let stringarray=["0","1","2","3","4","5","6","7","8","9"];
   let lp=floor(log10(num))+1;
   let lp1=lp;
   if(lp<=0){result="0"}
   else{
      result = "";
      loop(lp){
         result=result~ stringarray[(num%(10^lp1)-num%(10^(lp1-1)))/(10^(lp1-1))];
         lp1--;
      }
   }
}
}