Play Sound script not working. Help please.

Post » Tue Feb 04, 2014 7:58 am

I want a sound to play when player takes an object. This is how I've scripted it - the Utility.Wait is there so I could make sure the sound was played - I can't hear it.

Sound Property mySound  AutoEvent OnContainerChanged(ObjectReference akNewContainer, ObjectReference akOldContainer)if akNewContainer == Game.GetPlayer()   mySound.Play(self)Utility.Wait(2.0)debug.messagebox("You have found a rare painting")EndifEndEvent

The sound I chose to play is UISkillIncrease, I can hear it obviously previewed in CK in Sound Descriptor category but not in-game.

Thanks.

User avatar
Jade Barnes-Mackey
 
Posts: 3418
Joined: Thu Jul 13, 2006 7:29 am

Post » Mon Feb 03, 2014 11:32 pm

try playing it on akNewContainer instead - you probably can't play a sound on something inside a container, but the container itself should work.

User avatar
Scarlet Devil
 
Posts: 3410
Joined: Wed Aug 16, 2006 6:31 pm


Return to V - Skyrim