MisterQuestions Posted September 20, 2014 Posted September 20, 2014 Hi i got a error this supose to set the camera to a garage when player uses command, but just have errors whats wrong? Server-Side function garage1() fadeCamera( source, true, 5) setCameraMatrix(source, 1873, -2101, 14, 1873, -2101, 14) --Un extra... outputChatBox ( "#FF9E00Welcome to the garage!", getRootElement(), 255, 255, 255, true ) end addCommandHandler("g1", garage1) Logs [2014-09-19 20:52:28] WARNING: gm\server.lua:14: Bad argument @ 'fadeCamera' [Expected element at argument 1, got nil] [2014-09-19 20:52:28] WARNING: gm\server.lua:15: Bad argument @ 'setCameraMatrix' [Expected element at argument 1, got nil] "El conocimiento jamás debe detenerse, por que es lo único que nos salvará cuando no nos quede más". Att: -|TG|-Mister[Q]<.
Emile Posted September 20, 2014 Posted September 20, 2014 Try this: function garage1(source) fadeCamera( source, true, 5) setCameraMatrix( source, 1873, -2101, 14, 1873, -2101, 14) --Un extra... outputChatBox ( "#FF9E00Welcome to the garage!", source, 255, 255, 255, true ) end addCommandHandler("g1", garage1) fulltheftauto.net
Anubhav Posted September 20, 2014 Posted September 20, 2014 function garage1(source) fadeCamera( source, true, 5) setCameraMatrix(source, 1873, -2101, 14, 1873, -2101, 14) --Un extra... outputChatBox ( "#FF9E00Welcome to the garage!", source, 255, 255, 255, true ) end addCommandHandler("g1", garage1) Edit: GoldenEye was faster See my some resources: Skin shop: https://community.multitheftauto.com/in ... ls&id=8008 Note script: https://community.multitheftauto.com/in ... ls&id=8009 Rules Panel: https://community.multitheftauto.com/in ... ls&id=8246 Random Money: https://community.multitheftauto.com/in ... ls&id=8718
MisterQuestions Posted September 20, 2014 Author Posted September 20, 2014 Mmm i will try..but now how to create a vehicle in x position just for deco on a login screen and when player login destroy them. "El conocimiento jamás debe detenerse, por que es lo único que nos salvará cuando no nos quede más". Att: -|TG|-Mister[Q]<.
Anubhav Posted September 20, 2014 Posted September 20, 2014 What? See my some resources: Skin shop: https://community.multitheftauto.com/in ... ls&id=8008 Note script: https://community.multitheftauto.com/in ... ls&id=8009 Rules Panel: https://community.multitheftauto.com/in ... ls&id=8246 Random Money: https://community.multitheftauto.com/in ... ls&id=8718
MisterQuestions Posted September 20, 2014 Author Posted September 20, 2014 When a player join to server the camera is seted to a "X" point, how to create cars on that point, just for decoration... "El conocimiento jamás debe detenerse, por que es lo único que nos salvará cuando no nos quede más". Att: -|TG|-Mister[Q]<.
Anubhav Posted September 20, 2014 Posted September 20, 2014 playerCars = {} function garage1(source) fadeCamera( source, true, 5) setCameraMatrix(source, 1873, -2101, 14, 1873, -2101, 14) playerCars[source] = createVehicle(345, 1873, -2101, 14) setElementVisibleTo(playerCars[source], root, false) setElementVisibleTo(playerCars[source], source, true) outputChatBox ( "#FF9E00Welcome to the garage!", source, 255, 255, 255, true ) end addCommandHandler("g1", garage1) addEventHandler("onPlayerQuit", root, function() if playerCars[source] then destroyElement(playerCars[source]) playerCars[source] = nil end end ) addEventHandler("onPlayerLogin", root, function() if playerCars[source] then destroyElement(playerCars[source]) playerCars[source] = nil end end ) I-guess. See my some resources: Skin shop: https://community.multitheftauto.com/in ... ls&id=8008 Note script: https://community.multitheftauto.com/in ... ls&id=8009 Rules Panel: https://community.multitheftauto.com/in ... ls&id=8246 Random Money: https://community.multitheftauto.com/in ... ls&id=8718
MisterQuestions Posted September 20, 2014 Author Posted September 20, 2014 oh! amazing.... now i need to search a place to set camera (when i say place i mean to a garage) "El conocimiento jamás debe detenerse, por que es lo único que nos salvará cuando no nos quede más". Att: -|TG|-Mister[Q]<.
Anubhav Posted September 20, 2014 Posted September 20, 2014 Thanks and no problem. See my some resources: Skin shop: https://community.multitheftauto.com/in ... ls&id=8008 Note script: https://community.multitheftauto.com/in ... ls&id=8009 Rules Panel: https://community.multitheftauto.com/in ... ls&id=8246 Random Money: https://community.multitheftauto.com/in ... ls&id=8718
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