From 648748d09592c6ae642114605520f129328acd7c Mon Sep 17 00:00:00 2001 From: Hammie Date: Mon, 2 Oct 2023 15:03:38 +0200 Subject: [PATCH] Configure dialog tick sound #144 --- PROGRAM/dialog.c | 62 ++++++++++++---------------- RESOURCE/INI/ALIASES/sound_alias.ini | 3 ++ 2 files changed, 29 insertions(+), 36 deletions(-) diff --git a/PROGRAM/dialog.c b/PROGRAM/dialog.c index a28f6de3b..40e6d816f 100644 --- a/PROGRAM/dialog.c +++ b/PROGRAM/dialog.c @@ -127,24 +127,7 @@ void StartDialogMain() DelEventHandler("frame", "StartDialogMain"); -// KK --> - CreateEntity(&Dialog, "LegacyDialog"); - if (bNewInterface) - { - Dialog.texture = "dialog/Dialg2.tga"; - } - else - { - if (DIALOGCOLOUR == 1) - { - Dialog.texture = "dialog/Dialg1.tga"; - } - else - { - Dialog.texture = "dialog/dialog.tga"; - } - } -// KK <-- + CreateDialog(); Log_SetActiveAction("Nothing");//MAXIMUS LogsVisible(false); // KK @@ -262,24 +245,9 @@ void SelfDialog(ref Character) //Запускаем диалог Dialog.CurrentNode = CharacterRef.Dialog.CurrentNode; //Trace("SelfDialog: dialog path for self character <" + Character.id + "> = " + FullDialogPath); -// KK --> - CreateEntity(&Dialog, "LegacyDialog"); - if (bNewInterface) - { - Dialog.texture = "dialog/Dialg2.tga"; - } - else - { - if (DIALOGCOLOUR == 1) - { - Dialog.texture = "dialog/Dialg1.tga"; - } - else - { - Dialog.texture = "dialog/dialog.tga"; - } - } -// <-- KK + + CreateDialog(); + Log_SetActiveAction("Nothing");//MAXIMUS LogsVisible(false); // KK Dialog.headModel = CharacterRef.headModel; // KK @@ -865,3 +833,25 @@ void DialogCorpseExit(ref char) if(DIALOG_CAMERA>0.0) locCameraFollow();//MAXIMUS } //MAXIMUS <-- + +void CreateDialog() +{ + CreateEntity(&Dialog, "LegacyDialog"); + if (bNewInterface) + { + Dialog.texture = "dialog/Dialg2.tga"; + } + else + { + if (DIALOGCOLOUR == 1) + { + Dialog.texture = "dialog/Dialg1.tga"; + } + else + { + Dialog.texture = "dialog/dialog.tga"; + } + } + + Dialog.tickSound = "dialog_tick"; +} diff --git a/RESOURCE/INI/ALIASES/sound_alias.ini b/RESOURCE/INI/ALIASES/sound_alias.ini index a51d8ac40..ca0f9c274 100644 --- a/RESOURCE/INI/ALIASES/sound_alias.ini +++ b/RESOURCE/INI/ALIASES/sound_alias.ini @@ -1819,3 +1819,6 @@ maxDistance = 3.0 volume = 0.3 name = NATURE\cricket.wav name = NATURE\cricket2.wav + +[dialog_tick] +name = interface\ok.flac