{
void run()
{
ffc circle=Screen->LoadFFC(1);
int radius;
while(true)
{
Screen->Circle(5,40,40,radius,3,1,0,0,0,true,128);
radius++;
Waitframe();
}
}
}
Ohh a growing circle.
{
void run()
{
ffc blackout=Screen->LoadFFC(1);
while(true)
{
Screen->Rectangle(5,0,0,256,176,0,1,0,0,0,true,128);
Screen->Circle(5,Link->X,Link->Y,32,3,1,0,0,0,false,64);
Waitframe();
}
}
}
It makes the screen goes black then draw a circle at Link's position... I wished that I could make the screen visible only within the circle... Anyone can help?
{
void run(int v)
{
ffc guy=Screen->LoadFFC(1);
while(true)
{
int x=this->X;int y=this->Y;
if (Link->InputLeft==true)
{
this->Vx=v;
if (x>=240)
{
this->Vx=0;
this->X=240;
}
if (Link->InputUp==true)
{
this->Vy=v;
}
if (Link->InputDown==true)
{
this->Vy=v*-1;
}
if ((Link->InputDown==true)&&(Link->InputUp==true))
{
this->Vy=0;
}
if ((Link->InputUp==false)||(Link->InputDown==false))
{
this->Vy=0;
}
}
if (Link->InputRight==true)
{
this->Vx=v*-1;
if (x<=0)
{
this->Vx=0;
this->X=0;
}
if (Link->InputUp==true)
{
this->Vy=v;
}
if (Link->InputDown==true)
{
this->Vy=v*-1;
}
if ((Link->InputDown==true)&&(Link->InputUp==true))
{
this->Vy=0;
}
if ((Link->InputUp==false)||(Link->InputDown==false))
{
this->Vy=0;
}
}
if (Link->InputDown==true)
{
this->Vy=v*-1;
if (y<=0)
{
this->Vy=0;
this->Y=0;
}
if (Link->InputLeft==true)
{
this->Vx=v;
}
if (Link->InputRight==true)
{
this->Vx=v*-1;
}
if ((Link->InputLeft==false)&&(Link->InputRight==false))
{
this->Vx=0;
}
if ((Link->InputLeft==false)||(Link->InputRight==false))
{
this->Vx=0;
}
}
if (Link->InputUp==true)
{
this->Vy=1;
if (y>=160)
{
this->Vy=0;
this->Y=160;
}
if (Link->InputLeft==true)
{
this->Vx=v;
}
if (Link->InputRight==true)
{
this->Vx=v*-1;
}
if ((Link->InputLeft==false)&&(Link->InputRight==false))
{
this->Vx=0;
}
if ((Link->InputLeft==false)||(Link->InputRight==false))
{
this->Vx=0;
}
}
if ((Link->Action==0)||(Link->Action==2))
{
this->Vx=0;
this->Vy=0;
}
if (x<=0)
{
this->X=0;
}
if (x>=240)
{
this->X=240;
}
if (y<=0)
{
this->Y=0;
}
if (y>=240)
{
this->Y=240;
}
if ((Link->InputRight==true)&&(Link->InputLeft==true))
{
this->Vx=0;
}
if ((Link->InputDown==true)&&(Link->InputUp==true))
{
this->Vy=0;
}
Waitframe();
}
}
}
Well, that script could be shorter... Anyway, what it does is making the ffc moving when Link moves. And stops when Link stops or attacks. Also I've made him stop when he reaches the border of the screen. But I wanted it to move in diagonal when Link moves in diagonal... Right now it just moves in the four directions up left down and right...
Edited by lucas92, 24 October 2008 - 10:11 PM.