How to play a sound

Post » Sun Nov 18, 2012 7:23 pm

Hi there!
How to play a sound through script
Sound.Play() - doesn't work
User avatar
Andy durkan
 
Posts: 3459
Joined: Fri Aug 03, 2007 3:05 pm

Post » Sun Nov 18, 2012 12:47 pm

???
User avatar
Curveballs On Phoenix
 
Posts: 3365
Joined: Sun Jul 01, 2007 4:43 am

Post » Sun Nov 18, 2012 4:55 pm

http://www.creationkit.com/PlayAndWait_-_Sound

See if that helps?
User avatar
Katharine Newton
 
Posts: 3318
Joined: Tue Jun 13, 2006 12:33 pm

Post » Sun Nov 18, 2012 8:22 am

What kind of sound are you trying to play? An existing sound? A wav file? A line of dialogue (fuz file)?

Existing sound example:
-------------------------------

Spoiler

;Sound should be injected from Creation Kit.;Whatever object the script is attached to should provide a Properties buttonSound  Property MagVampireTransform01  AutoFunction test()	 MAGVampireTransform01.Play(Game.GetPlayer())endFunction

Speaking Dialogue with Script Example:
-------------------------------------------------


Spoiler

; (Custom topics should always be injected. Vanilla topics can be injected or you can look them up at runtime)Topic Property BashTopic AutoFunction test()	Topic pBashTopic	if (BashTopic)		pBashTopic = BashTopic	else		pBashTopic = (Game.GetForm(0x00039B94) As Topic)	endif	Game.GetPlayer().Say(pBashTopic)endFunction
User avatar
Sandeep Khatkar
 
Posts: 3364
Joined: Wed Jul 18, 2007 11:02 am


Return to V - Skyrim