public PlayerSoundsComponent( IAudio audio, Rigidbody rigidbody, PlayerStateMachine stateMachine) { this.source_ = audio.Factory.NewAudioSource(3); var sfx = LocalIo.Resources.GetSubpath("sfx/"); this.bumpWallSound_ = audio.LoadAsBuffer(sfx.GetFile("bump_wall.ogg")); this.footstepHeavy_ = audio.LoadAsBuffer(sfx.GetFile("footstep_heavy.ogg")); this.footstepLight_ = audio.LoadAsBuffer(sfx.GetFile("footstep_light.ogg")); this.jumpSound_ = audio.LoadAsBuffer(sfx.GetFile("jump.ogg")); this.walljumpSound_ = audio.LoadAsBuffer(sfx.GetFile("walljump.ogg")); this.fallSound_ = audio.LoadAsBuffer(sfx.GetFile("fall.ogg")); this.landSound_ = audio.LoadAsBuffer(sfx.GetFile("land.ogg")); this.whipSound_ = audio.LoadAsBuffer(sfx.GetFile("whip.ogg")); this.rigidbody_ = rigidbody; this.stateMachine_ = stateMachine; this.HookIntoStateMachine_(stateMachine); }