How to auto-repeat sound effects - Printable Version +- Sword of Moonlight Forums (https://forum.swordofmoonlight.com) +-- Forum: Sword of Moonlight (https://forum.swordofmoonlight.com/Forum-Sword-of-Moonlight) +--- Forum: SOM Guides, FAQ and Help (https://forum.swordofmoonlight.com/Forum-SOM-Guides-FAQ-and-Help) +--- Thread: How to auto-repeat sound effects (/Thread-How-to-auto-repeat-sound-effects) |
How to auto-repeat sound effects - HwitVlf - 2009-12-11 Attached is a project showing one way to repeat a timed sound effect. The 'Trigger Loop' event which is currently set to 'When Examined' can be changed to activate 'If Approached' or such. Here's the breakdown ------------------------------------------- Event#1 (Event Trigger=[trigger can be anything you want it to be]) [This Event starts up the loop in Event#2] Control Active Leaf (Target='Event#2' - Move to Leaf01) -------------------------------------------- Event#2 (Event Trigger=Always On) [This Event actually plays the timed/looped the sound effect] Leaf00 Change Counter Value (Set 'Counter00-Times Played' to 0) Leaf01 Play Sound Effect Alter Counter Value (Raise 'Counter00-Times Played ' by 1) Begin Timer00 Control Active Leaf (This Event Forward by 1) Leaf02 IF ('Times Played Counter' =4) Control Active Leaf (This Event to Leaf0)[This ends the loop after 4 plays] OTHERWISE Set Timer Value In Counter (Acquire Value From 'Timer0' & Set its value in 'Counter01-TimePassed') IF ('Counter01-TimePassed' =3)[This waits 3 seconds before replaying the sound] Control Active Leaf (This Event Move to Leaf01)[This restarts the loop] END IF END IF ----------------------------------------------- Re: How to auto-repeat sound effects - Madison Lastrega - 2009-12-12 I'm Sure it's great and all but my SoM Crashes when I try to load this or any other sample projects you have made , Don't know why exactly I know I always have to disable my DirectX to edit and re-enable to test, but my saved projects work just fine when I try to load any of the samples I get " SoM Main has encountered a blah-da-be -blah-de-dee" so ...any sugestions on this, I know your tutorials are sure to be an awesome help and would have saved me so much time but, unfortunaly I have had to "wing much of the begginning, until I found you wonderful people:) I love you all I like mostly the age group we share I am 34 by the way:) Re: How to auto-repeat sound effects - HwitVlf - 2009-12-12 That is very odd. All it requires is map Piece #0005, and Barrel (1) Object. You might try deleting the som_db.ini in the project folder; it might have some setting that's not compatible with your PC. But that shouldn't cause SOM_MAIN.EXE to crash. If that doesn't help, I'll just type in the directions manually here- let me know. Can someone else please test the attached project and see if it causes a crash? Re: How to auto-repeat sound effects - Madison Lastrega - 2009-12-12 Sorry my friend no dice:( I deleted the Ini and it still won't load. However, and the bright side I got the sound loop to work after all:) so all is well there , could you still explain a little about the IF command and IF message and otherwise they still confuse me :) thanks John your directions are sound:) Re: How to auto-repeat sound effects - HwitVlf - 2009-12-12 Added the typed looping event to the first post in this thread and added some 'IF' info here: https://www.swordofmoonlight.com/bbs/index.php/topic,253.msg2852.html#msg2852 |