Advertisement

Author Topic: Config sounds, Say command, and using loud noises.  (Read 618 times)

0 Members and 1 Guest are viewing this topic.

Offline DMarkwick

  • Contributing Member
  • **
  • I'm a llama!
Config sounds, Say command, and using loud noises.
« on: 21 Aug 2009, 14:28:53 »
OK, so for the forest fire part of the new addon I'm making, I'd like for the fire to make a selection of noises. I'd like to either:
Have the custom object repeatedly Say the noise or
have the object loop the noise (or a selection of noises) via config until it's deleted.

In the config I have the object:
Code: [Select]
class firemarkerinv : DMViewBlock4Vis
 {
  displayName="firemarker (invisible)";
  model="\JTD_FireAndSmoke\firemarkerinv.p3d";
 };

and the sound:
Code: [Select]
class CfgSounds
{
 sounds[] = {};   
  class forestfiresound1
  {
   name = "ForestFireSound1";
   sound[] = {"\JTD_FireAndSmoke\Sounds\ForestFireSound1.ogg", 1, 1};
   titles[] = {};
  };
};

So, two questions I guess.
1. How do I add sounds to an object and get it to loop those sounds.
2. What sound parameters do I need to have a loud noise audible over say 200m?

Offline nominesine

  • Former Staff
  • ****
  • I'm NOT back!
    • The IKB Forum
Re: Config sounds, Say command, and using loud noises.
« Reply #1 on: 21 Aug 2009, 15:03:21 »
I don't know much about addons, but when you are using sounds in a regular mission you can now define the distance over wich each and every sound can be heard. The volume will gradually fade away until maximum distance is reached. Even if you set the decibel to +90 or other rediculously high levels. In order to make a sound thtat should be heard at 200 meters I would say you need to set it's maximum distance to 300 or more (it's very weak and barely audible after 200 meters). Unfortunately I have no idea how sounds are defined within an addon. Do they have an internal description.ext or some similar equivalent?
OFPEC | Intel Depot
RETARDED Ooops... Retired!

Offline DeanosBeano

  • Addons Depot Staff
  • *****
  • SirDeanosbeano bstowed on me by sui ;)
    • Fraghaus
Re: Config sounds, Say command, and using loud noises.
« Reply #2 on: 21 Aug 2009, 16:02:48 »
  the best way if its possible (i.e you dont have too many in close proximity) would be to emulate the original fires .

 
Code: [Select]
class Land_Fire : House
    {
      model = "\Ca\misc3\fire";
      displayName = "Fireplace";
      icon = "\ca\misc3\data\Icons\icon_fireplace_ca.paa";
      mapSize = 1;
      scope = 2;
      armor = 150;
      simulation = "fire";
      vehicleClass = "Misc";
      class effects : SmallFire
      {
        class Light1
        {
          simulation = "light";
          type = "SmallFireLight";
        };
        class sound
        {
          simulation = "sound";
          type = "Fire";
        };
        class Fire1
        {
          simulation = "particles";
          type = "SmallFireF";
        };
        class Smoke1
        {
          simulation = "particles";
          type = "SmallFireS";
        };
      };
    };

 the sound is defined elsewhere

   class Fire
    {
      name = "Fire";
      sound[] = {
        "\ca\Sounds\sfx\fire",
        0.316228,
        1
      };
      titles[] = {
      };
    };

 as afr as i am aware the first number ( sometimes there can be 3) is decibels , this determines how far the sound can be heard from the source and the second is the speed or pitch * the original .

 i know Mark from hifi could answer this better but if he dont show up iwill ask him to come take a look.

I love ofp

Offline DMarkwick

  • Contributing Member
  • **
  • I'm a llama!
Re: Config sounds, Say command, and using loud noises.
« Reply #3 on: 23 Aug 2009, 22:38:42 »
Thanks DB :)

Offline scud

  • Members
  • *
Re: Config sounds, Say command, and using loud noises.
« Reply #4 on: 25 Nov 2009, 22:42:01 »
What does the '90' represent in this case ?
example:
soundVehiclePlate1[] = {"ca\sounds\weapons\hits\hit_vehicle_plate_01", 0.562341, 1, 90};

My problem is the hit sounds are too quiet and I need to increase the volume.
Is this possible via cfg or do I have to rerecord the sound with an increased volume?


Those that know - say nothing. Those that know nothing - tell all.

Offline DeanosBeano

  • Addons Depot Staff
  • *****
  • SirDeanosbeano bstowed on me by sui ;)
    • Fraghaus
Re: Config sounds, Say command, and using loud noises.
« Reply #5 on: 26 Nov 2009, 00:09:30 »

 well i can give you my best guess , i never saw any Bis documentation for a2 ( like all thing i think we must wait till after A:o for official info ;) makes good buisness sense to me) .

 soundVehiclePlate1[] = {"ca\sounds\weapons\hits\hit_vehicle_plate_01", 0.562341, 1, 90};
                             
first is volume  or DB of the original recording 1 is as recorded your value is 0.5 so half original

second  is pitch or speed

 third ( guess)  the distance from impact that the sound will be heard Max ( or distance at which some fuziness/fade is applied) i say the last because shells have a last figure of 1800 and the sound is different  although 1800 may not mean make fuzzy like i said , it may simply be the max distance it will be heard from source.


I love ofp

Offline scud

  • Members
  • *
Re: Config sounds, Say command, and using loud noises.
« Reply #6 on: 26 Nov 2009, 03:22:07 »
Ok, my misunderstanding, I thought the db was the distance the sound carried and not necessarily the same as volume.
More experimenting and cross referencing.

thanks


Those that know - say nothing. Those that know nothing - tell all.