Beispiel #1
0
def write_vscripts(vrad_conf: Property):
    """Write script functions for sounds out for VRAD to use."""
    if not SOUNDS:
        return

    conf_block = vrad_conf.ensure_exists('InjectFiles')

    for filename, code in SOUNDS.values():
        with open('BEE2/inject/' + filename, 'w') as f:
            f.write(code)
        conf_block[filename] = SOUND_LOC + filename