Aim Training system. Need help rep +
#2

How would I do this... I create an array with all coordinates of points the object can go to.
Код:
new Float:TrainingObjectMoving[7][3] = {
{1441.1388,1348.8584,10.8130},
{1438.1956,1359.2809,10.8203},
...
{1437.0270,1371.0566,10.8203}
};
Also, when u create an object u should assing it's id to some sort of variable:
Код:
new TrainingObject[MAX_PLAYERS];//to ur global variables
And change
Код:
CreatePlayerObject(playerid,2056,-5.9348,1556.2980,12.75000, 0.00000, 0.00000, 90.00000);
Into
Код:
TrainingObject[playerid] =CreatePlayerObject(playerid,2056,-5.9348,1556.2980,12.75000, 0.00000, 0.00000, 90.00000);
Then, on player enter training area, rand a number to get the first coordinates to move to, course AFTER u create an object itself...
Код:
new rpos = rand(7);
MovePlayerObect(playerid,TrainingObject[playerid],TrainingObjectMoving[rpos][0],
TrainingObjectMoving[rpos][1],TrainingObjectMoving[rpos][2], 1.0/*this is the speed value, u might want to edit it!*/);
U copy and paste this one into OnPlayerWeaponShot and OnPlayerObjectMoved.
It is still a pretty rought idea of what u should do, but I should have left something for u to figure out urself, othervise u would just copy it, and didn't develop form it.
Good luck!
Reply


Messages In This Thread
Aim Training system. Need help rep + - by Beasthian - 19.03.2016, 00:47
Re: Aim Training system. Need help rep + - by SamJust - 19.03.2016, 04:08
Re: Aim Training system. Need help rep + - by Beasthian - 27.03.2016, 04:06

Forum Jump:


Users browsing this thread: 3 Guest(s)