2020-02-05から1日間の記事一覧
AVFoundationをインポート import AVFoundation var sound: AVAudioPlayer? func playSound() { if let path = Bundle.main.path(forResource: "2_cymbal", ofType: "mp3") { do { sound = try AVAudioPlayer(contentsOf: URL(fileURLWithPath: path)) print…