Mercurial > public > geoquiz
comparison GeoQuiz/Logic/GameProtocol+Extension.swift @ 14:136928bae534
add user profile
author | Dennis C. M. <dennis@denniscm.com> |
---|---|
date | Wed, 19 Oct 2022 07:56:33 +0200 |
parents | a793f33f05fb |
children | f1967f8cc67b |
comparison
equal
deleted
inserted
replaced
13:bdfff35dd43c | 14:136928bae534 |
---|---|
119 } | 119 } |
120 | 120 |
121 private func playSound(_ filename: String) { | 121 private func playSound(_ filename: String) { |
122 let user = User() | 122 let user = User() |
123 | 123 |
124 if user.settings.sound { | 124 if user.data.sound { |
125 guard let soundFileURL = Bundle.main.url(forResource: filename, withExtension: "wav") else { | 125 guard let soundFileURL = Bundle.main.url(forResource: filename, withExtension: "wav") else { |
126 fatalError("Sound file \(filename) couldn't be found") | 126 fatalError("Sound file \(filename) couldn't be found") |
127 } | 127 } |
128 | 128 |
129 do { | 129 do { |