
#### animationscript function main #####
# data/chars/misc/levelMap.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==21)
    {


		void self = getlocalvar("self");

 		int myMap = getglobalvar("vMap");

        	if(frame==0){

  		if (myMap == 1){performattack(self, openborconstant("ANI_FOLLOW1"));}

  		if (myMap == 2){performattack(self, openborconstant("ANI_FOLLOW2"));}

  		if (myMap == 3){performattack(self, openborconstant("ANI_FOLLOW3"));}

  		if (myMap == 4){performattack(self, openborconstant("ANI_FOLLOW4"));}

  		if (myMap == 5){performattack(self, openborconstant("ANI_FOLLOW5"));}

  		if (myMap == 6){performattack(self, openborconstant("ANI_FOLLOW6"));}

  		if (myMap == 7){performattack(self, openborconstant("ANI_FOLLOW7"));}

  		if (myMap == 8){performattack(self, openborconstant("ANI_FOLLOW8"));}

  		if (myMap >= 9){performattack(self, openborconstant("ANI_FOLLOW9"));}

                }

	        return;
    }

}

#### animationscript function main #####
# data/chars/misc/levelMapEvil.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==28)
    {


		void self = getlocalvar("self");

 		int myMap = getglobalvar("vMapEvil");

        	if(frame==0){

  		if (myMap == 1){performattack(self, openborconstant("ANI_FOLLOW1"));}

  		if (myMap == 2){performattack(self, openborconstant("ANI_FOLLOW2"));}

  		if (myMap == 3){performattack(self, openborconstant("ANI_FOLLOW3"));}

  		if (myMap == 4){performattack(self, openborconstant("ANI_FOLLOW4"));}

  		if (myMap == 5){performattack(self, openborconstant("ANI_FOLLOW5"));}

  		if (myMap == 6){performattack(self, openborconstant("ANI_FOLLOW6"));}

  		if (myMap == 7){performattack(self, openborconstant("ANI_FOLLOW7"));}

  		if (myMap == 8){performattack(self, openborconstant("ANI_FOLLOW8"));}

  		if (myMap >= 9){performattack(self, openborconstant("ANI_FOLLOW9"));}

                }

	        return;
    }

}

#### animationscript function main #####
# data/chars/misc/levelMapHero.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==35)
    {


		void self = getlocalvar("self");

 		int myMap = getglobalvar("vMapHero");

        	if(frame==0){

  		if (myMap == 1){performattack(self, openborconstant("ANI_FOLLOW1"));}

  		if (myMap == 2){performattack(self, openborconstant("ANI_FOLLOW2"));}

  		if (myMap == 3){performattack(self, openborconstant("ANI_FOLLOW3"));}

  		if (myMap == 4){performattack(self, openborconstant("ANI_FOLLOW4"));}

  		if (myMap == 5){performattack(self, openborconstant("ANI_FOLLOW5"));}

  		if (myMap == 6){performattack(self, openborconstant("ANI_FOLLOW6"));}

  		if (myMap == 7){performattack(self, openborconstant("ANI_FOLLOW7"));}

  		if (myMap == 8){performattack(self, openborconstant("ANI_FOLLOW8"));}

  		if (myMap >= 9){performattack(self, openborconstant("ANI_FOLLOW9"));}

                }

	        return;
    }

}

#### animationscript function main #####
# data/chars/hank/FlechaT.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==60)
    {
        if(frame==0)
        {
            velo001(20, 0, -15);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/hank/FlechaCima.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==61)
    {
        if(frame==0)
        {
            velo001(0, 0, 12);
        }
        if(frame==1)
        {
            velo001(0, 0, 12);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Hank_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==63)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==64)
    {
        if(frame==2)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==68)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelHank", 0, 70, 0);
        }
        return;
    }
    if(animhandle==69)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelHank", 0, 70, 0);
        }
        return;
    }
    if(animhandle==71)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==73)
    {
        if(frame==3)
        {
            spawn01("FlechaCima", 10, 17, 0);
        }
        if(frame==4)
        {
            spawn01("FlechaCima", 7, 17, 0);
        }
        if(frame==5)
        {
            spawn01("FlechaCima", 13, 17, 0);
        }
        if(frame==7)
        {
            spawn01("FlechaCima", 10, 17, 0);
        }
        if(frame==8)
        {
            spawn01("FlechaCima", 7, 17, 0);
        }
        if(frame==9)
        {
            spawn01("FlechaCima", 13, 17, 0);
        }
        if(frame==11)
        {
            spawn01("FlechaCima", 10, 17, 0);
        }
        if(frame==12)
        {
            spawn01("FlechaCima", 7, 17, 0);
        }
        if(frame==13)
        {
            spawn01("FlechaCima", 13, 17, 0);
        }
        if(frame==13)
        {
            toss("FlechaT", 60, 198, 2);
        }
        if(frame==14)
        {
            toss("FlechaT", 70, 200, 15);
        }
        if(frame==15)
        {
            toss("FlechaT", 90, 204, 0);
        }
        if(frame==16)
        {
            toss("FlechaT", 90, 208, 0);
        }
        if(frame==17)
        {
            toss("FlechaT", 70, 210, -15);
        }
        if(frame==18)
        {
            toss("FlechaT", 110, 198, 2);
        }
        if(frame==19)
        {
            toss("FlechaT", 116, 200, 15);
        }
        if(frame==20)
        {
            toss("FlechaT", 120, 204, 0);
        }
        if(frame==21)
        {
            toss("FlechaT", 130, 208, 0);
        }
        if(frame==22)
        {
            toss("FlechaT", 140, 210, -15);
        }
        if(frame==23)
        {
            toss("FlechaT", 230, 208, 15);
        }
        if(frame==24)
        {
            toss("FlechaT", 240, 210, -15);
        }
        return;
    }
    if(animhandle==74)
    {
        if(frame==3)
        {
            shoot("Flechaa2", 15, 40, 1);
        }
        return;
    }
    if(animhandle==75)
    {
        if(frame==3)
        {
            shoot("Flechaa2", 15, 40, 1);
        }
        return;
    }
    if(animhandle==76)
    {
        if(frame==3)
        {
            shoot("Flechaa3", 15, 40, 1);
        }
        return;
    }
    if(animhandle==77)
    {
        if(frame==3)
        {
            shoot("Flechaa4", 15, 40, 1);
        }
        return;
    }
    if(animhandle==78)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==79)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==80)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vHank");

		if (myVar==1 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if (myVar==2 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if (myVar==3 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

  		if (myVar==4 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

	        if(frame==3)
        {
            shoot("Flechaa", 15, 40, 1);
        }
        return;
    }
    if(animhandle==81)
    {
        if(frame==2)
        {
            shoot("Flechaa2", 15, 45, 1);
        }
        return;
    }
    if(animhandle==82)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vHank");

 		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vHank", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==83)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vHank");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Hank______Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Hank______Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Hank______Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Hank______Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Hank______Level__1");

	  }

	}

	        return;
    }
    if(animhandle==84)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==89)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vHank");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Hank______Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Hank______Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Hank______Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Hank______Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Hank______Level__1");

	  }

	}

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/misc/fada.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==95)
    {


	if(frame==5){

                 shoot("fadaTiro", 0, 20, 0);

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/DM_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==106)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDM", 0, 70, 0);
        }
        return;
    }
    if(animhandle==107)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDM", 0, 70, 0);
        }
        return;
    }
    if(animhandle==109)
    {
        if(frame==0)
        {
            spawn01("levelMapHero", 20, 70, 0);
        }
        return;
    }
    if(animhandle==111)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vMestre");

     	        void mana = getentityproperty(self,"mp"); //get mp

         	if (myVar==NULL()){

		changeentityproperty(self, "mp", mana-20);

		}else{

  		if (myVar==0){

    		changeentityproperty(self, "mp", mana-20);

 	   	}

		if (myVar==1){

     		changeentityproperty(self, "mp", mana-15);

 	   	}

		if (myVar==2){

 		changeentityproperty(self, "mp", mana-10);

 	   	}

		if (myVar==3){

 		changeentityproperty(self, "mp", mana-5);

 	   	}

  		if (myVar>=4){

 		changeentityproperty(self, "mp", mana-1);

 	   	}

 	   	}

 	}

	        if(frame==4)
        {
            velo001(40, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==112)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==113)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==114)
    {


	if(frame==4){

                 shoot("VingaTiro1", 10, 11, 0);

        }

       	if(frame==0){

	int myVar = getglobalvar("vMapHero");

	       if(myVar>=6){

                 spawn01("fada", -10, 0, 1);

               }

	}

	        return;
    }
    if(animhandle==115)
    {


	if(frame==4){

                 shoot("VingaTiro1", 10, 11, 0);

        }

	        return;
    }
    if(animhandle==116)
    {
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        if(frame==10)
        {
            keymove(1, 1);
        }
        if(frame==11)
        {
            keymove(1, 1);
        }
        if(frame==12)
        {
            keymove(1, 1);
        }
        if(frame==13)
        {
            keymove(1, 1);
        }
        if(frame==14)
        {
            keymove(1, 1);
        }
        if(frame==15)
        {
            keymove(1, 1);
        }
        if(frame==16)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==117)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vMestre");

 		int myMap = getglobalvar("vMapHero");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapHero", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vMestre", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==118)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMestre");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Mestre___Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Mestre___Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Mestre___Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Mestre___Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Mestre___Level__1");

	  }

	}

	        return;
    }
    if(animhandle==119)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==124)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMestre");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Mestre___Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Mestre___Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Mestre___Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Mestre___Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Mestre___Level__1");

	  }

	}

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/CavLVL1.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==130)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }
    if(animhandle==137)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/CavLVL2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==142)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }
    if(animhandle==149)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/CavLVL3.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==154)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }
    if(animhandle==161)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/CavLVL4.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==166)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }
    if(animhandle==172)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/venger2_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==180)
    {
        if(frame==0)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==181)
    {


	if (frame == 0){

	       void self = getlocalvar("self");

	       int myMap = getglobalvar("vMapEvil");

	       if ((myMap>=6)){

       	       int s = rand()%4;

    	       if(s==-3){performattack(self, openborconstant("ANI_follow10"));}

    	       if(s==-2){performattack(self, openborconstant("ANI_follow10"));}

      	       if(s==-1){performattack(self, openborconstant("ANI_follow11"));}

      	       if(s==0){performattack(self, openborconstant("ANI_follow12"));}

      	       if(s==1){performattack(self, openborconstant("ANI_follow13"));}

  	       if(s==2){performattack(self, openborconstant("ANI_follow14"));}

    	       if(s==3){performattack(self, openborconstant("ANI_follow15"));}

	        }

 	}

	        return;
    }
    if(animhandle==185)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelVinga", 0, 70, 0);
        }
        return;
    }
    if(animhandle==186)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==189)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==192)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelVinga", 0, 70, 0);
        }
        return;
    }
    if(animhandle==194)
    {
        if(frame==0)
        {
            spawn01("levelMapEvil", 20, 70, 0);
        }
        return;
    }
    if(animhandle==196)
    {


	if(frame==5){

		int myVar = getglobalvar("vVinga2");

		if(myVar==NULL() || (myVar==0) ){

                 spawn01("cavLVL1", 32, 0, 0);

               }

  		if((myVar==1)){

                 spawn01("cavLVL2", 32, 0, 0);

               }

  		if((myVar==2)){

                 spawn01("cavLVL3", 32, 0, 0);

               }

  		if((myVar==3)){

                 spawn01("cavLVL1", 32, 0, 0);

                 spawn01("cavLVL1", -32, 0, 0);

               }

  		if(myVar>=4){

                 spawn01("cavLVL2", 62, 0, 0);

                 spawn01("cavLVL4", 32, 0, 0);

                 spawn01("cavLVL2", -32, 0, 0);

               }

        }

	        return;
    }
    if(animhandle==197)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==198)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==199)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myMap = getglobalvar("vMapEvil");

		if ((myMap>=6)){

		performattack(self, openborconstant("ANI_freespecial6"));

 	   	}

 	}

	if(frame==9){

                 shoot("VingaTiro2", 0, 11, 0);

        }

	        return;
    }
    if(animhandle==200)
    {


	if(frame==5){

		int myMap = getglobalvar("vMapEvil");

		if ((myMap>=6)){

		    shoot("VingaTiro3", 0, 11, 0);

		}else{

	            shoot("VingaTiro2", 0, 11, 0);

                }

        }

	        return;
    }
    if(animhandle==201)
    {


	if(frame==9){

                 shoot("VingaTiro3", 0, 11, 0);

        }

	        return;
    }
    if(animhandle==202)
    {
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        if(frame==10)
        {
            keymove(1, 1);
        }
        if(frame==11)
        {
            keymove(1, 1);
        }
        if(frame==12)
        {
            keymove(1, 1);
        }
        if(frame==13)
        {
            keymove(1, 1);
        }
        if(frame==14)
        {
            keymove(1, 1);
        }
        if(frame==15)
        {
            keymove(1, 1);
        }
        if(frame==16)
        {
            keymove(1, 1);
        }
        if(frame==17)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==203)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vVinga2");

 		int myMap = getglobalvar("vMapEvil");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapEvil", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vVinga2", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==204)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga2");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Vingador__Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Vingador__Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Vingador__Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Vingador__Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Vingador__Level__1");

	  }

	}

	        return;
    }
    if(animhandle==205)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==210)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga2");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Vingador_Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Vingador_Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Vingador_Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Vingador_Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Vingador_Level__1");

	  }

	}

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Evil_2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==219)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga2");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Vingador__Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Vingador__Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Vingador__Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Vingador__Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Vingador__Level__1");

	  }

	}

	        return;
    }
    if(animhandle==220)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Hank_2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==231)
    {


	void self = getlocalvar("self");

	if (frame == 0){

	changeentityproperty(self, "name", "Hank__Level__MAX");

	 }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Sheila_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==243)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==244)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==246)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==249)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==11)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==250)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==13)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==251)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==15)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==252)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==17)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==253)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==254)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==255)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSheila");

		if (myVar==1 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if (myVar==2 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if (myVar==3 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

		if (myVar==4 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

	        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==9)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==257)
    {
        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==258)
    {
        if(frame==0)
        {
            velo001(1, 0, 0);
        }
        if(frame==1)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==259)
    {
        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==260)
    {
        if(frame==0)
        {
            velo001(2, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==261)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSheila");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                               }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vSheila", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==262)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Sheila____Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Sheila____Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Sheila____Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Sheila____Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Sheila____Level__1");

	  }

	}

	        return;
    }
    if(animhandle==263)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Sheila_inv.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==270)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==274)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==275)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==276)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==277)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==279)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==281)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSheila");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                               }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vSheila", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==282)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	  }else{

	    changeentityproperty(self, "map", 0);

	  }

	}

	        return;
    }
    if(animhandle==283)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Presto/PrestoTiroA1.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==296)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        if(frame==7)
        {
            velo001(1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Presto_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==305)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelPresto", 0, 70, 0);
        }
        return;
    }
    if(animhandle==306)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelPresto", 0, 70, 0);
        }
        return;
    }
    if(animhandle==308)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==310)
    {
        if(frame==1)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==5)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==9)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==13)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        return;
    }
    if(animhandle==311)
    {


	if(frame==4)

	{

       	       int r = rand()%6;

       	       if(r==-5){shoot("PrestoTiroA3", 20, 15, 0);}

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

      	       if(r==5){shoot("PrestoTiro02", 15, 15, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==312)
    {


	if(frame==4)

	{

       	       int r = rand()%5;

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro04", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==313)
    {


	if(frame==4)

	{

       	       int r = rand()%5;

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro04", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiroVerde", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiroVerde", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiro02", 15, 15, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==314)
    {


	if(frame==4)

	{

       	       int r = rand()%4;

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiroVerde", 10, 0, 0);}

 	       if(r==2){shoot("HolyTiro", 15, 20, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==315)
    {


	if(frame==3)

	{

       	       int r = rand()%5;

       	       if(r==-4){shoot("PrestoTiro01", 15, 25, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 20, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 20, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 20, 0);}

      	       if(r==0){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 5, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 5, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==4){shoot("PrestoTiro02", 15, 25, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==316)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==317)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==318)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if (myVar==1 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial10"));

   	}

	if (myVar==2 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial11"));

   	}

	if (myVar==3 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial12"));

   	}

 	if (myVar==4 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial13"));

   	}

	if(frame==4)

	{

       	       int r = rand()%6;

       	       if(r==-5){shoot("PrestoTiroA3", 20, 15, 0);}

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

      	       if(r==5){}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==319)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

 	if (myVar>=4 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial15"));

   	}

	if(frame==3)

	{

       	       int r = rand()%5;

       	       if(r==-4){shoot("PrestoTiroA3", 15, 25, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 20, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 20, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 20, 0);}

      	       if(r==0){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 5, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 5, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==4){shoot("PrestoTiroA3", 15, 25, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==320)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vPresto");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vPresto", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==321)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Presto__Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Presto__Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Presto__Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Presto__Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Presto__Level__1");

	  }

	}

	        return;
    }
    if(animhandle==322)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Presto_2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==334)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelPresto", 0, 70, 0);
        }
        return;
    }
    if(animhandle==335)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelPresto", 0, 70, 0);
        }
        return;
    }
    if(animhandle==337)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==338)
    {
        if(frame==1)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==5)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==9)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==13)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        return;
    }
    if(animhandle==339)
    {


	if(frame==4)

	{

       	       int r = rand()%6;

       	       if(r==-5){shoot("PrestoTiroA3", 20, 15, 0);}

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

      	       if(r==5){shoot("PrestoTiro02", 15, 15, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==340)
    {


	if(frame==4)

	{

       	       int r = rand()%5;

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==341)
    {


	if(frame==4)

	{

       	       int r = rand()%5;

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiro02", 15, 15, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==342)
    {


	if(frame==4)

	{

       	       int r = rand()%4;

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==345)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if(frame==4)

	{

       	       int r = rand()%2;

       	       if(r==-1){shoot("PrestoTiroA3", 20, 15, 0);}

       	       if(r==0){spawn01("PrestoTiroA1", 20, 6, 0);}

      	       if(r==1){shoot("PrestoTiroA2", 20, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==346)
    {


	if(frame==3)

	{



      	       shoot("PrestoTiroA3", 15, 25, 0);

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==347)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vPresto");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vPresto", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==348)
    {


	void self = getlocalvar("self");

	if (frame == 0){

	changeentityproperty(self, "name", "Presto__Level__MAX");

	 }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/DM_2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==360)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vMestre");

     	        void mana = getentityproperty(self,"mp"); //get mp

         	if (myVar==NULL()){

		changeentityproperty(self, "mp", mana-20);

		}else{

  		if ((myVar==0)||(myVar==1)){

    		changeentityproperty(self, "mp", mana-20);

 	   	}

		if ((myVar==2)||(myVar==3)){

     		changeentityproperty(self, "mp", mana-15);

 	   	}

		if ((myVar==4)||(myVar==5)){

 		changeentityproperty(self, "mp", mana-10);

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

 		changeentityproperty(self, "mp", mana-5);

 	   	}

  		if (myVar>=9){

 		changeentityproperty(self, "mp", mana-1);

 	   	}

 	   	}

 	}

	        if(frame==4)
        {
            velo001(10, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==363)
    {


	if(frame==4){

                 shoot("PrestoTiroA3", 10, 11, 0);

        }

	        return;
    }
    if(animhandle==364)
    {


	if(frame==4){

                 shoot("PrestoTiroA3", 10, 11, 0);

        }

	        return;
    }
    if(animhandle==365)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMestre");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Mestre___Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Mestre___Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Mestre___Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Mestre___Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Mestre___Level__1");

	  }

	}

	        return;
    }
    if(animhandle==366)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Bobby_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==376)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==381)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==382)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==384)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==386)
    {
        if(frame==9)
        {
            spawn01("stomp", 35, 0, -1);
        }
        if(frame==10)
        {
            spawn01("stomp", 105, 0, -1);
        }
        if(frame==11)
        {
            spawn01("stomp", 175, 0, -1);
        }
        if(frame==12)
        {
            spawn01("stomp", 245, 0, -1);
        }
        return;
    }
    if(animhandle==391)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==392)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==393)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vBobby");

		if (myVar==1 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if (myVar==2 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if (myVar==3 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

		if (myVar==4 && frame == 0){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

	        return;
    }
    if(animhandle==395)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vBobby");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vBobby", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==396)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vBobby");

	if (frame == 0){

	  if (myVar!=NULL()){

          changeentityproperty(self, "map", myVar);

	  if (myVar==1){changeentityproperty(self, "name", "Bobby____Level__2");}

	  if (myVar==2){changeentityproperty(self, "name", "Bobby____Level__3");}

	  if (myVar==3){changeentityproperty(self, "name", "Bobby____Level__4");}

 	  if (myVar==4){changeentityproperty(self, "name", "Bobby____Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Bobby____Level__1");

	  }

	}

	        return;
    }
    if(animhandle==397)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Eric_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==408)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==409)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==411)
    {
        if(frame==0)
        {
            velo001(-2, 0, 0);
        }
        return;
    }
    if(animhandle==412)
    {
        if(frame==0)
        {
            velo001(-3, 0, 0);
        }
        return;
    }
    if(animhandle==413)
    {
        if(frame==0)
        {
            velo001(-4, 0, 0);
        }
        return;
    }
    if(animhandle==414)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PrestoTiroVerde", 20, 10, 1);
        }
        return;
    }
    if(animhandle==415)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("FlechaEP", 20, 43, 1);
        }
        return;
    }
    if(animhandle==416)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PrestoTiro03", 20, 10, 1);
        }
        return;
    }
    if(animhandle==417)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("LancaEP", 20, 37, 1);
        }
        return;
    }
    if(animhandle==418)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PedraEP", 20, 37, 1);
        }
        return;
    }
    if(animhandle==419)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PrestoTiro01", 20, 35, 1);
        }
        return;
    }
    if(animhandle==422)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==423)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==425)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==427)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==428)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==429)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(1, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==431)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vEric");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vEric", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==432)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vEric");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

            if (myVar==1){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.85, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.90, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.95, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__2");

	    }

            if (myVar==2){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.70, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.75, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.80, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__3");

	    }

            if (myVar==3){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__4");

	    }

            if (myVar==4){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.45, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.50, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.55, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__MAX");

	    }

	    }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Eric________Level__1");

	  }

	}

	        return;
    }
    if(animhandle==433)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Diana_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==442)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==6)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==446)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDiana", 0, 70, 0);
        }
        return;
    }
    if(animhandle==447)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDiana", 0, 70, 0);
        }
        return;
    }
    if(animhandle==450)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==452)
    {


    	if (frame==2){

    	       void self = getlocalvar("self");

               performattack(self, openborconstant("ANI_FOLLOW3"));

        }

	        return;
    }
    if(animhandle==453)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==454)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==455)
    {
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        if(frame==10)
        {
            keymove(1, 1);
        }
        if(frame==11)
        {
            keymove(1, 1);
        }
        if(frame==12)
        {
            keymove(1, 1);
        }
        if(frame==13)
        {
            keymove(1, 1);
        }
        if(frame==14)
        {
            keymove(1, 1);
        }
        if(frame==15)
        {
            keymove(1, 1);
        }
        if(frame==16)
        {
            keymove(1, 1);
        }
        if(frame==17)
        {
            keymove(1, 1);
        }
        if(frame==18)
        {
            keymove(1, 1);
        }
        if(frame==19)
        {
            keymove(1, 1);
        }
        if(frame==20)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==458)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vDiana");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vDiana", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==459)
    {


	void self = getlocalvar("self");

	float myVar = getglobalvar("vDiana");

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

	    if (myVar==1){

	    changeentityproperty(self, "speed", 1.9);

	    changeentityproperty(self, "name", "Diana_____Level__2");}

	    if (myVar==2){

	    changeentityproperty(self, "speed", 2.1);

	    changeentityproperty(self, "name", "Diana_____Level__3");}

	    if (myVar==3){

	    changeentityproperty(self, "speed", 2.3);

	    changeentityproperty(self, "name", "Diana_____Level__4");}

	    if (myVar==4){

	    changeentityproperty(self, "speed", 2.5);

	    changeentityproperty(self, "name", "Diana_____Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "speed", 1.7);

	    changeentityproperty(self, "name", "Diana_____Level__1");

	  }

	}

	        return;
    }
    if(animhandle==460)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Kelek_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==473)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelKelek", 0, 70, 0);
        }
        return;
    }
    if(animhandle==474)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelKelek", 0, 70, 0);
        }
        return;
    }
    if(animhandle==476)
    {
        if(frame==0)
        {
            spawn01("levelMapEvil", 20, 70, 0);
        }
        return;
    }
    if(animhandle==478)
    {


	int myVar = getglobalvar("vKelek");

	if (frame == 2){

		spawn01("raioK", 80, 0 ,0);

	}



	if (frame == 4){

		if (myVar>=1){

		spawn01("raioK", 115, 0 ,0);

 	   	}

        }

 	if (frame == 6){

		if (myVar>=2){

		spawn01("raioK", 150, 0 ,0);

 	   	}

 	}

 	if (frame == 8){

		if (myVar>=3){

		spawn01("raioK", 185, 0 ,0);

 	   	}

	}

	if (frame == 10){

  		if (myVar>=4){

		spawn01("raioK", 210, 0 ,0);

 	   	}

	}

	        return;
    }
    if(animhandle==479)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==480)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==481)
    {
        if(frame==4)
        {
            shoot("PrestoTiro01", 50, 40, 1);
        }
        return;
    }
    if(animhandle==482)
    {
        if(frame==4)
        {
            shoot("PrestoTiro01", 50, 33, 1);
        }
        return;
    }
    if(animhandle==483)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vKelek");

  		int myMap = getglobalvar("vMapEvil");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapEvil", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vKelek", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==484)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vKelek");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Kelek________Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Kelek________Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Kelek________Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Kelek________Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Kelek________Level__1");

	  }

	}

	        return;
    }
    if(animhandle==485)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/lolth_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==499)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelLolth", 0, 70, 0);
        }
        return;
    }
    if(animhandle==500)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelLolth", 0, 70, 0);
        }
        return;
    }
    if(animhandle==503)
    {
        if(frame==0)
        {
            spawn01("levelMapEvil", 20, 70, 0);
        }
        return;
    }
    if(animhandle==505)
    {


	if (frame == 5){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vLolth");

		if ((myVar==1)){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if ((myVar==2)){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if ((myVar==3)){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

  		if (myVar>=4){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

                performattack(self, openborconstant("ANI_FOLLOW3"));



 	}

	        return;
    }
    if(animhandle==510)
    {


 	        void self = getlocalvar("self");

		if(frame==5){

               	  performattack(self, openborconstant("ANI_freespecial20"));

               }

	        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==511)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==512)
    {
        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==513)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==514)
    {


 	        void self = getlocalvar("self");

		if(frame==4){

               	  performattack(self, openborconstant("ANI_freespecial20"));

               }

	        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==519)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vLolth");

  		int myMap = getglobalvar("vMapEvil");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapEvil", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vLolth", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==520)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vLolth");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Lolth________Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Lolth________Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Lolth________Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Lolth________Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Lolth________Level__1");

	  }

	}

	        return;
    }
    if(animhandle==521)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Warduke_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==530)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if ((myVar==2 || myVar==3 ||myVar==4) && frame == 0){

	performattack(self, openborconstant("ANI_follow3"));

   	}

	        return;
    }
    if(animhandle==532)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }
    if(animhandle==535)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==536)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==539)
    {
        if(frame==0)
        {
            spawn01("levelMapEvil", 20, 70, 0);
        }
        return;
    }
    if(animhandle==541)
    {
        if(frame==3)
        {
            velo001(4, 0, 0);
        }
        if(frame==10)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==543)
    {
        if(frame==9)
        {
            shoot("PrestoTiro02", 60, 30, 1);
        }
        return;
    }
    if(animhandle==544)
    {
        if(frame==9)
        {
            shoot("PrestoTiro04", 65, 6, 1);
        }
        return;
    }
    if(animhandle==545)
    {
        if(frame==9)
        {
            shoot("WardukeTiro", 60, 22, 1);
        }
        return;
    }
    if(animhandle==546)
    {
        if(frame==9)
        {
            shoot("PrestoHyper", 60, 30, 1);
        }
        return;
    }
    if(animhandle==547)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==548)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==549)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if (myVar==1 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial10"));

   	}

	if (myVar==2 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial11"));

   	}

	if (myVar==3 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial12"));

   	}

 	if (myVar==4 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial13"));

   	}

	        if(frame==9)
        {
            shoot("PrestoTiro01", 60, 30, 1);
        }
        return;
    }
    if(animhandle==550)
    {


	void self = getlocalvar("self");

	if (frame <= 1 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial9"));

	}

	if (frame == 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial8"));

	}

	if (frame > 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_jumpland"));

	}

	        return;
    }
    if(animhandle==551)
    {


	void self = getlocalvar("self");

	if (frame <= 1 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial9"));

	}

	if (frame == 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial8"));

	}

	if (frame > 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_jumpland"));

	}

	        return;
    }
    if(animhandle==554)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vWarduke");

  		int myMap = getglobalvar("vMapEvil");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapEvil", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vWarduke", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==555)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Warduke___Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Warduke___Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Warduke___Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Warduke___Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Warduke___Level__1");

	  }

	}

	        return;
    }
    if(animhandle==556)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Uni_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==564)
    {


	if(frame==0)	

	{	

	int	SFX1 = loadsample("data/chars/player/uni1.wav");

	int	SFX2 = loadsample("data/chars/player/uni2.wav");

	int	SFX3 = loadsample("data/chars/player/uni3.wav");

	int	SFX4 = loadsample("data/chars/player/uni4.wav");

	int	SFX5 = loadsample("data/chars/player/uni5.wav");

	int	SFX6 = loadsample("data/chars/player/uni6.wav");

	int	SFX7 = loadsample("data/chars/player/uni7.wav");

	int	s = rand()%4;

	if(s==-3){playsample(SFX1,	0, 120, 120, 100, 0);}

	if(s==-2){playsample(SFX2,	0, 120, 120, 100, 0);}

	if(s==-1){playsample(SFX3,	0, 120, 120, 100, 0);}

	if(s==0){playsample(SFX4,	0, 120, 120, 100, 0);}

	if(s==1){playsample(SFX5,	0, 120, 120, 100, 0);}

	if(s==2){playsample(SFX6,	0, 120, 120, 100, 0);}

	if(s==3){playsample(SFX7,	0, 120, 120, 100, 0);}

	}	

	        if(frame==1)
        {
            velo001(2, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==568)
    {
        if(frame==5)
        {
            velo001(50, 0, 0);
        }
        if(frame==6)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==569)
    {


	void self = getlocalvar("self");

	if (frame == 0){

	    changeentityproperty(self, "name", "Uni");

	}

	        return;
    }
    if(animhandle==570)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==572)
    {
        if(frame==0)
        {
            velo001(-2, 0, 0);
        }
        if(frame==1)
        {
            velo001(0, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/SD_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==580)
    {
        if(frame==0)
        {
            velo001(2, 0, 0);
        }
        if(frame==8)
        {
            velo001(60, 0, 0);
        }
        if(frame==9)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==581)
    {


	void self = getlocalvar("self");

	if (frame == 0){

	    changeentityproperty(self, "name", "Demonio_das_Sombras");

	}

	        return;
    }
    if(animhandle==582)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Sir_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==594)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==595)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==598)
    {
        if(frame==0)
        {
            spawn01("levelMapHero", 20, 70, 0);
        }
        return;
    }
    if(animhandle==600)
    {


	void self = getlocalvar("self");

	if(frame==0){

	changeentityproperty(self, "stealth", 20);

    	}

	if(frame==4){

    	void mana = getentityproperty(self,"mp"); //get mp

    	changeentityproperty(self, "mp", mana-3);//add mp

    	if (mana < 3){

        performattack(self, openborconstant("ANI_freespecial6"));

        }

    	}

	        return;
    }
    if(animhandle==601)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==602)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==603)
    {


       	if(frame==0){

	int myVar = getglobalvar("vMapHero");

	       if(myVar>=6){

                 spawn01("fada", -10, 0, 1);

               }

	}

	        return;
    }
    if(animhandle==606)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSir");

  		int myMap = getglobalvar("vMapHero");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapHero", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vSir", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==607)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSir");

	if(frame==0){

	changeentityproperty(self, "stealth", 0);

    	}

	if (frame == 0){

	  if (myVar!=NULL()){

     	    changeentityproperty(self, "map", myVar);

            if (myVar==1){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.85, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.90, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.95, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__2");

	    }

            if (myVar==2){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.70, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.75, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.80, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__3");

	    }

            if (myVar==3){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__4");

	    }

            if (myVar==4){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.45, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.50, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.55, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__MAX");

	    }

	    }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Sir._John______Level__1");

	  }

	}

	        return;
    }
    if(animhandle==608)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Strongheart_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==621)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==626)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelStrong", 0, 70, 0);
        }
        return;
    }
    if(animhandle==627)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelStrong", 0, 70, 0);
        }
        return;
    }
    if(animhandle==629)
    {
        if(frame==0)
        {
            spawn01("levelMapHero", 20, 70, 0);
        }
        return;
    }
    if(animhandle==631)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vStrong");

	if(frame == 8){

	if (myVar==NULL()){

         spawn01("cura1", 60, 33, 0);

   	}

	if (myVar==1){

         spawn01("cura2", 60, 33, 0);

   	}

	if (myVar==2){

         spawn01("cura3", 60, 1, 0);

   	}

	if (myVar==3){

         spawn01("cura4", 60, 1, 0);

   	}

	if (myVar==4){

         spawn01("cura5", 60, 1, 0);

   	}

   	}

	        return;
    }
    if(animhandle==632)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==633)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==634)
    {


       	if(frame==0){

	int myVar = getglobalvar("vMapHero");

	       if(myVar>=6){

                 spawn01("fada", -10, 0, 1);

               }

	}

	        if(frame==9)
        {
            shoot("HolyTiro", 37, 43, 1);
        }
        return;
    }
    if(animhandle==636)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vStrong");

  		int myMap = getglobalvar("vMapHero");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapHero", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vStrong", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==637)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vStrong");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Strongheart_Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Strongheart_Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Strongheart_Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Strongheart_Level___MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Strongheart_Level___1");

	  }

	}

	        return;
    }
    if(animhandle==638)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Rahmud_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==649)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==651)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==655)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==656)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==658)
    {
        if(frame==0)
        {
            spawn01("levelMapHero", 20, 70, 0);
        }
        return;
    }
    if(animhandle==660)
    {


       	if(frame==0){

	int myVar = getglobalvar("vMapHero");

	       if(myVar>=6){

                 spawn01("fada", -10, 0, 1);

               }

	}

	        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        if(frame==6)
        {
            velo001(4, 0, 0);
        }
        if(frame==9)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==661)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vRahmud");

	if(frame == 0){

	if (myVar==NULL()||(myVar==0)){

	performattack(self, openborconstant("ANI_freespecial11"));

   	}

	if (myVar==1){

	performattack(self, openborconstant("ANI_freespecial12"));

   	}

	if (myVar==2){

 	performattack(self, openborconstant("ANI_freespecial13"));

   	}

	if (myVar==3){

	performattack(self, openborconstant("ANI_freespecial14"));

   	}

	if (myVar>=4){

	performattack(self, openborconstant("ANI_freespecial15"));

   	}

   	}

	        return;
    }
    if(animhandle==662)
    {
        if(frame==6)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==663)
    {
        if(frame==6)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==664)
    {
        if(frame==6)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==665)
    {
        if(frame==6)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==666)
    {
        if(frame==6)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        return;
    }
    if(animhandle==667)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==668)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==671)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vRahmud");

  		int myMap = getglobalvar("vMapHero");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapHero", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vRahmud", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==672)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vRahmud");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Rahmud____Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Rahmud____Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Rahmud____Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Rahmud____Level___MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Rahmud____Level___1");

	  }

	}

	        return;
    }
    if(animhandle==673)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Miner/Mina.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==681)
    {


	if (frame==8){

    	       void self = getlocalvar("self");

    	       killentity(self);

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Bruenor_.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==688)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==689)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vMiner");

		if ((myVar==1)){

		performattack(self, openborconstant("ANI_follow11"));

 	   	}

		if ((myVar==2)){

		performattack(self, openborconstant("ANI_follow12"));

 	   	}

		if ((myVar==3)){

		performattack(self, openborconstant("ANI_follow13"));

 	   	}

  		if (myVar>=4){

		performattack(self, openborconstant("ANI_follow14"));

 	   	}

 	}

	        return;
    }
    if(animhandle==693)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==695)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==696)
    {
        if(frame==1)
        {
            velo001(2, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==697)
    {
        if(frame==1)
        {
            velo001(3, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==698)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==700)
    {
        if(frame==0)
        {
            spawn01("levelMapHero", 20, 70, 0);
        }
        return;
    }
    if(animhandle==702)
    {
        if(frame==4)
        {
            spawn01("Mina", 2, 0, 1);
        }
        return;
    }
    if(animhandle==703)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==704)
    {
        if(frame==0)
        {
            spawnbind("troca", 0, 1, 1);
        }
        return;
    }
    if(animhandle==705)
    {


       	if(frame==0){

	int myVar = getglobalvar("vMapHero");

	       if(myVar>=6){

                 spawn01("fada", -10, 0, 1);

               }

	}

	        if(frame==6)
        {
            toss("MinerTiro", 15, 35, 1);
        }
        return;
    }
    if(animhandle==707)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vMiner");

  		int myMap = getglobalvar("vMapHero");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMapHero", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<4){

		  setglobalvar("vMiner", myVar + 1);

  		   if (myVar==3){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

                  performattack(self, openborconstant("ANI_FOLLOW1"));

                  }

                }

	        return;
    }
    if(animhandle==708)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMiner");

	if (frame == 0){

	  if (myVar!=NULL()){

          changeentityproperty(self, "map", myVar);

	  if (myVar==1){changeentityproperty(self, "name", "Bruenor__Level__2");}

	  if (myVar==2){changeentityproperty(self, "name", "Bruenor__Level__3");}

	  if (myVar==3){changeentityproperty(self, "name", "Bruenor__Level__4");}

 	  if (myVar==4){changeentityproperty(self, "name", "Bruenor__Level__MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Bruenor__Level__1");

	  }

	}

	        return;
    }
    if(animhandle==709)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Hank.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==717)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==718)
    {
        if(frame==2)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==722)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vHank");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==723)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelHank", 0, 70, 0);
        }
        return;
    }
    if(animhandle==725)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==727)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelHank", 0, 70, 0);
        }
        return;
    }
    if(animhandle==728)
    {
        if(frame==3)
        {
            spawn01("FlechaCima", 10, 17, 0);
        }
        if(frame==4)
        {
            spawn01("FlechaCima", 7, 17, 0);
        }
        if(frame==5)
        {
            spawn01("FlechaCima", 13, 17, 0);
        }
        if(frame==7)
        {
            spawn01("FlechaCima", 10, 17, 0);
        }
        if(frame==8)
        {
            spawn01("FlechaCima", 7, 17, 0);
        }
        if(frame==9)
        {
            spawn01("FlechaCima", 13, 17, 0);
        }
        if(frame==11)
        {
            spawn01("FlechaCima", 10, 17, 0);
        }
        if(frame==12)
        {
            spawn01("FlechaCima", 7, 17, 0);
        }
        if(frame==13)
        {
            spawn01("FlechaCima", 13, 17, 0);
        }
        if(frame==13)
        {
            toss("FlechaT", 60, 198, 2);
        }
        if(frame==14)
        {
            toss("FlechaT", 70, 200, 15);
        }
        if(frame==15)
        {
            toss("FlechaT", 90, 204, 0);
        }
        if(frame==16)
        {
            toss("FlechaT", 90, 208, 0);
        }
        if(frame==17)
        {
            toss("FlechaT", 70, 210, -15);
        }
        if(frame==18)
        {
            toss("FlechaT", 110, 198, 2);
        }
        if(frame==19)
        {
            toss("FlechaT", 116, 200, 15);
        }
        if(frame==20)
        {
            toss("FlechaT", 120, 204, 0);
        }
        if(frame==21)
        {
            toss("FlechaT", 130, 208, 0);
        }
        if(frame==22)
        {
            toss("FlechaT", 140, 210, -15);
        }
        if(frame==23)
        {
            toss("FlechaT", 230, 208, 15);
        }
        if(frame==24)
        {
            toss("FlechaT", 240, 210, -15);
        }
        return;
    }
    if(animhandle==729)
    {
        if(frame==3)
        {
            shoot("Flechaa2", 15, 40, 1);
        }
        return;
    }
    if(animhandle==730)
    {
        if(frame==3)
        {
            shoot("Flechaa2", 15, 40, 1);
        }
        return;
    }
    if(animhandle==731)
    {
        if(frame==3)
        {
            shoot("Flechaa3", 15, 40, 1);
        }
        return;
    }
    if(animhandle==732)
    {
        if(frame==3)
        {
            shoot("Flechaa4", 15, 40, 1);
        }
        return;
    }
    if(animhandle==735)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vHank");

		if ((myVar==2)||(myVar==3)){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if ((myVar==4)||(myVar==5)){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

  		if (myVar>=9){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

 	}

	        if(frame==3)
        {
            shoot("Flechaa", 15, 40, 1);
        }
        return;
    }
    if(animhandle==736)
    {
        if(frame==2)
        {
            shoot("Flechaa2", 15, 45, 1);
        }
        return;
    }
    if(animhandle==737)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vHank");

 		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vHank", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==738)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vHank");

	if (frame == 0){

	  if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Hank______Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Hank______Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Hank______Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Hank______Level__5");}

	if (myVar==5){changeentityproperty(self, "name", "Hank______Level__6");}

	if (myVar==6){changeentityproperty(self, "name", "Hank______Level__7");}

	if (myVar==7){changeentityproperty(self, "name", "Hank______Level__8");}

	if (myVar==8){changeentityproperty(self, "name", "Hank______Level__9");}

	if (myVar==9){changeentityproperty(self, "name", "Hank______Level__MAX");}

	  }else{

	    changeentityproperty(self, "name", "Hank______Level__1");

	  }

	}

	        return;
    }
    if(animhandle==739)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==743)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vHank");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Sheila.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==752)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==753)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==755)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==757)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==759)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==11)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==760)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==13)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==761)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==15)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==762)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==17)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==765)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vSheila");

		if ((myVar==2)||(myVar==3)){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if ((myVar==4)||(myVar==5)){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

		if (myVar>=9){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

	}

	        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==9)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==767)
    {
        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==768)
    {
        if(frame==0)
        {
            velo001(1, 0, 0);
        }
        if(frame==1)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==769)
    {
        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==770)
    {
        if(frame==0)
        {
            velo001(2, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==771)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSheila");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                               }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vSheila", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==772)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if (frame == 0){

	  if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Sheila____Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Sheila____Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Sheila____Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Sheila____Level__5");}

	if (myVar==5){changeentityproperty(self, "name", "Sheila____Level__6");}

	if (myVar==6){changeentityproperty(self, "name", "Sheila____Level__7");}

	if (myVar==7){changeentityproperty(self, "name", "Sheila____Level__8");}

	if (myVar==8){changeentityproperty(self, "name", "Sheila____Level__9");}

	if (myVar==9){changeentityproperty(self, "name", "Sheila____Level__MAX");}

	  }else{

	    changeentityproperty(self, "name", "Sheila____Level__1");

	  }

	}

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

	        return;
    }
    if(animhandle==773)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==777)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if(frame==0){

	if (myVar == NULL()){changeentityproperty(self, "maxhealth", 240);}

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

	if(getentityproperty(self, "health")==0){

        changeentityproperty(self, "health", 240);

        }

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Sheilainv.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==781)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==785)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==786)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==787)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==788)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelSheila", 0, 70, 0);
        }
        return;
    }
    if(animhandle==790)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==792)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSheila");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vSheila", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==793)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSheila");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

	        return;
    }
    if(animhandle==794)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Presto.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==805)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==806)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelPresto", 0, 70, 0);
        }
        return;
    }
    if(animhandle==808)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==810)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelPresto", 0, 70, 0);
        }
        return;
    }
    if(animhandle==811)
    {
        if(frame==1)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==5)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==9)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        if(frame==13)
        {
            shoot("PrestoHyper", 10, 45, 1);
        }
        return;
    }
    if(animhandle==812)
    {


	if(frame==4)

	{

       	       int r = rand()%6;

       	       if(r==-5){shoot("PrestoTiroA3", 20, 15, 0);}

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

      	       if(r==5){shoot("PrestoTiro02", 15, 15, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==813)
    {


	if(frame==4)

	{

       	       int r = rand()%5;

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro04", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==814)
    {


	if(frame==4)

	{

       	       int r = rand()%5;

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiro04", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiroVerde", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiroVerde", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiro02", 15, 15, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==815)
    {


	if(frame==4)

	{

       	       int r = rand()%4;

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro05", 15, 0, 0);}

      	       if(r==1){shoot("PrestoTiroVerde", 10, 0, 0);}

 	       if(r==2){shoot("HolyTiro", 15, 20, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 0, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==816)
    {


	if(frame==3)

	{

       	       int r = rand()%5;

       	       if(r==-4){shoot("PrestoTiro01", 15, 25, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 20, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 20, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 20, 0);}

      	       if(r==0){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 5, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 5, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==4){shoot("PrestoTiro02", 15, 25, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==819)
    {


	if (frame == 0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if ((myVar==2)||(myVar==3)){

	performattack(self, openborconstant("ANI_freespecial10"));

   	}

	if ((myVar==4)||(myVar==5)){

	performattack(self, openborconstant("ANI_freespecial11"));

   	}

	if ((myVar==6) || (myVar==7)|| (myVar==8)){

	performattack(self, openborconstant("ANI_freespecial12"));

   	}

 	if (myVar>=9){

	performattack(self, openborconstant("ANI_freespecial13"));

   	}

        }

	if(frame==4)

	{

       	       int r = rand()%6;

       	       if(r==-5){shoot("PrestoTiroA3", 20, 15, 0);}

       	       if(r==-4){spawn01("PrestoTiroA1", 20, 6, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 15, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 15, 0);}

      	       if(r==0){shoot("PrestoTiro01", 15, 15, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 0, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==3){shoot("PrestoTiro03", 10, 0, 0);}

      	       if(r==4){shoot("PrestoTiroA2", 20, 0, 0);}

      	       if(r==5){}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==820)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

 	if (myVar>=9 && frame == 0){

	performattack(self, openborconstant("ANI_freespecial15"));

   	}

	if(frame==3)

	{

       	       int r = rand()%5;

       	       if(r==-4){shoot("PrestoTiroA3", 15, 25, 0);}

       	       if(r==-3){shoot("PrestoTiro01", 15, 20, 0);}

       	       if(r==-2){shoot("PrestoTiro01", 15, 20, 0);}

      	       if(r==-1){shoot("PrestoTiro02", 15, 20, 0);}

      	       if(r==0){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==1){shoot("PrestoTiro03", 10, 5, 0);}

 	       if(r==2){shoot("PrestoTiro03", 10, 5, 0);}

      	       if(r==3){shoot("PrestoTiro04", 10, 5, 0);}

      	       if(r==4){shoot("PrestoTiroA3", 15, 25, 0);}

               int SFX1 = loadsample("data/chars/player/magic1.wav");

	       int SFX2 = loadsample("data/chars/player/magic2.wav");

	       int SFX3 = loadsample("data/chars/player/magic3.wav");

       	       int s = rand()%2;

      	       if(s==-1){playsample(SFX1, 0, 120, 120, 100, 0);}

      	       if(s==0){playsample(SFX2, 0, 120, 120, 100, 0);}

      	       if(s==1){playsample(SFX3, 0, 120, 120, 100, 0);}

        }

	        return;
    }
    if(animhandle==821)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vPresto");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vPresto", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==822)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Presto__Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Presto__Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Presto__Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Presto__Level__5");}

	if (myVar==5){changeentityproperty(self, "name", "Presto__Level__6");}

	if (myVar==6){changeentityproperty(self, "name", "Presto__Level__7");}

	if (myVar==7){changeentityproperty(self, "name", "Presto__Level__8");}

	if (myVar==8){changeentityproperty(self, "name", "Presto__Level__9");}

	if (myVar==9){changeentityproperty(self, "name", "Presto__Level__MAX");}

	  }else{

	    changeentityproperty(self, "name", "Presto__Level__1");

	  }

	}

	        return;
    }
    if(animhandle==823)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==827)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vPresto");

	if(frame==0){

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Bobby.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==832)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==837)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vBobby");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==838)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==840)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==842)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==843)
    {
        if(frame==9)
        {
            spawn01("stomp", 35, 0, -1);
        }
        if(frame==10)
        {
            spawn01("stomp", 105, 0, -1);
        }
        if(frame==11)
        {
            spawn01("stomp", 175, 0, -1);
        }
        if(frame==12)
        {
            spawn01("stomp", 245, 0, -1);
        }
        return;
    }
    if(animhandle==850)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vBobby");

		if ((myVar==2)||(myVar==3)){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if ((myVar==4)||(myVar==5)){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

		if (myVar>=9){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

   	   	}

	        return;
    }
    if(animhandle==852)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vBobby");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vBobby", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==853)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vBobby");

	if (frame == 0){

	  if (myVar!=NULL()){

	  if (myVar==1){changeentityproperty(self, "name", "Bobby____Level__2");}

	  if (myVar==2){changeentityproperty(self, "name", "Bobby____Level__3");}

	  if (myVar==3){changeentityproperty(self, "name", "Bobby____Level__4");}

 	  if (myVar==4){changeentityproperty(self, "name", "Bobby____Level__5");}

	  if (myVar==5){changeentityproperty(self, "name", "Bobby____Level__6");}

	  if (myVar==6){changeentityproperty(self, "name", "Bobby____Level__7");}

	  if (myVar==7){changeentityproperty(self, "name", "Bobby____Level__8");}

 	  if (myVar==8){changeentityproperty(self, "name", "Bobby____Level__9");}

 	  if (myVar==9){changeentityproperty(self, "name", "Bobby____Level__MAX");}



	  }else{

	    changeentityproperty(self, "name", "Bobby____Level__1");

	  }

	}

	        return;
    }
    if(animhandle==854)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==858)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vBobby");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Eric.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==863)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==864)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==866)
    {
        if(frame==0)
        {
            velo001(-2, 0, 0);
        }
        return;
    }
    if(animhandle==867)
    {
        if(frame==0)
        {
            velo001(-3, 0, 0);
        }
        return;
    }
    if(animhandle==868)
    {
        if(frame==0)
        {
            velo001(-4, 0, 0);
        }
        return;
    }
    if(animhandle==869)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PrestoTiroVerde", 20, 10, 1);
        }
        return;
    }
    if(animhandle==870)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("FlechaEP", 20, 43, 1);
        }
        return;
    }
    if(animhandle==871)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PrestoTiro03", 20, 10, 1);
        }
        return;
    }
    if(animhandle==872)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("LancaEP", 20, 37, 1);
        }
        return;
    }
    if(animhandle==873)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PedraEP", 20, 37, 1);
        }
        return;
    }
    if(animhandle==874)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==0)
        {
            shoot("PrestoTiro01", 20, 35, 1);
        }
        return;
    }
    if(animhandle==877)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vEric");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==878)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==880)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==882)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==885)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==4)
        {
            velo001(1, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==887)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vEric");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vEric", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==888)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vEric");

	if (frame == 0){

	  if (myVar!=NULL()){

            if (myVar==1){

   	    changeentityproperty(self, "name", "Eric________Level__2");

	    }

            if (myVar==2){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.85, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.90, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.95, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__3");

	    }

            if (myVar==3){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.85, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.90, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.95, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__4");

	    }

            if (myVar==4){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.70, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.75, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.80, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__5");

	    }

            if (myVar==5){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.70, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.75, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.80, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__6");

	    }

            if (myVar==6){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__7");

	    }

            if (myVar==7){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__8");

	    }

            if (myVar==8){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__9");

	    }

            if (myVar>=9){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.45, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.50, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.55, 0, 1);

   	    changeentityproperty(self, "name", "Eric________Level__MAX");

	    }

	    }else{

	    changeentityproperty(self, "name", "Eric________Level__1");

	  }

	}

	        return;
    }
    if(animhandle==889)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==893)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vEric");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Diana.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==899)
    {
        if(frame==3)
        {
            velo001(2, 0, 0);
        }
        if(frame==6)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==903)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vDiana");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==904)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDiana", 0, 70, 0);
        }
        return;
    }
    if(animhandle==907)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==909)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDiana", 0, 70, 0);
        }
        return;
    }
    if(animhandle==910)
    {


    	if (frame==2){

    	       void self = getlocalvar("self");

               performattack(self, openborconstant("ANI_FOLLOW3"));

        }

	        return;
    }
    if(animhandle==913)
    {
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        if(frame==10)
        {
            keymove(1, 1);
        }
        if(frame==11)
        {
            keymove(1, 1);
        }
        if(frame==12)
        {
            keymove(1, 1);
        }
        if(frame==13)
        {
            keymove(1, 1);
        }
        if(frame==14)
        {
            keymove(1, 1);
        }
        if(frame==15)
        {
            keymove(1, 1);
        }
        if(frame==16)
        {
            keymove(1, 1);
        }
        if(frame==17)
        {
            keymove(1, 1);
        }
        if(frame==18)
        {
            keymove(1, 1);
        }
        if(frame==19)
        {
            keymove(1, 1);
        }
        if(frame==20)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==916)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vDiana");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vDiana", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==917)
    {


	void self = getlocalvar("self");

	float myVar = getglobalvar("vDiana");

	if (frame == 0){

	  if (myVar!=NULL()){

  	    if (myVar==1){

	    changeentityproperty(self, "speed", 1.7);

	    changeentityproperty(self, "name", "Diana_____Level__2");}

	    if (myVar==2){

	    changeentityproperty(self, "speed", 1.9);

	    changeentityproperty(self, "name", "Diana_____Level__3");}

	    if (myVar==3){

	    changeentityproperty(self, "speed", 1.9);

	    changeentityproperty(self, "name", "Diana_____Level__4");}

	    if (myVar==4){

	    changeentityproperty(self, "speed", 2.1);

	    changeentityproperty(self, "name", "Diana_____Level__5");}

	    if (myVar==5){

	    changeentityproperty(self, "speed", 2.1);

	    changeentityproperty(self, "name", "Diana_____Level__6");}

	    if (myVar==6){

	    changeentityproperty(self, "speed", 2.3);

	    changeentityproperty(self, "name", "Diana_____Level__7");}

	    if (myVar==7){

	    changeentityproperty(self, "speed", 2.3);

	    changeentityproperty(self, "name", "Diana_____Level__8");}

	    if (myVar==8){

	    changeentityproperty(self, "speed", 2.3);

	    changeentityproperty(self, "name", "Diana_____Level__9");}

	    if (myVar==9){

	    changeentityproperty(self, "speed", 2.5);

	    changeentityproperty(self, "name", "Diana_____Level__MAX");}

	  }else{

	    changeentityproperty(self, "speed", 1.7);

	    changeentityproperty(self, "name", "Diana_____Level__1");

	  }

	}

	        return;
    }
    if(animhandle==918)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==922)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vDiana");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/GolemLVL1.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==930)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/GolemLVL2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==938)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/GolemLVL3.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==946)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/GolemLVL4.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==954)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/Vinga/GolemLVL5.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==962)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }

}

#### animationscript function main #####
# data/chars/player/Venger.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==968)
    {
        if(frame==0)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==973)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==974)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelVinga", 0, 70, 0);
        }
        return;
    }
    if(animhandle==976)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==978)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelVinga", 0, 70, 0);
        }
        return;
    }
    if(animhandle==979)
    {


	if(frame==5){

		int myVar = getglobalvar("vVinga");

		if(myVar==NULL() || (myVar==1) ){

                 spawn01("GolemLVL1", 32, 0, 0);

               }

  		if((myVar==2)||(myVar==3)){

                 spawn01("GolemLVL2", 32, 0, 0);

               }

  		if((myVar==4)||(myVar==5)){

                 spawn01("GolemLVL3", 32, 0, 0);

               }

  		if((myVar==6) || (myVar==7)|| (myVar==8)){

                 spawn01("GolemLVL4", 32, 0, 0);

               }

  		if(myVar>=9){

                 spawn01("GolemLVL5", 32, 0, 0);

               }

        }

	        return;
    }
    if(animhandle==982)
    {


	if(frame==9){

                  shoot("VingaTiro1", 10, 31, 0);

        }

	        return;
    }
    if(animhandle==983)
    {


	if(frame==5){

                 shoot("VingaTiro1", 10, 20, 0);

        }

	        return;
    }
    if(animhandle==984)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vVinga");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vVinga", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==985)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Vingador_Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Vingador_Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Vingador_Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Vingador_Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Vingador_Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Vingador_Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Vingador_Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Vingador_Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Vingador_Level___MAX");}

	}else{

	changeentityproperty(self, "name", "Vingador_Level___1");

	}

	}

	        return;
    }
    if(animhandle==986)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==990)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/DM.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1003)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vMestre");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1004)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDM", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1006)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1008)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelDM", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1009)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vMestre");

     	        void mana = getentityproperty(self,"mp"); //get mp

         	if (myVar==NULL()){

		changeentityproperty(self, "mp", mana-20);

		}else{

  		if ((myVar==0)||(myVar==1)){

    		changeentityproperty(self, "mp", mana-20);

 	   	}

		if ((myVar==2)||(myVar==3)){

     		changeentityproperty(self, "mp", mana-15);

 	   	}

		if ((myVar==4)||(myVar==5)){

 		changeentityproperty(self, "mp", mana-10);

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

 		changeentityproperty(self, "mp", mana-5);

 	   	}

  		if (myVar>=9){

 		changeentityproperty(self, "mp", mana-1);

 	   	}

 	   	}

 	}

	        if(frame==4)
        {
            velo001(40, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1012)
    {


	if(frame==4){

                 shoot("VingaTiro1", 10, 11, 0);

        }

	        return;
    }
    if(animhandle==1013)
    {


	if(frame==4){

                 shoot("VingaTiro1", 10, 11, 0);

        }

	        return;
    }
    if(animhandle==1014)
    {
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        if(frame==10)
        {
            keymove(1, 1);
        }
        if(frame==11)
        {
            keymove(1, 1);
        }
        if(frame==12)
        {
            keymove(1, 1);
        }
        if(frame==13)
        {
            keymove(1, 1);
        }
        if(frame==14)
        {
            keymove(1, 1);
        }
        if(frame==15)
        {
            keymove(1, 1);
        }
        if(frame==16)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1015)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vMestre");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vMestre", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1016)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMestre");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Mestre___Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Mestre___Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Mestre___Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Mestre___Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Mestre___Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Mestre___Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Mestre___Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Mestre___Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Mestre___Level___MAX");}

	}else{

	changeentityproperty(self, "name", "Mestre___Level___1");

	}

	}

	        return;
    }
    if(animhandle==1017)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1022)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMestre");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Strongheart.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1027)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1032)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vStrong");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1033)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelStrong", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1035)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1037)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelStrong", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1038)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vStrong");

	if(frame == 8){

	if (myVar==NULL()||(myVar==1)){

         spawn01("cura1", 60, 33, 0);

   	}

	if ((myVar==2)||(myVar==3)){

         spawn01("cura2", 60, 33, 0);

   	}

	if ((myVar==4)||(myVar==5)){

         spawn01("cura3", 60, 1, 0);

   	}

	if ((myVar==6) || (myVar==7)|| (myVar==8)){

         spawn01("cura4", 60, 1, 0);

   	}

	if (myVar>=9){

         spawn01("cura5", 60, 1, 0);

   	}

   	}

	        return;
    }
    if(animhandle==1041)
    {
        if(frame==9)
        {
            shoot("HolyTiro", 37, 43, 1);
        }
        return;
    }
    if(animhandle==1043)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vStrong");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vStrong", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1044)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vStrong");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Strongheart_Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Strongheart_Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Strongheart_Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Strongheart_Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Strongheart_Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Strongheart_Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Strongheart_Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Strongheart_Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Strongheart_Level___MAX");}

	  }else{

	    changeentityproperty(self, "name", "Strongheart_Level___1");

	  }

	}

	        return;
    }
    if(animhandle==1045)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1050)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vStrong");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Rahmud.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1054)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1056)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==4)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1060)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vRahmud");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1061)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1063)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1065)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        if(frame==6)
        {
            velo001(4, 0, 0);
        }
        if(frame==9)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1066)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1067)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vRahmud");

	if(frame == 0){

	if (myVar==NULL()||(myVar==1)){

	performattack(self, openborconstant("ANI_freespecial11"));

   	}

	if ((myVar==2)||(myVar==3)){

	performattack(self, openborconstant("ANI_freespecial12"));

   	}

	if ((myVar==4)||(myVar==5)){

 	performattack(self, openborconstant("ANI_freespecial13"));

   	}

	if ((myVar==6) || (myVar==7)|| (myVar==8)){

	performattack(self, openborconstant("ANI_freespecial14"));

   	}

	if (myVar>=9){

	performattack(self, openborconstant("ANI_freespecial15"));

   	}

   	}

	        return;
    }
    if(animhandle==1068)
    {
        if(frame==6)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==1069)
    {
        if(frame==6)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==1070)
    {
        if(frame==6)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==1071)
    {
        if(frame==6)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro2", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro1", 43, 40, 1);
        }
        return;
    }
    if(animhandle==1072)
    {
        if(frame==6)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        if(frame==8)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        if(frame==10)
        {
            shoot("RahmudTiro3", 43, 40, 1);
        }
        return;
    }
    if(animhandle==1077)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vRahmud");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vRahmud", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1078)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vRahmud");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Rahmud___Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Rahmud___Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Rahmud___Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Rahmud___Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Rahmud___Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Rahmud___Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Rahmud___Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Rahmud___Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Rahmud___Level___MAX");}

	  }else{

	    changeentityproperty(self, "name", "Rahmud___Level___1");

	  }

	}

	        return;
    }
    if(animhandle==1079)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1084)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vRahmud");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Sir.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1094)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vSir");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1095)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1098)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1100)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelEric", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1101)
    {


	void self = getlocalvar("self");

	if(frame==0){

	changeentityproperty(self, "stealth", 20);

    	}

	if(frame==4){

    	void mana = getentityproperty(self,"mp"); //get mp

    	changeentityproperty(self, "mp", mana-3);//add mp

    	if (mana < 3){

        performattack(self, openborconstant("ANI_freespecial6"));

        }

    	}

	        return;
    }
    if(animhandle==1107)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vSir");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vSir", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1108)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSir");

	if(frame==0){

	changeentityproperty(self, "stealth", 0);

    	}

	if (frame == 0){

	  if (myVar!=NULL()){

            if (myVar==1){

   	    changeentityproperty(self, "name", "Sir._John______Level__2");

	    }

            if (myVar==2){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.85, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.90, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.95, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__3");

	    }

            if (myVar==3){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.85, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.90, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.95, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__4");

	    }

            if (myVar==4){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.70, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.75, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.80, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__5");

	    }

            if (myVar==5){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.70, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.75, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.80, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__6");

	    }

            if (myVar==6){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__7");

	    }

            if (myVar==7){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__8");

	    }

            if (myVar==8){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.55, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.60, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.65, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__9");

	    }

            if (myVar>=9){

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL"), 0.45, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL2"), 0.50, 0, 1);

	    changeentityproperty(self, "defense", openborconstant("ATK_NORMAL3"), 0.55, 0, 1);

   	    changeentityproperty(self, "name", "Sir._John______Level__MAX");

	    }

	    }else{

	    changeentityproperty(self, "name", "Sir._John______Level__1");

	  }

	}

	        return;
    }
    if(animhandle==1109)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1114)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vSir");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Bruenor.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1119)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==2)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1120)
    {


	if (frame == 0){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vMiner");

		if ((myVar==2)||(myVar==3)){

		performattack(self, openborconstant("ANI_follow11"));

 	   	}

		if ((myVar==4)||(myVar==5)){

		performattack(self, openborconstant("ANI_follow12"));

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

		performattack(self, openborconstant("ANI_follow13"));

 	   	}

  		if (myVar>=9){

		performattack(self, openborconstant("ANI_follow14"));

 	   	}

 	}

	        return;
    }
    if(animhandle==1124)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vMiner");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1126)
    {
        if(frame==1)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1127)
    {
        if(frame==1)
        {
            velo001(2, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1128)
    {
        if(frame==1)
        {
            velo001(3, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1129)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1131)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1133)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelBobby", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1134)
    {
        if(frame==4)
        {
            spawn01("Mina", 2, 0, 1);
        }
        return;
    }
    if(animhandle==1137)
    {
        if(frame==6)
        {
            toss("MinerTiro", 15, 35, 1);
        }
        return;
    }
    if(animhandle==1139)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vMiner");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vMiner", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1140)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMiner");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Bruenor__Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Bruenor__Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Bruenor__Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Bruenor__Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Bruenor__Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Bruenor__Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Bruenor__Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Bruenor__Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Bruenor__Level___MAX");}

	}else{

	changeentityproperty(self, "name", "Bruenor__Level___1");

	}

	}

	        return;
    }
    if(animhandle==1141)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1146)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vMiner");

	if(frame==0){

	 if(myVar >= 9){

	  changeentityproperty(self, "maxhealth", 480);

         }else{

          changeentityproperty(self, "maxhealth", 240 + 25*myVar);

         }

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Warduke.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1152)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if ((myVar>=4) && frame == 0){

	performattack(self, openborconstant("ANI_follow3"));

   	}

	        return;
    }
    if(animhandle==1154)
    {
        if(frame==0)
        {
            velo001(-1, 0, 0);
        }
        return;
    }
    if(animhandle==1157)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1158)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1161)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1163)
    {
        if(frame==3)
        {
            velo001(4, 0, 0);
        }
        if(frame==10)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1164)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelWarduke", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1166)
    {
        if(frame==9)
        {
            shoot("PrestoTiro02", 60, 30, 1);
        }
        return;
    }
    if(animhandle==1167)
    {
        if(frame==9)
        {
            shoot("PrestoTiro04", 65, 6, 1);
        }
        return;
    }
    if(animhandle==1168)
    {
        if(frame==9)
        {
            shoot("WardukeTiro", 60, 22, 1);
        }
        return;
    }
    if(animhandle==1169)
    {
        if(frame==9)
        {
            shoot("PrestoHyper", 60, 30, 1);
        }
        return;
    }
    if(animhandle==1172)
    {


	if (frame == 0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if ((myVar==2)||(myVar==3)){

	performattack(self, openborconstant("ANI_freespecial10"));

   	}

	if ((myVar==4)||(myVar==5)){

	performattack(self, openborconstant("ANI_freespecial11"));

   	}

	if ((myVar==6) || (myVar==7)|| (myVar==8)){

	performattack(self, openborconstant("ANI_freespecial12"));

   	}

 	if (myVar>=9){

	performattack(self, openborconstant("ANI_freespecial13"));

   	}

    	}

	        if(frame==9)
        {
            shoot("PrestoTiro01", 60, 30, 1);
        }
        return;
    }
    if(animhandle==1173)
    {


	void self = getlocalvar("self");

	if (frame <= 1 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial9"));

	}

	if (frame == 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial8"));

	}

	if (frame > 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_jumpland"));

	}

	        return;
    }
    if(animhandle==1174)
    {


	void self = getlocalvar("self");

	if (frame <= 1 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial9"));

	}

	if (frame == 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_freespecial8"));

	}

	if (frame > 3 && getentityproperty(self, "y")==0){

           performattack(self, openborconstant("ANI_jumpland"));

	}

	        return;
    }
    if(animhandle==1177)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vWarduke");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vWarduke", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1178)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if (frame == 0){

	if (myVar!=NULL()){

     	changeentityproperty(self, "map", myVar);

	if (myVar==1){changeentityproperty(self, "name", "Warduke__Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Warduke__Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Warduke__Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Warduke__Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Warduke__Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Warduke__Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Warduke__Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Warduke__Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Warduke__Level___MAX");}

	  }else{

	    changeentityproperty(self, "map", 0);

	    changeentityproperty(self, "name", "Warduke__Level___1");

	  }

	}

	        return;
    }
    if(animhandle==1179)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1183)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vWarduke");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Kelek.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1192)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vKelek");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1193)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelKelek", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1195)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1197)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelKelek", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1198)
    {


	int myVar = getglobalvar("vKelek");

	if (frame == 2){

		spawn01("raioK", 80, 0 ,0);

	}



	if (frame == 4){

		if (myVar>=2){

		spawn01("raioK", 115, 0 ,0);

 	   	}

        }

 	if (frame == 6){

		if (myVar>=4){

		spawn01("raioK", 150, 0 ,0);

 	   	}

 	}

 	if (frame == 8){

		if (myVar>=6){

		spawn01("raioK", 185, 0 ,0);

 	   	}

	}

	if (frame == 10){

  		if (myVar>=9){

		spawn01("raioK", 210, 0 ,0);

 	   	}

	}

	        return;
    }
    if(animhandle==1201)
    {
        if(frame==4)
        {
            shoot("PrestoTiro01", 50, 40, 1);
        }
        return;
    }
    if(animhandle==1202)
    {
        if(frame==4)
        {
            shoot("PrestoTiro01", 50, 33, 1);
        }
        return;
    }
    if(animhandle==1203)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vKelek");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vKelek", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1204)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vKelek");

	if (frame == 0){

	  if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Kelek______Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Kelek______Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Kelek______Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Kelek______Level__5");}

	if (myVar==5){changeentityproperty(self, "name", "Kelek______Level__6");}

	if (myVar==6){changeentityproperty(self, "name", "Kelek______Level__7");}

	if (myVar==7){changeentityproperty(self, "name", "Kelek______Level__8");}

	if (myVar==8){changeentityproperty(self, "name", "Kelek______Level__9");}

	if (myVar==9){changeentityproperty(self, "name", "Kelek______Level__MAX");}

	  }else{

	    changeentityproperty(self, "name", "Kelek______Level__1");

	  }

	}

	        return;
    }
    if(animhandle==1205)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1209)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vKelek");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/lolth.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1219)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vLolth");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1220)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelLolth", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1223)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1225)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelLolth", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1226)
    {


	if (frame == 5){

		void self = getlocalvar("self");

		int myVar = getglobalvar("vLolth");

		if ((myVar==2)||(myVar==3)){

		performattack(self, openborconstant("ANI_freespecial10"));

 	   	}

		if ((myVar==4)||(myVar==5)){

		performattack(self, openborconstant("ANI_freespecial11"));

 	   	}

		if ((myVar==6) || (myVar==7)|| (myVar==8)){

		performattack(self, openborconstant("ANI_freespecial12"));

 	   	}

  		if (myVar>=9){

		performattack(self, openborconstant("ANI_freespecial13"));

 	   	}

                performattack(self, openborconstant("ANI_FOLLOW3"));



 	}

	        return;
    }
    if(animhandle==1231)
    {


 	        void self = getlocalvar("self");

		if(frame==5){

               	  performattack(self, openborconstant("ANI_freespecial20"));

               }

	        if(frame==5)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1233)
    {
        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1235)
    {


 	        void self = getlocalvar("self");

		if(frame==4){

               	  performattack(self, openborconstant("ANI_freespecial20"));

               }

	        if(frame==0)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1240)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vLolth");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vLolth", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1241)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vLolth");

	if (frame == 0){

	  if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Lolth______Level__2");}

	if (myVar==2){changeentityproperty(self, "name", "Lolth______Level__3");}

	if (myVar==3){changeentityproperty(self, "name", "Lolth______Level__4");}

	if (myVar==4){changeentityproperty(self, "name", "Lolth______Level__5");}

	if (myVar==5){changeentityproperty(self, "name", "Lolth______Level__6");}

	if (myVar==6){changeentityproperty(self, "name", "Lolth______Level__7");}

	if (myVar==7){changeentityproperty(self, "name", "Lolth______Level__8");}

	if (myVar==8){changeentityproperty(self, "name", "Lolth______Level__9");}

	if (myVar==9){changeentityproperty(self, "name", "Lolth______Level__MAX");}

	  }else{

	    changeentityproperty(self, "name", "Lolth______Level__1");

	  }

	}

	        return;
    }
    if(animhandle==1242)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1246)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vLolth");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}

#### animationscript function main #####
# data/chars/player/Venger2.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animhandle = getlocalvar("animhandle");
    if(animhandle==1252)
    {
        if(frame==0)
        {
            velo001(1, 0, 0);
        }
        if(frame==3)
        {
            velo001(0, 0, 0);
        }
        return;
    }
    if(animhandle==1257)
    {


	if(frame==0){

	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga2");

	if (myVar == 1){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar == 8){changeentityproperty(self, "maxhealth", 360);}

        changeentityproperty(self, "health", 500);

        }

	        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelMiner", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1258)
    {
        if(frame==0)
        {
            spawnbind("levelMax", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelVinga", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1260)
    {
        if(frame==0)
        {
            spawn01("levelMap", 20, 70, 0);
        }
        return;
    }
    if(animhandle==1262)
    {
        if(frame==0)
        {
            spawnbind("levelUP", 0, 85, 0);
        }
        if(frame==0)
        {
            spawnbind("levelVinga", 0, 70, 0);
        }
        return;
    }
    if(animhandle==1263)
    {


	if(frame==5){

		int myVar = getglobalvar("vVinga2");

		if(myVar==NULL() || (myVar==1) ){

                 spawn01("cavLVL1", 32, 0, 0);

               }

  		if((myVar==2)||(myVar==3)){

                 spawn01("cavLVL2", 32, 0, 0);

               }

  		if((myVar==4)||(myVar==5)){

                 spawn01("cavLVL3", 32, 0, 0);

               }

  		if((myVar==6) || (myVar==7)|| (myVar==8)){

                 spawn01("cavLVL1", 32, 0, 0);

                 spawn01("cavLVL1", -32, 0, 0);

               }

  		if(myVar>=9){

                 spawn01("cavLVL2", 62, 0, 0);

                 spawn01("cavLVL4", 32, 0, 0);

                 spawn01("cavLVL2", -32, 0, 0);

               }

        }

	        return;
    }
    if(animhandle==1266)
    {


	if(frame==9){

                 shoot("VingaTiro2", 0, 11, 0);

        }

	        return;
    }
    if(animhandle==1267)
    {


	if(frame==5){

                 shoot("VingaTiro2", 0, 11, 0);

        }

	        return;
    }
    if(animhandle==1268)
    {
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        if(frame==10)
        {
            keymove(1, 1);
        }
        if(frame==11)
        {
            keymove(1, 1);
        }
        if(frame==12)
        {
            keymove(1, 1);
        }
        if(frame==13)
        {
            keymove(1, 1);
        }
        if(frame==14)
        {
            keymove(1, 1);
        }
        if(frame==15)
        {
            keymove(1, 1);
        }
        if(frame==16)
        {
            keymove(1, 1);
        }
        if(frame==17)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1269)
    {


		void self = getlocalvar("self");

		int myVar = getglobalvar("vVinga2");

  		int myMap = getglobalvar("vMap");

        	if(frame==1 && openborvariant("current_branch")=="mapa"){

                if (myMap==NULL()){ myMap = 0;}

	        setglobalvar("vMap", myMap + 1);

                performattack(self, openborconstant("ANI_FOLLOW5"));

                }

                if (myVar==NULL()){ myVar = 0;}

  		if (frame == 1 && myVar<9){

		  setglobalvar("vVinga2", myVar + 1);

  		   if (myVar==8){

                  performattack(self, openborconstant("ANI_FOLLOW2"));

                  }else{

		    if (myVar==0 || myVar==2 || myVar==4 || myVar==6 || myVar==7){

                      performattack(self, openborconstant("ANI_FOLLOW1"));

                  }else {

                      performattack(self, openborconstant("ANI_FOLLOW9"));

		  }

                  }

                }

	        return;
    }
    if(animhandle==1270)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga2");

	if (frame == 0){

	if (myVar!=NULL()){

	if (myVar==1){changeentityproperty(self, "name", "Vingador_Level___2");}

	if (myVar==2){changeentityproperty(self, "name", "Vingador_Level___3");}

	if (myVar==3){changeentityproperty(self, "name", "Vingador_Level___4");}

	if (myVar==4){changeentityproperty(self, "name", "Vingador_Level___5");}

	if (myVar==5){changeentityproperty(self, "name", "Vingador_Level___6");}

	if (myVar==6){changeentityproperty(self, "name", "Vingador_Level___7");}

	if (myVar==7){changeentityproperty(self, "name", "Vingador_Level___8");}

	if (myVar==8){changeentityproperty(self, "name", "Vingador_Level___9");}

	if (myVar==9){changeentityproperty(self, "name", "Vingador_Level___MAX");}

	}else{

	changeentityproperty(self, "name", "Vingador_Level___1");

	}

	}

	        return;
    }
    if(animhandle==1271)
    {
        if(frame==0)
        {
            keymove(1, 1);
        }
        if(frame==1)
        {
            keymove(1, 1);
        }
        if(frame==2)
        {
            keymove(1, 1);
        }
        if(frame==3)
        {
            keymove(1, 1);
        }
        if(frame==4)
        {
            keymove(1, 1);
        }
        if(frame==5)
        {
            keymove(1, 1);
        }
        if(frame==6)
        {
            keymove(1, 1);
        }
        if(frame==7)
        {
            keymove(1, 1);
        }
        if(frame==8)
        {
            keymove(1, 1);
        }
        if(frame==9)
        {
            keymove(1, 1);
        }
        return;
    }
    if(animhandle==1275)
    {


	void self = getlocalvar("self");

	int myVar = getglobalvar("vVinga2");

	if(frame==0){

	if (myVar == 1 || myVar == 2){changeentityproperty(self, "maxhealth", 260);}

  	if (myVar == 3 || myVar == 4){changeentityproperty(self, "maxhealth", 280);}

  	if (myVar == 5 || myVar == 6){changeentityproperty(self, "maxhealth", 300);}

  	if (myVar == 7){changeentityproperty(self, "maxhealth", 320);}

  	if (myVar >= 8){changeentityproperty(self, "maxhealth", 360);}

        }

       	if(frame==0 && openborvariant("current_branch")=="dorme"){

        performattack(self, openborconstant("ANI_FOLLOW4"));

        }

       	if(frame==0 && openborvariant("current_branch")=="final"){

        performattack(self, openborconstant("ANI_FOLLOW6"));

        }

	        return;
    }

}
