Nicolas ECM Posted December 9, 2013 Posted December 9, 2013 Hi I want help text appears in 3D when / doton command took place this cast but nothing happens please help local dxDraw3DText = exports.3D_DX_Texts:dxDraw3DText addCommandHandler("doton" mogolla ) function mogolla () local x, y, z = getElementPosition ( sourcePlayer ) local theText = dxDraw3DText( "Doton doriu jehiquin" x, y, z, 2, "default", 255, 255, 255, 12 ) if theText then setTimer( destroyElement, 10000, 1, theText ) end end
Castillo Posted December 9, 2013 Posted December 9, 2013 local dxDraw3DText = exports.3D_DX_Texts:dxDraw3DText function mogolla ( ) local x, y, z = getElementPosition ( sourcePlayer ) local theText = dxDraw3DText( "Doton doriu jehiquin" x, y, z, 2, "default", 255, 255, 255, 12 ) if theText then setTimer ( destroyElement, 10000, 1, theText ) end end addCommandHandler ( "doton" mogolla ) San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Castillo Posted December 9, 2013 Posted December 9, 2013 Post the source code from this function: dxDraw3DText San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Sasu Posted December 10, 2013 Posted December 10, 2013 Where is 'sourcePlayer' defined? @Solidsnake14, you forgot a comma on line 10. State: Inactive
Castillo Posted December 10, 2013 Posted December 10, 2013 Not really, he forgot the comma. function mogolla ( ) local x, y, z = getElementPosition ( localPlayer ) local theText = dxDraw3DText ( "Doton doriu jehiquin" x, y, z, 2, "default", 255, 255, 255, 12 ) if theText then setTimer ( destroyElement, 10000, 1, theText ) end end addCommandHandler ( "doton", mogolla ) San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
DiSaMe Posted December 10, 2013 Posted December 10, 2013 Apart from missing commas and usage of variable before it is assigned the function value, this line hardly has any meaning: local dxDraw3DText = exports.3D_DX_Texts:dxDraw3DText This syntax: table:method(arguments) is another way to write this call: table.method(table, arguments) So it's not like 'table:method' has any meaning without a call. -
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