Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

I don't think you understand. I don't want twine to be recognised at all when it's not in scope. The ball you read about in the book is a completely different ball. It's a rubber ball. It's NOT the ball of twine. You cannot read about the ball of twine in the book.

You're right, I don't understand. You are going to have to simplify it for me, because as I understand it, Adventuron is acting as-designed.

If the rubber ball is a different ball, then why is it not in your code snippet? I can only understand the elements you place in the code snippet.

It's in the code snippet. The ball is NOT an object. It's a topic in the book. When you READ ABOUT BALL, you're supposed to get told about the rubber ball. Instead, you get told about the twine. I didn't ASK ABOUT TWINE. How can I possibly make it any clearer?

This ensures that "twine" is never a primary noun and "ball" is not an alias.

start_at = room
game_settings {
   add_standard_prepositions = false
   experimental_new_parser = true
}
locations {
   room : location "You are in a room.";
}
objects {
   ball : object "a ball of twine" at = "room" ;
   text_book   : object "a text book" at = "room";
}
on_command {
   : match "_ _" {
      : mask {
         : print {("^n^verb = " + original "verb")}
         : print {("^n^preposition1 = " + original "preposition1")}
         : print {("^n^noun1 = " + original "noun1")}
         : print {("^n^preposition2 = " + original "preposition2")}
         : print {("^n^noun2 = " + original "noun2" + "^m^")}
      }
   }
  : if (is_present "text_book") {
      : match "read _" {
         : if (preposition1_is "about") {
            : if (noun1_is "ball") {
               : print "It says you only need rubber to make a ball.";
               : done;
            }
            : print "There's no topic on that.";
            : done;
         }
      }
   }
}
vocabulary {
   : experimental_replace { text = "ball of twine" with = "ball" }
   : experimental_replace { text = "twine" with = "ball" }
   : preposition / aliases = [about]
   : noun / aliases = [ball]
}

You still don't get it. I want twine to be the primary noun for the twine. When I READ ABOUT BALL in the book, I don't want it to refer to the twine. I want it to refer to the topic on the rubber ball in the book.

start_at = room
game_settings {
   add_standard_prepositions = false
   experimental_new_parser = true
}
locations {
   room : location "You are in a room.";
}
objects {
   twine     : object "a ball of twine" at = "room" msg = "aaa";
   text_book : object "a text book" at = "room";
}
on_command {
   : if (is_present "twine" && noun1_is "ball") {
      : mask {
         : set_noun1 text="twine";
      }
   }
   : match "_ _" {
      : mask {
         : print {("^n^verb = " + original "verb")}
         : print {("^n^preposition1 = " + original "preposition1")}
         : print {("^n^noun1 = " + original "noun1")}
         : print {("^n^preposition2 = " + original "preposition2")}
         : print {("^n^noun2 = " + original "noun2" + "^m^")}
      }
   }
  : if (is_present "text_book") {
      : match "read _" {
         : if (preposition1_is "about") {
            : if (noun1_is "ball") {
               : print "It says you only need rubber to make a ball.";
               : done;
            }
            : print "There's no topic on that.";
            : done;
         }
      }
   }
}
vocabulary {
   : experimental_replace { text = "ball of twine" with = "twine" }
   
   : preposition / aliases = [about]
   : noun / aliases = [ball]
}

OMG. I give up. You're obsessed with the twine. Your code still doesn't work. I keep telling you, when I READ ABOUT BALL, its supposed to say, "It says you only need rubber to make a ball." Instead, it says, "There's no topic on that."