Move Object instantly - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Move Object instantly (
/showthread.php?tid=551892)
Move Object instantly -
cyberlord - 21.12.2014
Hello i facing problem with move object , for real i dont want to move i want to rotate everything works fine excepts speed i set speed to 0.0001 but it still do it instantly no animation the object i want to rotate is barrierturn hare is my code :
Code:
else if(IsPlayerInRangeOfPoint(playerid, 2.0,49.4500000,-1534.1100000,5.0000000))//Pasienis 1 uztvara
{
if(Used[playerid] == 0)
{
MoveDynamicObject(Uztvara[0],49.4500000,-1534.1100000,5.0000000,0.0001,0.0,0.0,84.5000000);
SendClientMessage(playerid, 0xFFFFFFFF, "Uztvara atidaryta!"); //open
Used[playerid] = 1;
return 1;
}
if(Used[playerid] == 1)
{
MoveDynamicObject(Uztvara[0],49.4500000,-1534.1100000,5.0000000,0.0001,0.0000000,270.0000000,84.5000000);
SendClientMessage(playerid, 0xFFFFFFFF, "Uztvara uzdaryta!"); //close
Used[playerid] = 0;
return 1;
}
}
Re: Move Object instantly -
ChristolisTV - 25.07.2015
I think the problem is with speed...
PHP Code:
else if(IsPlayerInRangeOfPoint(playerid, 2.0,49.4500000,-1534.1100000,5.0000000))//Pasienis 1 uztvara
{
if(Used[playerid] == 0)
{
MoveDynamicObject(Uztvara[0],49.4500000,-1534.1100000,5.0000000,1,0.0,0.0,84.5000000);
SendClientMessage(playerid, 0xFFFFFFFF, "Uztvara atidaryta!"); //open
Used[playerid] = 1;
return 1;
}
if(Used[playerid] == 1)
{
MoveDynamicObject(Uztvara[0],49.4500000,-1534.1100000,5.0000000,1,0.0000000,270.0000000,84.5000000);
SendClientMessage(playerid, 0xFFFFFFFF, "Uztvara uzdaryta!"); //close
Used[playerid] = 0;
return 1;
}
}
Re: Move Object instantly -
Vince - 25.07.2015
The object still needs to be actually
moved. Only adjusting the rotation does not work. Move up/down by 0.01 or something. I would also recommend storing the coordinates in a constant variable or something so you don't have to copy a set of coordinates 4 times.