func init // adds using namespace sys.add_use('Un4seen.Bass') // initialize a member if(not isdef('Name')) sys.add_var(this.name, 'BASSFlag') blk_init.println(this.codename, ' = ', this.BASSFlag(), ';') end end func BASSFlag() v = this.props('BASSFlag').value flags = ((v _and_ 1) ? '|BASSFlag.BASS_DEFAULT' : '') + ((v _and_ 2) ? '|BASSFlag.BASS_STREAM_PRESCAN' : '') + ((v _and_ 4) ? '|BASSFlag.BASS_STREAM_AUTOFREE' : '') + ((v _and_ 8) ? '|BASSFlag.BASS_STREAM_RESTRATE' : '') + ((v _and_ 16) ? '|BASSFlag.BASS_STREAM_BLOCK' : '') + ((v _and_ 32) ? '|BASSFlag.BASS_STREAM_DECODE' : '') + ((v _and_ 64) ? '|BASSFlag.BASS_STREAM_STATUS' : '') return('(0' + flags + ')') end