I've hit this problem a few times and I've done a forum search and looked at the Manual that comes with AGS - with little luck I thought I'd post it.
I have a character that changes view and animates before displaying a GUI window. The problem is I get an error saying that: 'The character could not be displayed because there were no frames in loop(no.) of view(no.).
Here is some script that the break is happening in:
{
if (cJohnny.IsCollidingWithObject(oGasleak)) {
cJohnny.LockView(34);
PlaySound(6);
cJohnny.Animate(0, 3, eOnce, eBlock, eForwards);
Wait(50);
Display("Message is displayed.");
gGUIWindow.Visible = true;
oGasleak.Visible = false;
oGas_leak2.Visible = true;
}
As I've had this problem a few times and never really understood why it happens and generally fix it by just playing around with the script until it plays ball.
i'm sure you've tried this but in case not , i have to ask.
Are there frames in View 34's Loop 0?
haha, yes of course...and if I create the loop it's crying for it just says theres no frames in the next loop...etc.
Quote from: Mark Borg on Sat 08/05/2010 05:07:50
haha, yes of course...and if I create the loop it's crying for it just says theres no frames in the next loop...etc.
Ohhh .,.. i don't know if this is the problem but check to see if you have "Run the next loop after this to make a long animation" box checked in the view window. If it is checked, uncheck it.
ahh nice try
Sadly thats not the problem, I'll ask around and if i find a solution to this outside the forum then I'll post it here.
Where's the cJohny.UnlockView function. You need to put that, that's probably the reason why this happens.
Nope even with the UnlockView function I get the error, plus I'm not sure if this is correct but I also want to hold on the last frame of that view change so I don't know if I;d want to release the view back to AGS.