xXGhostXx Posted October 9, 2018 Share Posted October 9, 2018 (edited) Hi guys ! What is problem ? I want show plate vehicle on click vehicle ! function showpelak () local noclick local carSelect outputChatBox("#f2e345[Vehicle]: "..getVehiclePlateText ( carSelect ), 50, 164, 29, true) noclick = nil end addEventHandler("OnClientClick", showpelak) Please answer me problem ! @iMr.WiFi..! Edited October 9, 2018 by xXGhostXx Link to comment
iMr.WiFi..! Posted October 9, 2018 Share Posted October 9, 2018 addEventHandler ( "onClientClick", getRootElement(), function ( button, state, absoluteX, absoluteY, worldX, worldY, worldZ, clickedElement ) if( button == "right" )then if( state == "down" )then if( getElementType( clickedElement ) == 'vehicle' )then outputChatBox("#f2e345[Vehicle]: "..getVehiclePlateText ( clickedElement ), 50, 164, 29, true) end end end end ) 1 Link to comment
xXGhostXx Posted October 9, 2018 Author Share Posted October 9, 2018 10 minutes ago, iMr.WiFi..! said: addEventHandler ( "onClientClick", getRootElement(), function ( button, state, absoluteX, absoluteY, worldX, worldY, worldZ, clickedElement ) if( button == "right" )then if( state == "down" )then if( getElementType( clickedElement ) == 'vehicle' )then outputChatBox("#f2e345[Vehicle]: "..getVehiclePlateText ( clickedElement ), 50, 164, 29, true) end end end end ) Not work ! Link to comment
iMr.WiFi..! Posted October 9, 2018 Share Posted October 9, 2018 16 minutes ago, xXGhostXx said: Not work ! You need to right click on vehicle to get outputChatBox Link to comment
xXGhostXx Posted October 9, 2018 Author Share Posted October 9, 2018 43 minutes ago, iMr.WiFi..! said: You need to right click on vehicle to get outputChatBox How to set left click on vehicle for get outputChatBox 46 minutes ago, iMr.WiFi..! said: You need to right click on vehicle to get outputChatBox Thanks ! i Liked You Link to comment
KillerX Posted October 9, 2018 Share Posted October 9, 2018 4 hours ago, xXGhostXx said: How to set left click on vehicle for get outputChatBox addEventHandler ( "onClientClick", getRootElement(), function ( button, state, absoluteX, absoluteY, worldX, worldY, worldZ, clickedElement ) if( button == "left" )then if( state == "down" )then if( getElementType( clickedElement ) == 'vehicle' )then outputChatBox("#f2e345[Vehicle]: "..getVehiclePlateText ( clickedElement ), 50, 164, 29, true) end end end end ) Link to comment
Recommended Posts