Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: on Thu 23/12/2004 13:44:51

Title: How can a label display a string or a value returned by a function?
Post by: on Thu 23/12/2004 13:44:51
I'd want a label on a GUI to display the name of the item selected in the list
How can I do this?
I thought to use game.inv_activated to get the number of the item clicked and then to use GetInvName to get the item name
But how can a label display the item name?

Can I make an inventory with a list of the item names instead of their icon???
I'd also want that the player could choose one of these items by clicking to see the informations about it in a label...
Title: Re: How can a label display a string or a value returned by a function?
Post by: Ishmael on Thu 23/12/2004 14:33:46
Look into SetLabelText text script command. It lets you set the text of a GUI label, and to format the text to your liking use StrFormat text script command.