mirror of
https://gitlab.com/Oreolek/salet-module.git
synced 2024-05-24 11:58:21 +03:00
10 and 11 versions - canExit and unit descriptions
This commit is contained in:
parent
9585570b37
commit
0b692db299
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "salet",
|
||||
"version": "1.6.9",
|
||||
"version": "1.6.11",
|
||||
"description": "A general client-side framework for cybertext interactive fiction games.",
|
||||
"keywords": ["ifiction", "interactive fiction", "games", "coffee-script", "text", "menu"],
|
||||
"homepage": "http://salet.oreolek.ru",
|
||||
|
|
|
@ -58,7 +58,7 @@ class SaletRoom
|
|||
salet.rooms[f].canExit? and
|
||||
(
|
||||
salet.rooms[f].canExit == false or
|
||||
salet.rooms[f].canExit.fcall(salet.rooms[f], this) == false
|
||||
salet.rooms[f].canExit.fcall(salet.rooms[f], @name) == false
|
||||
) and
|
||||
force == false
|
||||
)
|
||||
|
@ -138,9 +138,9 @@ class SaletRoom
|
|||
)
|
||||
|
||||
for description in unitDescriptions
|
||||
retval += description.content
|
||||
retval += " "+description.content
|
||||
|
||||
return retval
|
||||
return markdown(retval)
|
||||
|
||||
###
|
||||
Places a unit in this room.
|
||||
|
|
|
@ -6,7 +6,7 @@ There is only one instance of this class.
|
|||
###
|
||||
class Salet
|
||||
constructor: (spec) ->
|
||||
@version = "1.6.6"
|
||||
@version = "1.6.11"
|
||||
@character = new Character
|
||||
|
||||
# REDEFINE THIS IN YOUR GAME
|
||||
|
|
|
@ -10,7 +10,7 @@ class SaletUnit
|
|||
@visible = true
|
||||
@look = (f) =>
|
||||
if @dsc and @dsc != "" and @visible
|
||||
text = markdown(@dsc.fcall(this, f).toString())
|
||||
text = @dsc.fcall(this, f).toString()
|
||||
# replace braces {{}} with link to _act_
|
||||
return parsedsc(text, @name)
|
||||
@takeable = false
|
||||
|
|
Loading…
Reference in a new issue