Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Jim Reed on Mon 27/07/2009 16:39:02

Title: How to change button NormalGraphic?
Post by: Jim Reed on Mon 27/07/2009 16:39:02
Manual reads:
----
Example:

Display("The button's normal image is sprite %d.", btnPlay.NormalGraphic);

will display btnPlay's normal sprite number.
----

I'm a bit confused.

I have:
a GUI named "gEditorA" assigned ID 2
a button on the above mentioned GUI named "i1" assigned ID 0

I don't know how to script the change, so that the button's normal graphic changes to sprite number x.

I hope you understand my problem. Can someone please help me?
Title: Re: How to change button NormalGraphic?
Post by: Matti on Mon 27/07/2009 16:52:21
i1.NormalGraphic=x;
Title: Re: How to change button NormalGraphic?
Post by: Jim Reed on Mon 27/07/2009 16:57:22
Thanks Mr Matti!