Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: DrakeStoel on Mon 23/07/2012 21:33:57

Title: Inventory turns on dialog
Post by: DrakeStoel on Mon 23/07/2012 21:33:57
I'm trying to make different options appear for my dialog depending on what inventory items I have, but I keep getting the error "undefined token 'option'" I'm not sure how to fix this. Here's my script:
Code (AGS) Select
// Dialog script file
@S  // Dialog startup entry point
  if (player.HasInventory (iBarrel))
  {
    option-on 1
  }

Anyone's help would be appreciated :grin:
Title: Re: Inventory turns on dialog
Post by: Deu2000 on Mon 23/07/2012 21:56:34
Code (AGS) Select
// Dialog script file
@S  // Dialog startup entry point
  if (player.HasInventory (iBarrel))
  {
option-on 1
  }


The error: you tabulated before the dialog script. When you tabulate, it means it's a script command.

PM: Sorry for my crashing english :(
Title: Re: Inventory turns on dialog
Post by: DrakeStoel on Mon 23/07/2012 22:01:57
Well, that sure fixed it right up! Thanks a bunch!