Jump to content
Sign in to follow this  
AdmiralKarlDonuts

Helicopter powerup sound???

Recommended Posts

How do I add that powerup sound to a helicopter? I pulled apart the USMC AH-1W Beta and the BAS Black Hawks - which both have it - and tried adding the relevant parts to my config, but no dice.

Can someone post an example of how I might do this from scratch, without cutting up other people's scripts and configs?

Many thanks. smile_o.gif

PS here's what I'm trying to make work: essentially copy/pasted from those aforementioned configs.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class EventHandlers

{

engine ="if (_this select 1) then {[_this select 0] exec ""\s84_uh1h\scripts\powerup.sqs""}";

};

class CfgSounds

{

class Powerup

{

sound[]={"\s84_uh1h\powerup.ogg",db-30,1};

name = "powerup";

titles[] = {};

};

};

Now to powerup.sqs...

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">_huey = _this select 0

? (getpos _huey select 2) <2:_huey say "powerup"

exit

powerup.ogg is located in the root \s84_uh1h directory.

It looks to me like this should all work, so I'm clueless.

Share this post


Link to post
Share on other sites

Try this

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">engine ="if (_this select 1) then {[_this select 0] exec {\s84_uh1h\scripts\powerup.sqs}}";

everything else looks ok.

Share this post


Link to post
Share on other sites

Looks okay, but your engine will start running imemdiately, and you just may not hear the sound over the regular engine one?

Try a sidechat in your script. to debug

Cheers

Share this post


Link to post
Share on other sites

Hmmm, I tried the syntax CSJ suggested and added a debug globalchat....it seems that the script isn't being called at all. No error messages, but no sound and no globalchat.

The investigation continues rock.gif

Share this post


Link to post
Share on other sites

You've got the:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class EventHandlers

{

engine ="if (_this select 1) then {[_this select 0] exec ""\s84_uh1h\scripts\powerup.sqs""}";

};

inside the CfgVehicles definition of your unit, yep? And the

CfgSounds outside?

Share this post


Link to post
Share on other sites
You've got the:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class EventHandlers

{

engine ="if (_this select 1) then {[_this select 0] exec ""\s84_uh1h\scripts\powerup.sqs""}";

};

inside the CfgVehicles definition of your unit, yep? And the

CfgSounds outside?

Oooof...that was it. the eventhandlers were not in the right place. That's fixed it - thanks footmunch smile_o.gif

BTW how's the Mudhen coming? hehehe...

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×