So, you want to control some actor through other actor???
1. This is to control 1 of hundreds cloned actor
-) make 2 integer global variables "PosX" and "PosY"
-) Controlled Actor -> Draw Actor
- Code: Select all
if(cloneindex==3) //or which cloneindex do you want
{
x=PosX;
y=PosY;
}
-) Controller Actor -> Keydown
- Code: Select all
PosX+=3;
//or
PosY+=3;
//or any moving code do you want
2. This is to control any cloned actor
-) make 2 integer global arrays "PosX[99]" and "PosY[99]" -> change 99 to the total clones do you have
-) Controlled Actor -> Draw Actor
- Code: Select all
x=PosX[cloneindex];
y=PosY[cloneindex];
-) Controller Actor -> Keydown
- Code: Select all
PosX[3]+=5;
//or
PosY[3]-=5;
//or any moving code do you want
//change 3 to the cloneindex you want to move