Moving the camera
#1

I tried moving my camera on login, so it kind of moves forward but it didn't work quite how I wanted it to :P
I tried to do it with GetPlayerCameraPos and then SetPlayerCameraPos, has anybody got any other way to do it?
Reply
#2

You are using a timer, correct?
Reply
#3

Correct
Oh and it goes every 500 milliseconds.
Reply
#4

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

I use 50 mili seconds one time for each player when it stops i kill timer so its not using to much CPU
Reply
#5

It still won't work, that's the code I used:
PHP код:
forward CameraMovement(playerid);
public 
CameraMovement(playerid)
{
    if(
LoginDialog[playerid])
    {
        new 
Float:p[3];
        
GetPlayerCameraPos(playerid,p[0],p[1],p[2]);
        
SetPlayerCameraPos(playerid,p[0],p[1]+1,p[2]);
        print(
"Camera moved");
        
movetimer[playerid] = SetTimerEx("CameraMovement",50,false,"i",playerid);
        return 
1;
    }
    return 
1;

OnPlayerRequestClass:
PHP код:
    movetimer[playerid] = SetTimerEx("CameraMovement",50,false,"i",playerid); 
Reply
#6

Help, anyone?
Reply
#7

Did it by myself :P
Thanks to everyone who tried helping!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)