kuba90pl Posted November 11, 2011 Share Posted November 11, 2011 hi ! auta.xml: <auta> <car1 id="500" owner="oli" /> <car2" id="502" owner="oli2" /> </auta> index=0 function proste() local autaxml = xmlLoadFile ( "misc/auta.xml" ) if autaxml then index=(index)+1 ind="car"..index.."" outputChatBox(ind) local info = xmlFindChild ( autaxml, ind, 0 ) local attrs = xmlNodeGetAttributes ( info ) value={} for name,value in pairs ( attrs ) do id=value[1] nazwa=value[2] outputChatBox(id) outputChatBox(nazwa) createVehicle(id,-1989,129,27.539062) end end end I want to get id and owner from table value but i dont know how. Help ! 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