AttachCameraToObject flickering
#1

Alright, I posted this before but got ZERO responses, please try to help me out.

I recently made this script:

[ame]http://www.youtube.com/watch?v=C_0FZK4fJWo[/ame]


This is on my testserver, which uses the exact same gamemode as my main server.

However, on my main server it looks like this:

[ame]http://www.youtube.com/watch?v=Vz9WPmZM33c[/ame]




I did a few tests and it even flickers with the following code:

Код:
CMD:fpstest(playerid, params[])
{
	new object1 =  CreateObject(19300, 0, 0, 0, 0.0, 0.0, 0);
	AttachCameraToObject(playerid, object1);
	return 1;
}
What could be causing this? Because I promised my players the FPS script I made, but so far all they have is a buggy version of it

Any help is appreciated.

Milan
Reply
#2

I'm having the same issue with AttachCameraToObject on my server.
Reply
#3

anyone?
Reply
#4

Could be a SA-MP bug.
Reply
#5

This happens only in that particular location or around the map?
Reply
#6

Quote:
Originally Posted by Viniborn
Посмотреть сообщение
This happens only in that particular location or around the map?
all around the map
Reply
#7

maybe the camera speed is relevant to this. you all know the too-fast-vehicle glitch, its the same HOM-effect. caused by really quick movements - since you create the object at blueberry acres (0,0,0), and then attach the camera to the object, it (the camera) will warp to the object, causing none of the new surrounding shit is loaded/cant be displayed, this could explain the same glitch when travelling >5000 km/h
ok, i suggest you to first teleport yourself to 0,0,10, and use the same command then. if its not bugging out, then its the camera speed. in this case, createobject is fine, then attach the object to the player (invisible object, but use any visible for now), THEN attch the camera to the (already attached-to-player) object..
now a few questions which came into my mind: did you make sure that each players camera is a per-player variable? same with the object1? does it work the very first time after the server got startet up?
Reply
#8

Yes, I have my objects called "pizza[playerid]".
Pizza because I was eating pizza, but that's irrelevant.

I have per player objects,but they are created at OnGamemodeEnit for the first 50 players, as my server is 50 players max.

At the command /fps it attaches the pizza[playerid] to the player, and on Disconnect and/or /fpsoff it deattaches it.

Will try teleporting to 0.0.10

EDIT:

still flickering,
Reply
#9

Bump after 2 days
Reply
#10

PHP код:
if (!strcmp("/fps"cmdtexttrue))
    {
        new 
realcam[playerid] = CreateObject(186850.00.00.00.00.00.00.0);
        
AttachObjectToPlayer(realcam[playerid], playerid0.00.20.680.00.00.0);
        
AttachCameraToObject(playeridrealcam[playerid]);
        return 
1;
    } 
On my server it perfectly works
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)