moadi Posted April 20, 2019 Posted April 20, 2019 (edited) Hey everyone I've been trying to convert a gamemode I've coded a long while ago from GTA:N to RAGE:MP everything is going smooth so far until I got to the camera part So basically I've just created a camera let newCam = mp.cameras.new('default', new mp.Vector3(0, 0, 0), new mp.Vector3(0, 0, 0), 40); newCam.pointAtCoord(10, 0, 0); newCam.setActive(true); mp.game.cam.renderScriptCams(true, false, 0, true, false); And set it to active, it worked fine, but after I'm done I want to reset the camera which means I want to deactivate this new camera and activate the old gameplay one which focuses on the player and gives you free mouse movement The way I used to do it on GTA:N was simply like this: API.setActiveCamera(null); I've looked everywhere I can't seem to find a solution to this, do I have to manually set the camera behind the player? If so how do I give the player free mouse movement? Thanks Edited April 20, 2019 by moadi
robinlanvins Posted April 20, 2019 Posted April 20, 2019 (edited) mp.game.cam.renderScriptCams(false, false, 0, true, false); Here you go, change first parameter to false, because true means render custom cameras, false resets them Reference: https://wiki.rage.mp/index.php?title=Cam::renderScriptCams Edited April 20, 2019 by robinlanvins 3
grandbrown Posted March 12, 2020 Posted March 12, 2020 (edited) ❤️ Edited March 12, 2020 by grandbrown
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