Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

It is a matter of style but I'd personally favour one of three approaches

  1. Put EVERYTHING in on_command {} block. All examine logic for objects AND general location logic goes in here, nowhere else.
  2. Add a : gosub "examine_messages" ; to the on_command{} block and put everything in a new subroutine called "examine_messages". All examine logic for objects AND general location logic goes in here, nowhere else.
  3. Put all examine per-object examine logic in the objects definitions themselves, and put all per-location examine logic in the locations themselves.
   lamp : object "a lamp" {
      start_at = my_location
      on_examine {
         : print "Hello" ;
         : done ;
      }
   }