Simple Debugger

version 1/080105 by Michael Hilborn

  • Home page
  • Beginning
  • Previous
  • Next



  • Chapter: The boolean value (truth state)

    Originally, Simple Debugger provided you with a new kind of value, the boolean, which is commonly used by programmers for binary states. These are no longer available because they have been replaced by Inform's own value called the 'truth state'. For example, the following no longer works:

        The surrender flag is a boolean that varies.
        [later in our code...]
        if the surrender flag is false, say "Never give up, never surrender!";
        if the surrender flag is true, say "We surrender!";

    Instead, replace it with:

        The surrender flag is a truth state that varies.
        [later in our code...]
        if the surrender flag is false, say "Never give up, never surrender!";
        if the surrender flag is true, say "We surrender!";