func init // adds using namespace sys.add_use('Un4seen.Bass') // initialize a member if(not isdef('Name')) sys.add_var(this.name, 'BASSMode') blk_init.println(this.codename, ' = ', this.BASSMode(), ';') end end func BASSMode() v = this.props('BASSMode').value flags = ((v _and_ 1) ? '|BASSMode.BASS_POS_BYTES' : '') + ((v _and_ 2) ? '|BASSMode.BASS_POS_MUSIC_ORDERS' : '') + ((v _and_ 4) ? '|BASSMode.BASS_POS_MIDI_TICK' : '') + ((v _and_ 8) ? '|BASSMode.BASS_POS_OGG' : '') + ((v _and_ 16) ? '|BASSMode.BASS_MUSIC_POSRESET' : '') + ((v _and_ 32) ? '|BASSMode.BASS_MUSIC_POSRESETEX' : '') + ((v _and_ 64) ? '|BASSMode.BASS_MIXER_NORAMPIN' : '') + ((v _and_ 128) ? '|BASSMode.BASS_POS_DECODE' : '') + ((v _and_ 256) ? '|BASSMode.BASS_POS_DECODETO' : '') + ((v _and_ 512) ? '|BASSMode.BASS_MIDI_DECAYSEEK' : '') return('(0' + flags + ')') end