Skip to content
Snippets Groups Projects

Bug fix

Merged Robin Halseth Sandvik requested to merge master into main
3 files
+ 14
7
Compare changes
  • Side-by-side
  • Inline
Files
3
using System.Collections;
using System;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
using UnityEngine.InputSystem;
@@ -60,7 +61,7 @@ namespace BigSock {
bulletScript.Direction = (target.Value - (Vector2) actor.transform.position).normalized;
// Play sound effect
var source = actor.source[0];
var source = actor.source.FirstOrDefault();
var audioClip = AudioService.SINGLETON.Get(AUDIO_PATH);
if (source != null && audioClip != null) {
source.clip = audioClip;
Loading