Sha256: f7422d620e9c353d446c42be3d780a3f58d61b395c675c8f95eebad5da2c432f
Contents?: true
Size: 1018 Bytes
Versions: 3
Compression:
Stored size: 1018 Bytes
Contents
Gamefic.script do respond :take, Use.text do |actor, text| actor.tell "You don't see any \"#{text}\" here." end respond :take, Use.available do |actor, thing| if thing.parent == actor actor.tell "You're already carrying #{the thing}." elsif thing.portable? if actor.parent != thing.parent actor.tell "You take #{the thing} from #{the thing.parent}." else actor.tell "You take #{the thing}." end thing.parent = actor else actor.tell "You can't take #{the thing}." end end respond :take, Use.available(:attached?) do |actor, thing| actor.tell "#{The thing} is attached to #{the thing.parent}." end respond :take, Use.available(Rubble) do |actor, rubble| actor.tell "You don't have any use for #{the rubble}." end interpret "get :thing", "take :thing" interpret "pick up :thing", "take :thing" interpret "pick :thing up", "take :thing" interpret "carry :thing", "take :thing" end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
gamefic-standard-2.2.0 | lib/gamefic-standard/actions/take.rb |
gamefic-standard-2.1.0 | lib/gamefic-standard/actions/take.rb |
gamefic-standard-2.0.0 | lib/gamefic-standard/actions/take.rb |