Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 10 Guests
Online:

LATEST FORUM THREADS

»
warfare
CoD4 Map + Mod Releases
Voting menu on maps
CoD+UO General
Hauling 911
CoDBO3 General

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 4
Category: CoD4 Scripting
Scripting and coding with Call of Duty 4.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername, novemberdobby
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked subscribe
Author Topic: flickering litghs with sound Problem
Hippster
General Member
Since: Sep 21, 2008
Posts: 81
Last: Jun 22, 2011
[view latest posts]
Level 3
Im a fan of MODSonair
Category: CoD4 Scripting
Posted: Sunday, Sep. 27, 2009 01:42 pm
Hi there,
i have flickering Lights in my Prefab and it works so far. Now i got an Issue with the Sound - the Sound starts to play when my Litghts are on (buzzing)...
Now i need to know how can i stopp playing the Buzzsoundfile when my Models switch off...(the Sound is still playing..)

Here is the Code i use:

Code:


....some other Mapstuff...

		wait(randomfloat(5)); //self waittill("trigger"); (for randomly move) wait(randomfloat(7));

		spotlight1_hide movez (height, speed); // Move script_brushmodel(s) on Z axis
		spotlight1_model setmodel( "me_lightfluohang" );       // swap xmodel by _off
		self stoploopsound("lightsbuzz");
		spotlight1_hide waittill ("movedone");


		
		wait(randomfloat(2.5)); //self waittill("trigger"); (for randomly move) wait(randomfloat(7));

		spotlight1_hide movez (height - (height * 2), speed);
		spotlight1_model setmodel( "me_lightfluohang_on" ); // switch back to _on Xmodel
		self playsound("lightbuzz");
		spotlight1_hide waittill ("movedone");

....some other Mapstuff...


Would be nice if someone can help me out here :)

Best Regards

edited on Sep. 28, 2009 05:38 am by Hippster
Share |
Restricted Access Topic is Locked subscribe
MODSonline.com Forums : Call of Duty 4 : CoD4 Scripting

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»