ACI version 3.21.1115)
Crash Error:
Crossfade Out channel is 8 but the channel is gone.
It's a problem after the conversion
from 3.0.1 to 3.2.1.I'm... I'm guessing the problem is something about different sounds... but I don't know why crashes.
I will dump yo all the script, with green the scripts that works perfectly, and in red the script that crashes.. Cause you will see that they uses the same sound:
Quote
function room_Load()
{
aMusic17.Play();
if (IntVar_Huida == 1) object[0].SetView(50,0);
if (IntVar_Huida == 2) object[0].SetView(50,1);
if (IntVar_Huida == 3) object[0].SetView(50,2);
if (IntVar_Huida == 4) object[0].SetView(50,3);
}
function room_AfterFadeIn()
{
if (IntVar_Huida == 1) // Huida en caza civil
{
IntVar_Tipodemuerte = 4;
object[0].Move(170,137, 3, eBlock, eAnywhere);
cCt.ChangeRoom(12, 2000, 2000);
cCt.Say("Atención, caza civil, identifÃquese inmediatamente o sera abatido, el Crucero está en alerta roja de huÃda");
cEgo.Say("Mierda... con esta chatarra no podré llegar muy lejos");
object[0].Move(240, 182, 4, eNoBlock, eAnywhere);
Wait(10);
PlaySound(19);
Wait(20);
PlaySound(19);
Wait(50);
player.ChangeRoom(95, 2000, 2000);
}
if (IntVar_Huida == 2) // huida en transporte de carga
{
IntVar_Tipodemuerte = 4;
object[0].Move(170,137, 2, eBlock, eAnywhere);
cCt.ChangeRoom(12, 2000, 2000);
cCt.Say("Atención, transporte; indique la carga y la destinación");
cEgo.Say("Ahem.... Provisiones de munición para los cruceros escolta");
cCt.Say("Buen intento, fugitiva, pero no se permite la salida de transportes de carga cuando el Crucero esta en alerta roja por huÃda");
Display("Te aferras a los mandos y das máxima potencia al Transporte, pero como no tiene capacidad de salto ni niguna otra nave a la que huir...");
object[0].Move(240, 182, 3, eNoBlock, eAnywhere);
Wait(10);
PlaySound(19);
Wait(20);
PlaySound(19);
Wait(50);
player.ChangeRoom(95, 2000, 2000);
}
if (IntVar_Huida == 3) // HUIDA CON SPHYNX
{
IntVar_Tipodemuerte = 4;
object[0].Move(170,137, 3, eBlock, eAnywhere);
cCt.ChangeRoom(12, 2000, 2000);
cCt.Say("¡Atención caza Sphynx! ¡No tiene autorización para despegar!");
cEgo.Say("Maldición, ahà os quedais, chicos, Espero que estos nuevos cazas sean realmente rapidos");
object[0].Move(240, 182, 4, eNoBlock, eAnywhere);
Wait(10);
PlaySound(19);
Wait(20);
PlaySound(19);
Wait(30);
PlaySound(19);
Display("Pero parece que la capacidad de maniobra de un Sphynx era mucho menor que la de un U-figther o incluso un Hermes, con el que quizás hubieras escapado con vida...");
player.ChangeRoom(95, 2000, 2000);
}
if (IntVar_Huida == 4) // HUIDA CON HERMES
{
object[0].Move(170,137, 3, eBlock, eAnywhere);
cCt.ChangeRoom(12, 2000, 2000);
cCt.Say("¡Alto ahà caza Hermes! ¡No tiene autorización para despegar!");
cEgo.Say("Jajaja, pues lo lleváis claro si creéis que me vais a dar con esas torretas; ¡Nos vemos!");
object[0].Move(400, 300, 6, eNoBlock, eAnywhere);
Wait(10);
PlaySound(19);
Wait(20);
PlaySound(19);
Wait(50);
PlaySound(19);
Wait(100);
player.ChangeRoom(13, 148, 117);
}
}
I repeat to say, that the Sound and the music works in all the green parts of the script, but BEFORE the sound plays in the red script, the game crash with the window:
Crossfade Out channel is 8 but the channel is gone.thank you for helping!
Nobody knows what is about? If I mess around, I will finally simply let it with no sound... and is not a good solution xD
Well, currently there are a maximum of 8 AudioChannels supported in AGS so if you're hitting that limit that could be a part of it. I would suggest updating your script to the new sound system so you have greater control over what plays on which channel.
Are you suggesting that maybe when this part of the script fails, is because more or 8 sounds were playing at the same time, maybe?
I will check the new commands for sound, looking after a way to solve it, thanks!
MMm, the problem persists;
And I'm not sure if is about the sound. Anywhere says that has relation to the sound... Was only a assumption, 'cause the problem talk about "channel 8..."
sure anybody know nothing?
Yeah...crossfading and channels means sound. Are you getting the same error with the new code then?
I simple replaced the "playsound(19);" for "aSound19.Play()" and it does the exact problem... and now it crashes on all the options of this script, not only the red-colored part :S
Are your sounds (especially aSound19) long in duration? Do you have a lot of other sounds playing when that room loads? It should just fail (without error) if it can't play...doesn't make sense.
Ok, I just see that the problem is the music.
If there is no music, there is no problem. But I don't know how it can be the problem.
Anyway, after the conversion from 3.0.1 to 3.2.2, I have a lot of problems with music; a lot of times the music stops when a sound is triggered... I think I would have to set the new propierties of all music clips.. arj, and see If I fix the errors!
Thanks!