Do config files work on linux/mac

Hello guys!
I was wondering if anybody knows if the .ini style files work on linux/mac. More specifically the files that are used by the configparser module. My hope are that it does, as I’ve pretty much given up on the xml parsers.

This would be the script that I am running:

from bge import logic
import configparser
parser = configparser.ConfigParser()


cont = logic.getCurrentController()
own = cont.owner


path = logic.expandPath('//')
file = 'Campaign_waves.ini'


parser.read_file(open(path+file))
sections = parser.sections()
    
for item in sections:
    shipType = parser.get(item, "ship")

And the .ini file (stored with the .blend:

[DEFAULT]
ship=0
amount=0
delayBetweenShips=0
SkipToNextWave=0
health=0
armor=0
guns=0
lastWave=0


[WAVE1]
ship=0
amount=10
delayBetweenShips=60
SkipToNextWave=0
health = 2
armor = 1
guns = 0
lastWave = 1

Thanks :smiley:

If it’s in the Python standard library, it should not be platform specific*.

Thank you :slight_smile: