Class: Gamefic::Script::Text

Inherits:
Base
  • Object
show all
Defined in:
lib/gamefic/script/text.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#==

Constructor Details

#initialize(path, code, absolute_path = nil) ⇒ Text

Returns a new instance of Text.



5
6
7
8
9
# File 'lib/gamefic/script/text.rb', line 5

def initialize path, code, absolute_path = nil
  @path = path
  @code = code
  @absolute_path = absolute_path || path
end

Instance Attribute Details

#absolute_pathObject (readonly)

Returns the value of attribute absolute_path.



4
5
6
# File 'lib/gamefic/script/text.rb', line 4

def absolute_path
  @absolute_path
end

#pathObject (readonly)

Returns the value of attribute path.



4
5
6
# File 'lib/gamefic/script/text.rb', line 4

def path
  @path
end

Instance Method Details

#readObject



10
11
12
# File 'lib/gamefic/script/text.rb', line 10

def read
  @code
end