SerweryWłasny serwerDla twórcówForumFAQDokumentacjaBezpieczeństwo
Pobierz launcher
  1. Dokumentacja
  2. Funkcje klienta
  3. setSoundEffectParameter

Funkcja

setSoundEffectParameter

KlientDźwięk (klient)Identyczna z MTA:SA

Ustawia parametr efektu, także wyłączonego. Nazwy i zakresy są jak w MTA (np. echo: wetDryMix, feedback, leftDelay, rightDelay, panDelay; reverb: inGain, reverbMix, reverbTime, highFreqRTRatio); bandpass: lowCut, highCut, gain.

Składnia

bool setSoundEffectParameter(sound theSound, string effectName, string effectParameter, mixed effectParameterValue)

Argumenty

theSoundsound
Dźwięk.
effectNamestring
Nazwa efektu.
effectParameterstring
Nazwa parametru.
effectParameterValuemixed
Liczba (albo bool dla panDelay). Wartość spoza zakresu daje false i ostrzeżenie z zakresem.

Zwraca

true przy powodzeniu.

Przykład

Głos przez telefon.

local call = playSound("audio/call.mp3")
setSoundEffectEnabled(call, "bandpass", true)
setSoundEffectParameter(call, "bandpass", "lowCut", 400)
setSoundEffectParameter(call, "bandpass", "highCut", 3000)

Zobacz też