Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Lukey J on Sun 12/04/2020 18:43:03

Title: Game Start Automatic Digalog
Post by: Lukey J on Sun 12/04/2020 18:43:03
Afternoon Guys,

so bsaically what im looking for is..

as soon as the game loads and after the first fade in, in the first room

the play talks - speaking the plot of the game

giving the player a task in this case to make a cup of tea

any help would be grand

Title: Re: Game Start Automatic Digalog
Post by: Slasher on Sun 12/04/2020 18:49:36
Could start dialog in 'First time enters room' function in room 1.
Title: Re: Game Start Automatic Digalog
Post by: Lukey J on Sun 12/04/2020 19:59:07
Could you give me an example of what you mean

cheers
Title: Re: Game Start Automatic Digalog
Post by: Slasher on Sun 12/04/2020 20:02:06
Code (ags) Select

function room_FirstLoad()
{
  // add what you want character to do/say
}
Title: Re: Game Start Automatic Digalog
Post by: Lukey J on Sun 12/04/2020 20:08:33
function room_FirstLoad()
{
      player.Say("I'd rather open it");
}

Didnt seem do do anything :(
Title: Re: Game Start Automatic Digalog
Post by: Slasher on Sun 12/04/2020 20:12:47
it won't if you just added the function yourself.  You need to click on the room_FirstLoad function in the room property panel.. this will show the function in script.. then add your bits..
Title: Re: Game Start Automatic Digalog
Post by: Snarky on Sun 12/04/2020 20:14:24
The function needs to be linked to the room event in the editor. You should go through the "Starting off" tutorial in the manual, in particular the sections on Hotspots and events (https://www.adventuregamestudio.co.uk/manual/acintro3.htm), and Animations and cutscenes (https://www.adventuregamestudio.co.uk/manual/acintro7.htm).
Title: Re: Game Start Automatic Digalog
Post by: Lukey J on Sun 12/04/2020 20:19:37
Got it working! thanks Guys