scaryface87 Posted June 27, 2015 Share Posted June 27, 2015 Hello , Im trying to make my view look at a chair. What i've tried ; chair = createObject(1671,0,0,0) function changemyview(thePlayer) setCameraTarget(thePlayer,chair) end So i wanna know how im able to get an camera attached on the chair (the chair is moveable so it should update if its moving) Link to comment
tuaos Posted June 27, 2015 Share Posted June 27, 2015 Hello ,Im trying to make my view look at a chair. What i've tried ; chair = createObject(1671,0,0,0) function changemyview(thePlayer) setCameraTarget(thePlayer,chair) end So i wanna know how im able to get an camera attached on the chair (the chair is moveable so it should update if its moving) local cam = getCameraTarget() attachElements( cam, chair ) Link to comment
scaryface87 Posted June 29, 2015 Author Share Posted June 29, 2015 Hello ,Im trying to make my view look at a chair. What i've tried ; chair = createObject(1671,0,0,0) function changemyview(thePlayer) setCameraTarget(thePlayer,chair) end So i wanna know how im able to get an camera attached on the chair (the chair is moveable so it should update if its moving) local cam = getCameraTarget() attachElements( cam, chair ) Hello , Its not working first i had error from local cam = getCameraTarget() , it needed an argument so i wrote "getCameraTarget(thePlayer) but then it does nothing. Link to comment
scaryface87 Posted June 29, 2015 Author Share Posted June 29, 2015 chair = createObject(1671,0,0,0) function changemyview(thePlayer) local cam = getCameraTarget() attachElements( cam, chair,0,0,10 ) end Link to comment
tuaos Posted June 29, 2015 Share Posted June 29, 2015 chair = createObject(1671,0,0,0) function changemyview(thePlayer) local cam = getCameraTarget() attachElements( cam, chair,0,0,10 ) end local chair = createObject(1671,0,0,0) local cam = getCamera() function changemyview() attachElements( cam, chair, 0, 0, 10 ) end But look if it is moving and change the position arguments of attachElements, and if not working work this on smoothMoveCamera Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now