Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

using libxml2 with cocos2d-x

I am new in C++ and cocos2d-x. I need to know how to parse XML with elements and attributes libxml2 in cocos2d-x . I have tried to google but I can't file any exact code example . how exactly are the usage of the libxml2 in cocos?

I found this code from the official site but I don't have any idea how to convert it into cocos code. http://www.xmlsoft.org/examples/reader1.c

I am using XCode for the IDE,.

like image 567
Fugogugo Avatar asked Mar 05 '26 02:03

Fugogugo


1 Answers

If you look in CCSAXParser.cpp and CCUserDefault.cpp you will see an example of cocos2d-x using libxml to parse data. Or there is also this solution (I have never tried it).

like image 159
Paul de Lange Avatar answered Mar 07 '26 18:03

Paul de Lange



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!