How to make a simple portrait dialogue?

Started by mooneon, Tue 21/02/2023 17:34:53

Previous topic - Next topic

mooneon

Hello, I know that this is been asked thousands of times but I for the life of me cannot find anything easy to understand on the forums. I'm really dumb when it comes to reading the manual and coding. This is my first time ever trying to make a click-and-point game on my own.  :cry:

I want to make a dialogue textbox appear every time a character or narrative speech appears. I don't want it to appear above the character. The textbox should also change character portraits depending on which character is speaking. - Much like the sierra-style.




What is the step-by-step of this process? Which script am I using? I understand if it's in my incompetence that I should just read and learn on my own but I spend the whole day yesterday trying to find out on my own before posting.

glurex

If I understand you correctly: for the textbox you have to create a new text GUI (in the GUI's option on Explore Project). And in Game Start function (At Global Script) set that text windows GUI. For example: "SetTextWindowGUI (X);" where X is the number of your text GUI.

For the portrait: in General Settings, Speech Style: SierraWithBackground. Later you have to set a Speech View to your character(s).

I recomend you to read the AGS Manual.


Khris

You don't even need to create a custom GUI for this, at least not initially.

Go to General Settings -> Dialog and change the SpeechStyle to "SierraWithBackground" like glurex said.
AGS will now display speech in the standard message GUI, next to a portrait that is animated using the character's speech view.

To fine-tune this, put suitable portrait sprites in the speech view instead of whole character sprites. You'll also want to pick a non-outline font as the speech font (inside the Global Script's game_start function):
Code: ags
  Game.SpeechFont = eFontStandard;

To further customize the appearance, you can now also use a custom TextWindowGUI.

SMF spam blocked by CleanTalk