MoveObject Disasemble
#1

Objects going to the same spot, but not staying together can someone help me please?

I Need it to stay together plz



pawn Код:
#include <a_samp>

new NB[8];

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

public OnGameModeInit()
{
    NB[0] = CreateObject(10771, 2969.09, 472.10, 5.87,   0.00, 0.00, 0.00);
    NB[1] = CreateObject(11145, 2906.09, 472.10, 4.87,   0.00, 0.00, 0.00);
    NB[2] = CreateObject(11149, 2963.00, 466.90, 12.40,   0.00, 0.00, 0.00);
    NB[3] = CreateObject(11146, 2960.20, 472.60, 12.74,   0.00, 0.00, 0.00);
    NB[4] = CreateObject(10770, 2972.20, 464.50, 39.07,   0.00, 0.00, 0.00);
    NB[5] = CreateObject(10772, 2970.35, 472.10, 17.67,   0.00, 0.00, 0.00);
    NB[6] = CreateObject(3115, 2870.25, 472.10, 17.36,   0.00, 0.00, 0.00);
    NB[7] = CreateObject(11237, 2976.33, 464.21, 31.57,   0.00, 0.00, 0.00);
    SetTimer("Navy",1,false);
    return 1;
}

public OnGameModeExit()
{
    return 1;
}

forward Navy();
forward Navy1();
forward Navy2();

public Navy()
{
 for(new i=0; i<8; i++)
 {
  new Float:x, Float:y, Float:z;
  new Float:RotX,Float:RotY,Float:RotZ;
  GetObjectRot(NB[i], RotX, RotY, RotZ);
  GetObjectPos(NB[i], x, y, z);
  MoveObject(NB[i],x+231,y,z,2.0,0,0,20,300 );
  SetTimer("Navy1", 60000,false);
 }
 return 1;
}

public Navy1()
{
 for(new i=0; i<8; i++)
 {
  new Float:x, Float:y, Float:z;
  new Float:RotX,Float:RotY,Float:RotZ;
  GetObjectRot(NB[i], RotX, RotY, RotZ);
  GetObjectPos(NB[i], x, y, z);
  MoveObject(NB[i],x+331,y+128,z,2.0,0,0,50,300 );
 }
 return 1;
}
Reply
#2

You're moving 1 piece at a time, try moving them all at the same time.
Reply
#3

all iz moving at once lmfao didnt u read it they are moving but not together, read the code or can u adjust im just trying some crazy thing hoping it works :/
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)