Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: rmonic79 on Thu 29/01/2015 19:23:52

Title: Cutscene simulating gameplay
Post by: rmonic79 on Thu 29/01/2015 19:23:52
Hello guys i wanna do something like MI1 governor's house selecting actions and objects automatically  and even moving the cursor around. Is it possible?
Title: Re: Cutscene simulating gameplay
Post by: Retro Wolf on Thu 29/01/2015 19:31:31
You could make a character with the exact same sprite as the cursor, then have it "walk" to wherever you want it to on the screen.
You might run into problems if the "cursor" needs to "click" on the GUI, you would have to do something fancy with drawing the sprite over the GUI (or have a fake duplicate GUI?).

Someone will probably come along with a better idea though.
Title: Re: Cutscene simulating gameplay
Post by: Snarky on Thu 29/01/2015 21:29:54
The other thing you can do is to move the actual mouse cursor around with Mouse.SetPosition(). But you have to make sure the user can't interfere by providing input with the real mouse. I think if you use Mouse.SetBounds() so the mouse can't move from the position you specify (you'll have to update it whenever you want to move the cursor, of course), and put a test in the click-handling code to ignore any mouseclicks while you're in "playback mode", that should do it.

Doing it with a character is probably easier, unless you need to do GUI/inventory stuff and your UI has a lot of complicated scripting that is difficult to simulate.
Title: Re: Cutscene simulating gameplay
Post by: rmonic79 on Fri 30/01/2015 17:23:57
Thanks i'll give it a try ;)