Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Gribbler on Wed 14/01/2009 13:37:57

Title: Two questions about Dialogs
Post by: Gribbler on Wed 14/01/2009 13:37:57
How to script within a dialog? For example: change character speech animation (view) during a dialog. Or how to get an item by chosing specific dialog topic? I know the commands for that actions (ChangeView, AddInventory) but just don't know how to incorporate them into dialog itself. Please do not write RTFM cause I already did...:-)
Title: Re: Two questions about Dialogs
Post by: Dualnames on Wed 14/01/2009 14:21:19
well, imagine the dialog is like this:

if you want to out functions in dialogs in the same way you do in every normal script:

http://guidetoags.blogspot.com/2009/01/dialog-request.html

if you don't want to add normal script functions:

Check manual for add-inv X//this shouldn't be idented.
Title: Re: Two questions about Dialogs
Post by: Gribbler on Wed 14/01/2009 15:23:21
I even did't realized its that easy:-) Thanks a lot!
Title: Re: Two questions about Dialogs
Post by: Shane 'ProgZmax' Stevens on Thu 15/01/2009 01:28:33
Just remember, if you want to use regular scripting inside the built in dialog editor, you need at least one space before each script so it is not recognized as regular dialog code, like:


@1

narrator:  Hello!

//now let's have the narrator say hello through a regular Display() call
//note the space in front of the call

Display("Hello!");

stop