amm2100 Posted July 10, 2015 Share Posted July 10, 2015 (edited) Hey Guys 1st : I need to ask how can I make my markers on one group Example :- I have 18 Marker's around the SA Map and I need to put them all with one script in easy way 2nd: is there any way to make Script when I type /makemarker , It make marker cylinder on my position and named it Marker1 , Marker2, Marker3, ...... etc ----------------------------- Sorry for my Bad English and Sorry Because I am noob scriptwriter , I started Lua since 2015/7/7 Edited July 16, 2015 by Guest Link to comment
GTX Posted July 10, 2015 Share Posted July 10, 2015 What do you mean in easy way? Put them in a table? markers = { createMarker(..), createMarker(..) } Link to comment
n3wage Posted July 10, 2015 Share Posted July 10, 2015 1 - Markers = { -- x, y, z { 0, 0, 0 }, { 10, 10, 10 } } for i, v in ipairs ( Markers ) do createMarker ( v[1], v[2], v[3] ); end 2 - count = 0; function makemarker ( thePlayer ) count = count +1; local pos = { getElementPosition ( thePlayer ) }; _G["Marker" .. count] = createMarker ( pos[1], pos[2], pos[3] ); end addCommandHandler ( "makemarker", makemarker ) Link to comment
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