Jump to content
Sign in to follow this  
LtShadow

Real Sound Configuration - Help with inits?

Recommended Posts

Hey guys, it's Shadow (aka IntrepidGamer)

I have here in the midst of my @RealSound FA-18 Super Hornet (model by John and Saul) an issue!

Your mission, if you choose to accept, goes like this;

In the previous version of the F-18 mod (I say F-18 because it was not a super hornet at that time), I was able to piggy back on a initialization script within the main aircraft pbo file that allowed me to use a flyby script I used to play a realistic fly by of a certain aircraft, because the RV engine does not have the stand alone capability.

The way it works;

The script needs several calling factors in able to correctly target a specific user, and the aircraft, that will play the sound file with the given speed, altitude, and direction.

Here is the code itself -- NOTE: This is a one of a kind script, please use it only for troubleshooting purposes, please! :)--

//Flyby script by matt and tyler from @RS 2012

private "_flyby";

_flyby = false;

while {alive _this} do {
_sleeptime = 19;
while {!_flyby} do {
	sleep 2;
	_dist = player distance _this;
	_speed = speed _this;
	_ex = ((_this != vehicle player) && !(vehicle player isKindOf "Plane"));
	_a10 = (_this isKindOf "A10" || _this isKindOf "Su25_base");
	_su = (_this isKindOf "Su34" || _this isKindOf "ACE_T10" || _this isKindOf "L39_TK_EP1" || _this isKindOf "ACE_Su30"  || _this isKindOf "ACE_Su34");
	_av8 = (_this isKindOf "F18C");

	if (_dist > 180 && _dist <= 1000 && (_speed > 350) && _ex && _av8) exitWith {
		playsound "close_fb";
		_flyby = true;
	};
};
sleep _sleeptime;
_flyby = false;
};

Now, in order for this to work correctly there needs to be a few more scripts which are used to call for this one in particular.

See below for the ladder of how this script gets called.

F-18c Hornet calls for init;

class Extended_Init_EventHandlers
{
class f18c
{
 F18C_init = "[_this select 0] execVM ""\f18c\scripts\init.sqf"";";
};
class 200

Inside the init.sqf;

private "_plane";
_plane = _this select 0;

_nul = [_plane] execVM "\f18c\scripts\fbfx.sqf";


Inside the fbfx.sqf file;

_veh = (_this select 0);

//Private ["_script1[]"];

_script1 = [];

if (alive player) then
{
_script1 set [0, _veh execVM "\f18c\scripts\flyby.sqf"];
};

And then the flyby script is called for...

This works perfectly fine in the original aircraft, because it was all pre-set and ready for us to roll with it.

Thing is, I have no idea how to create the first set of arguments to start the script. I helped with creating the script, but am no expert.

I would appreciate your guys' help in me figuring this out, to bring forth the next big update for the FA-18 Super Hornet @RealSound replacement! ;)

Thank you!

Tyler (Shadow/Intrepid)

ArmA Holic post: http://www.armaholic.com/page.php?id=24551

Share this post


Link to post
Share on other sites

Anyone available to tell me what/how to do with this? :)

Share this post


Link to post
Share on other sites

I'm sorry admins, but can you please move this to a more active thread? It would be greatly appreciated! Ty.

Share this post


Link to post
Share on other sites

Basically asking; How do I initialize this within the FA-18 Super Hornet with Eventhandlers?

Thank you!

Share this post


Link to post
Share on other sites

maybe you should ask a mod to move your thread to the "correct" forum section.. maybe you'll get some help there :D

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  

×