Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Skio on Fri 21/05/2004 21:15:55

Title: changing the name of a character
Post by: Skio on Fri 21/05/2004 21:15:55
Can I dynamically change the full name of the character?

EXAMPLE: Player points on a character and the status bar reads MAN.
Player talks to MAN and asks his name. When he points to the character again, the status bar reads the name instead of MAN.

NOTE: I have tried to use the "character[player].name=..." variable inside an interaction event but I got no effect.
Did I used it wrong?
Title: Re: changing the name of a character
Post by: Scorpiorus on Fri 21/05/2004 21:59:34
Make a use of a StrCopy() function:

StrCopy(character[player].name, "his new name");
Title: Re: changing the name of a character
Post by: TerranRich on Sat 22/05/2004 05:20:00
This function must be used to set all strings to a value. NEVER use the "=" command.
Title: Re: changing the name of a character
Post by: Skio on Sun 23/05/2004 21:06:17
Thanks guys