:: StoryTitle Lock and Key: Variable in Snowman :: Start Rooms: - [[Front Room]] - [[Back Room]] :: Front Room <% if (s.key) { %> [[Exit]] <% } else { %> *Locked Door* <% } %> Rooms: - [[Back Room]] :: Back Room <% if (!s.key) { %> Items: - Pick up key <% } else { %> There is nothing here. <% } %> <% $(function() { $('.key-item').click(function() { s.key = true; $(this).replaceWith('You have a key.'); }); }); %> Rooms: - [[Front Room]] :: Exit You found the key and went through the door!