diff --git a/package.json b/package.json index 4c0b8d3..4cba523 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "salet", - "version": "1.7.6", + "version": "1.7.7", "description": "A general client-side framework for cybertext interactive fiction games.", "keywords": ["ifiction", "interactive fiction", "games", "coffee-script", "text", "menu"], "homepage": "https://salet.su", diff --git a/src/character.coffee b/src/character.coffee index 9235564..ee23447 100644 --- a/src/character.coffee +++ b/src/character.coffee @@ -21,7 +21,7 @@ class Character @listinv = (thing) => for i in @inventory if i.name == thing - return invlink(i.display, i.name) + return invlink(i.display.fcall(i), i.name) @inv = (thing) => for i in @inventory diff --git a/src/unit.coffee b/src/unit.coffee index 4d91f17..2b1c86e 100644 --- a/src/unit.coffee +++ b/src/unit.coffee @@ -15,10 +15,10 @@ class SaletUnit return parsedsc(text, @name) @takeable = false @display = "" - @take = () => "You take the #{@display}." # taking to inventory - @act = () => "You don't find anything extraordinary about the #{@display}." # unit action - @dsc = () => "You see a {{#{@display}}} here." # unit description - @inv = () => "It's a #{@display}." # inventory description + @take = () => "You take the #{@display.fcall(@)}." # taking to inventory + @act = () => "You don't find anything extraordinary about the #{@display.fcall(@)}." # unit action + @dsc = () => "You see a {{#{@display.fcall(@)}}} here." # unit description + @inv = () => "It's a #{@display.fcall(@)}." # inventory description @location = "" @put = (location) => if salet.rooms[location]?