Ahmed Abo-elezz Posted November 24, 2014 Posted November 24, 2014 why i got error table indes is nil in this line markertkhashab [ thePlayer ] = createMarker ( x, y, z, "cylinder", 5.0, 255, 0, 0, 255, theplayer ) please help me local Marjerkhashwood = { [1]={ -1635.6999511719, -2219.5, 30 }, [2]={ -1636.8000488281, -2203.6000976563, 30.400001525879 }, [3]={ -1731.3000488281, -2212, 55 }, [4]={ -1715.8000488281, -2235.6999511719, 46 }, [5]={ -1643.0999755859, -2261.8000488281, 31.599998474121 } } markertkhashab = { } blipkhshab = { } function startJobkhashab ( thePlayer, seat, jacked ) local x, y, z = unpack ( Marjerkhashwood [ math.random ( #Marjerkhashwood ) ] ) markertkhashab [ thePlayer ] = createMarker ( x, y, z, "cylinder", 5.0, 255, 0, 0, 255, theplayer ) blipkhshab [ thePlayer ] = createBlipAttachedTo ( markertkhashab [ thePlayer ], 58, 2, 255, 0, 0, 255, 0, 99999.0, thePlayer ) addEventHandler ( "onMarkerHit", markertkhashab [ thePlayer ], warpkhashab ) end
ALw7sH Posted November 24, 2014 Posted November 24, 2014 local Marjerkhashwood = { { -1635.6999511719, -2219.5, 30 }, { -1636.8000488281, -2203.6000976563, 30.400001525879 }, { -1731.3000488281, -2212, 55 }, { -1715.8000488281, -2235.6999511719, 46 }, { -1643.0999755859, -2261.8000488281, 31.599998474121 } }
Moderators IIYAMA Posted November 27, 2014 Moderators Posted November 27, 2014 @ALw7sH You just wrote exactly the same.... @Arab Real Life The variable thePlayer is nil. and why it is nil, is caused by your other code.
Saml1er Posted November 27, 2014 Posted November 27, 2014 Show us the part where you're calling startJobkhashab function.
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