Explanation of the main loop (do loop)
- first, it reads characters from the source OBJ file and collects them until it encounters a space or a line break, this string is called WORD$
- second, it checks if this word is a number, if it is:
- it'll check if the type$ string is equal to "v" (vertex), if it is then:
- else if the type$ string is equal to "f" (face), if it is then:
- it'll convert the number, and skip the steps that are for floats (these are integers) as described by @nathanielbabiak
- if the WORD$ is not a number then it's a type
- it'll capitalize all non capital ascii codes to make them easier to work with in NX
- it'll set the type$ string to word$
- if it the new type$ is "#" (comment) it'll skip all text that comes after it until the next line break