- Home /
Efficient script parser
I'm in the middle of making a text parser, and I'm stuck on a problem. I need it to be able to skip spaces between text if a condition is set (if statement). The parsing process is a for loop that reads a text asset. Is there anyway to just make the for loop skip the reading of spaces (" ")?
This is not really a Unity question. Look at the .Net documentation for System.IO and you can find all of the features you can use for text processing.
If you are just going to parse it as-is w/o using the .Net libraries directly, and without knowing anything about your problem, I would suggest just using the string.split() function. $$anonymous$$aybe post some actual code if you want more specific help.
if you really just want xml functionality unity has this built in - http://answers.unity3d.com/questions/63728/easy-xml-parsing.html
Your answer
![](https://koobas.hobune.stream/wayback/20220613105646im_/https://answers.unity.com/themes/thub/images/avi.jpg)