gnome14 Posted October 28 Share Posted October 28 (edited) I'm making a player home and I added light switches but when I activate them, it plays some generic sound for activation, instead of the one I chose, no matter what sound I choose. Does anyone have an idea on how to fix it? Edited October 28 by gnome14 Link to comment Share on other sites More sharing options...
sullyvanj93 Posted October 28 Share Posted October 28 I've never tried messing with the Sounds Activate. If that's not working, it may just be a GECK limitation, but I have no idea if that's the case. If you just can't figure that out, try playing your sound through the script instead. Link to comment Share on other sites More sharing options...
gnome14 Posted October 28 Author Share Posted October 28 I did figure out that it has something to do with the script. Activate sound doesn't work with a script like this: Quote scn NPHLightMainSCRIPT Begin OnActivate If XMarkerNPHLightMain.GetDisabled == 1 XMarkerNPHLightMain.Enable Else XMarkerNPHLightMain.Disable Endif End But it does work with a scripts like the ones for picking up fruit, e.g. Quote scn BananaYuccaScript int State begin onActivate if State == 0 && GetActionRef == player player.additem NVFreshBananaYuccaFruit 1 set State to 1 playGroup Forward 1 setdestroyed 1 endif end begin onLoad if State == 0 playGroup Backward 1 elseif State == 1 playGroup Forward 1 endif end begin onReset if State == 1 playgroup Backward 1 set State to 0 setdestroyed 0 endif end But I'm not sure what to make of it. Link to comment Share on other sites More sharing options...
gnome14 Posted October 28 Author Share Posted October 28 Something like this seems to work: Quote scn ActivatorTestSCRIPT Begin OnActivate PlaySound ObjSwitchElevator If TestRef.GetDisabled == 1 TestRef.Enable Else TestRef.Disable Endif End The only problem is that the chosen sound and the usual sound that plays when you press the activate key (E) overlap each other. Link to comment Share on other sites More sharing options...
sullyvanj93 Posted October 29 Share Posted October 29 Would a one-second delay on your sound be appropriate? Very easy to do with NVSE. Link to comment Share on other sites More sharing options...
gnome14 Posted October 29 Author Share Posted October 29 Not really, it has to be immediate, cause it's for a light switch so there needs to be a click simultaneously with activation. I found StopSound function added by JIP on GECK wiki so that could work but I have to check out how to use NVSE scripts first, cause it didn't just work when I added it in the script in GECK lol but I might just leave it as is. Also, thank you for the suggestions. Link to comment Share on other sites More sharing options...
Radioactivelad Posted October 31 Share Posted October 31 A little unintuitive, but you need to put an 'Activate' command in 'OnActivate' scripts if you want the object to react with its built in animations/sounds. 1 Link to comment Share on other sites More sharing options...
gnome14 Posted November 2 Author Share Posted November 2 It worked. Thank you so much! Link to comment Share on other sites More sharing options...
Recommended Posts