Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: rbaleksandar on Sun 30/03/2008 12:13:18

Title: Cutscenes Opening a window (SOLVED)
Post by: rbaleksandar on Sun 30/03/2008 12:13:18
Okay, yet another dull question :)

I want the following. We have a room (e.g. a street and a house). The house has a window (and a door :)). My character stands on the street in front of the house. My question is - how can I make a cutscene for examlpe, in which my character opens one of the windows and enters the house? How can I make an animation of opening the window? I don't think that this is a kind of background animation or?
When I click "interact", I want my character to go to the window (that's easy), open the window (?) and enter the house.

Please, help :)
Title: Re: Cutscenes Opening a window
Post by: Akatosh on Sun 30/03/2008 13:41:33
That's rather easy. All you will need are the Object.Animate (http://americangirlscouts.org/agswiki/index.php?title=Object_functions_and_properties#Object.Animate) and Character.Animate (http://americangirlscouts.org/agswiki/index.php?title=Character_functions_and_properties#Character.Animate) functions. It's all explained there. Good luck!
Title: Re: Cutscenes Opening a window
Post by: rbaleksandar on Sun 30/03/2008 16:09:54
Ok, but how do I make the window to open? I think of only one way, and that is the following:

The character goes to the house and to the window. Than the animation starts by repleacing the current character view with another one but this time with a window in it. So I have to create a new loop in which both character and the window are displayed, replace the current character view with this animation and place it somewhere on the screen (here the wall of the house)? Am I right?

PS: Thanks for answering  ;D
Title: Re: Cutscenes Opening a window
Post by: ryanlandry on Sun 30/03/2008 20:46:28
you wouldn't put the window in the character loop. you would use an "object" for the window, and have an animation (view, loop) for that object, as well as one of the character "opening" the window. If your background shows the window as closed, then you have your window object animate over top of it, so that when it's done the closed window of the background is covered up by the open window of the object. hope that makes sense...
Title: Re: Cutscenes Opening a window
Post by: rbaleksandar on Mon 31/03/2008 09:35:53
Quote from: ryanlandry on Sun 30/03/2008 20:46:28
you wouldn't put the window in the character loop. you would use an "object" for the window, and have an animation (view, loop) for that object, as well as one of the character "opening" the window. If your background shows the window as closed, then you have your window object animate over top of it, so that when it's done the closed window of the background is covered up by the open window of the object. hope that makes sense...

I made it and it is cool :) Thanks a lot ;)