Hi there, I'm trying to get default sound to the code using default sound for doors.
I see there's default values but I don't get it where I need to change that.
// Default door sounds
AudioClip* openDoorSound,
closeDoorSound,
unlockDoorSound;
I've already created those sounds with script names and the only way that I could use those sounds is inside AnyClickSpecial to set the value to the particular sound.
I don't know if I'm doing it incorrectly.
static int Doors::AnyClickSpecial(int door_id, int obj, int x, int y, CharacterDirection dir, int nr_room, int nr_x, int nr_y, CharacterDirection nr_dir, AudioClip *opensound, AudioClip *closesound, int key, int closevalue) {
// key = -1: masterkey - even locked doors will be opened
// key = -2: door can't be unlocked (like rusted)
AudioChannel *chan;
int result=1;
verbsData.openDoorSound = openDoorSound;
verbsData.closeDoorSound = closeDoorSound;
verbsData.unlockDoorSound = unlockDoorSound;
Any help is welcome.
Thanks all
Go to the game_start function in the VerbGUI script (VerbGui.asc).
In there, append lines like
verbsData.openDoorSound = aMyCustomOpenDoorSound;
etc.
Appreciate your help Khris. That was exactly what I wanted to do. Thread can be closed.