AttachCameraToDynamicObject bugs/glitches
#1

Hello there, I have some problems here
So, when I am trying to set player's camera attached to an object while he's(the object) is moving, the camera stuck(dosn't move, while the object yes( I think so )).
My code looks like this:
PHP код:
SnowObject[playerid] = CreateDynamicObject(18864coordsfrom[0], coordsfrom[1], coordsfrom[2], 000);
AttachCameraToDynamicObject(playeridSnowObject[playerid]);
MoveDynamicObject(SnowObject[playerid], coordsto[0], coordsto[1], coordsto[2], 19); 
What is wrong with my code?
Can someone testing this function/find out what the problem is?
Thank y'all in advance!
Reply
#2

Код:
AttachCameraToDynamicObject(playerid, SnowObject[playerid]); 
MoveDynamicObject(playerid, SnowObject[playerid], coordsto[0], coordsto[1], coordsto[2], 19);
Swap these two to become...
Код:
MoveDynamicObject(playerid, SnowObject[playerid], coordsto[0], coordsto[1], coordsto[2], 19);  
AttachCameraToDynamicObject(playerid, SnowObject[playerid]);
Reply
#3

Quote:
Originally Posted by Infin1ty
Посмотреть сообщение
Код:
AttachCameraToDynamicObject(playerid, SnowObject[playerid]); 
MoveDynamicObject(playerid, SnowObject[playerid], coordsto[0], coordsto[1], coordsto[2], 19);
Swap these two to become...
Код:
MoveDynamicObject(playerid, SnowObject[playerid], coordsto[0], coordsto[1], coordsto[2], 19);  
AttachCameraToDynamicObject(playerid, SnowObject[playerid]);
I already tried this(before to post this)...but doesn't worked...
Any other solution?
Reply
#4

I tried with normal samp objects functions and work, but with Incognito's streamer...does not work
why?
Reply
#5

Sounds like it could be a streaming issue. Is the object streamed in when you attach the camera to it? Or are you far away from the object when you attach the camera?

I found this conversation from a few years back that explain this issue and some methods to tackle it:
https://github.com/samp-incognito/sa...ugin/issues/49
Reply
#6

Quote:
Originally Posted by Threshold
Посмотреть сообщение
Sounds like it could be a streaming issue. Is the object streamed in when you attach the camera to it? Or are you far away from the object when you attach the camera?

I found this conversation from a few years back that explain this issue and some methods to tackle it:
https://github.com/samp-incognito/sa...ugin/issues/49
Oh, thanks, I found out how to resolve this problem(setting the stream distance to a negative number).
+rep
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)