ifmapper 0.9.8 → 0.9.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -72,6 +72,7 @@ class InformWriter
72
72
  return new_tag(elem, name)
73
73
  end
74
74
 
75
+
75
76
  def wrap_text(text, width = 65, indent = 79 - width)
76
77
  return 'UNDER CONSTRUCTION' unless text
77
78
  str = inform_quote( text.dup )
@@ -80,10 +81,7 @@ class InformWriter
80
81
  r = ''
81
82
  while str
82
83
  idx = str.rindex(/[ -]/, width)
83
- unless idx
84
- idx = str.index(/[ -]/, width)
85
- idx = str.size unless idx
86
- end
84
+ idx = str.size unless idx
87
85
  r << str[0..idx]
88
86
  str = str[idx+1..-1]
89
87
  r << "\n" << ' ' * indent if str
@@ -343,7 +341,7 @@ EOF
343
341
  'description',
344
342
  ] + DIRECTIONS
345
343
 
346
- @keyword = /^#{keywords.join('|')}$/i
344
+ @keyword = /^(?:#{keywords.join('|')})$/i
347
345
  start
348
346
  end
349
347
  end
data/lib/IFMapper/Room.rb CHANGED
@@ -43,7 +43,8 @@ class Room
43
43
  @y = vars.shift
44
44
  if not vars.empty? and vars[0].kind_of?(String)
45
45
  @desc = vars.shift
46
- @desc.sub!(/\n/, ' ')
46
+ @desc.gsub!(/(\w)\s*\n/, '\1 ')
47
+ @desc.sub!(/\n+$/, '')
47
48
  @desc.strip!
48
49
  end
49
50
  end
@@ -88,10 +88,7 @@ class TADSWriter
88
88
  r = ''
89
89
  while str
90
90
  idx = str.rindex(/[ -]/, width)
91
- unless idx
92
- idx = str.index(/[ -]/, width)
93
- idx = str.size unless idx
94
- end
91
+ idx = str.size unless idx
95
92
  r << str[0..idx]
96
93
  str = str[idx+1..-1]
97
94
  r << "\n" << ' ' * indent if str
@@ -85,7 +85,7 @@ class TranscriptReader
85
85
  NAME_MAXWORDS = 20
86
86
 
87
87
  # word list that may be uncapitalized in room name
88
- NAME_UNCAP = /^(?:of|on|to|with|by|a|in|the|at|under)$/i
88
+ NAME_UNCAP = /^(?:of|on|to|with|by|a|in|the|at|under|through|near)$/i
89
89
 
90
90
  # Default room description recognition parameters.
91
91
  DESC_MINWORDS = 20
@@ -570,6 +570,8 @@ class TranscriptReader
570
570
  debug "ENDS AT: #{name}"
571
571
 
572
572
  desc = room[:desc]
573
+ desc.gsub!(/(\w)\s*\n/, '\1 ')
574
+
573
575
  line = move[:line]
574
576
 
575
577
  # If we teleported, try to find room
data/maps/A New Life.map CHANGED
Binary file
data/maps/Bronze.map ADDED
Binary file
Binary file
Binary file
data/maps/anchor.map CHANGED
Binary file
data/maps/kaged.map ADDED
Binary file
Binary file
data/maps/simple.map ADDED
Binary file
data/maps/zerosum.map CHANGED
Binary file
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
- rubygems_version: 0.8.10
2
+ rubygems_version: 0.8.11
3
3
  specification_version: 1
4
4
  name: ifmapper
5
5
  version: !ruby/object:Gem::Version
6
- version: 0.9.8
7
- date: 2006-03-13
6
+ version: 0.9.9
7
+ date: 2006-06-19 00:00:00 -03:00
8
8
  summary: Interactive Fiction Mapping Tool.
9
9
  require_paths:
10
- - lib
10
+ - lib
11
11
  email: ggarram@advance.dsl.com.ar
12
12
  homepage: http://www.rubyforge.org/projects/ifmapper/
13
13
  rubyforge_project: ifmapper
@@ -18,239 +18,247 @@ bindir: bin
18
18
  has_rdoc: true
19
19
  required_ruby_version: !ruby/object:Gem::Version::Requirement
20
20
  requirements:
21
- -
22
- - ">="
23
- - !ruby/object:Gem::Version
24
- version: 1.8.0
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: 1.8.0
25
24
  version:
26
25
  platform: ruby
26
+ signing_key:
27
+ cert_chain:
27
28
  authors:
28
- - Gonzalo Garramuno
29
+ - Gonzalo Garramuno
29
30
  files:
30
- - IFMapper.rbw
31
- - bin/IFMapper
32
- - lib/IFMapper/FXSpline.rb
33
- - lib/IFMapper/FXRoom.rb
34
- - lib/IFMapper/FXSectionDialogBox.rb
35
- - lib/IFMapper/FXConnection.rb
36
- - lib/IFMapper/FXMapColorBox.rb
37
- - lib/IFMapper/IFMReader.rb
38
- - lib/IFMapper/FXWarningBox.rb
39
- - lib/IFMapper/IFMWriter.rb
40
- - lib/IFMapper/FXMapperSettings.rb
41
- - lib/IFMapper/AStar.rb
42
- - lib/IFMapper/Connection.rb
43
- - lib/IFMapper/FXDCPostscript.rb
44
- - lib/IFMapper/MapPrinting.rb
45
- - lib/IFMapper/FXDCPrint.rb
46
- - lib/IFMapper/Room.rb
47
- - lib/IFMapper/FXMapDialogBox.rb
48
- - lib/IFMapper/InformReader.rb
49
- - lib/IFMapper/InformWriter.rb
50
- - lib/IFMapper/FXSection.rb
51
- - lib/IFMapper/TADSReader.rb
52
- - lib/IFMapper/GUEReader.rb
53
- - lib/IFMapper/FXMapFileDialog.rb
54
- - lib/IFMapper/FXRoomDialogBox.rb
55
- - lib/IFMapper/FXConnectionDialogBox.rb
56
- - lib/IFMapper/MapReader.rb
57
- - lib/IFMapper/FXRoomList.rb
58
- - lib/IFMapper/FXAboutDialogBox.rb
59
- - lib/IFMapper/FXSearchDialogBox.rb
60
- - lib/IFMapper/TADSWriter.rb
61
- - lib/IFMapper/FXMap.rb
62
- - lib/IFMapper/Section.rb
63
- - lib/IFMapper/Map.rb
64
- - lib/IFMapper/TranscriptDialogBox.rb
65
- - lib/IFMapper/TranscriptReader.rb
66
- - lib/IFMapper/FXMapperWindow.rb
67
- - lib/IFMapper/PDFMapExporter.rb
68
- - maps/Zork_Zero.ifm
69
- - maps/anchor.ifm
70
- - maps/atrox.ifm
71
- - maps/awaken.ifm
72
- - maps/babel.ifm
73
- - maps/bse.ifm
74
- - maps/Bureaucracy.ifm
75
- - maps/change.ifm
76
- - maps/curses.ifm
77
- - maps/curves.ifm
78
- - maps/edifice.ifm
79
- - maps/frozen.ifm
80
- - maps/glow.ifm
81
- - maps/Hollywood_Hijinx.ifm
82
- - maps/Jigsaw.ifm
83
- - maps/LGOP.ifm
84
- - maps/library.ifm
85
- - maps/Mercy.ifm
86
- - maps/mindelec.ifm
87
- - maps/minster.ifm
88
- - maps/muse.ifm
89
- - maps/paperchase.ifm
90
- - maps/Planetfall.ifm
91
- - maps/Plundered_Hearts.ifm
92
- - maps/Ralph.ifm
93
- - maps/Robots_of_Dawn.ifm
94
- - maps/Seastalker.ifm
95
- - maps/Sherlock.ifm
96
- - maps/SoFar.ifm
97
- - maps/space_st.ifm
98
- - maps/Starcross.ifm
99
- - maps/stationfall.ifm
100
- - maps/Suspended.ifm
101
- - maps/theatre.ifm
102
- - maps/toonesia.ifm
103
- - maps/tortoise.ifm
104
- - maps/vgame.ifm
105
- - maps/weather.ifm
106
- - maps/windhall.ifm
107
- - maps/Wishbringer2.ifm
108
- - maps/Wishbringer.ifm
109
- - maps/zebulon.ifm
110
- - maps/Zork1.ifm
111
- - maps/Zork2.ifm
112
- - maps/Zork3.ifm
113
- - maps/deadline.map
114
- - maps/lurkinghorror.map
115
- - maps/DDIV.map
116
- - maps/muldoon_legacy.map
117
- - maps/bluechairs.map
118
- - maps/inhumane.map
119
- - maps/ballerina.map
120
- - maps/sherbet.map
121
- - maps/delusions.map
122
- - maps/zdungeon.map
123
- - maps/Bureaucracy.map
124
- - maps/Tangle.map
125
- - maps/spring.map
126
- - maps/trinity.map
127
- - maps/slouch.map
128
- - maps/pawn.map
129
- - maps/anchor.map
130
- - maps/risorgimento.map
131
- - maps/christminster.map
132
- - maps/AllRoads.map
133
- - maps/CityOfSecrets.map
134
- - maps/pytho.map
135
- - maps/eas.map
136
- - maps/eas2.map
137
- - maps/eas3.map
138
- - maps/worlds.map
139
- - maps/SavoirFare.map
140
- - maps/Heroine.map
141
- - maps/metamorphoses.map
142
- - maps/break_in.map
143
- - maps/moonmist.map
144
- - maps/dreamhold.map
145
- - maps/AMFV.map
146
- - maps/wasp.map
147
- - maps/Janitor.map
148
- - maps/bear.map
149
- - maps/zerosum.map
150
- - maps/balances.map
151
- - maps/fallacy.map
152
- - maps/heist.map
153
- - maps/pkgirl.map
154
- - maps/heroes.map
155
- - maps/photograph.map
156
- - maps/drift3.map
157
- - maps/party.map
158
- - maps/devours.map
159
- - maps/djinni.map
160
- - maps/A New Life.map
161
- - maps/History Repeating.map
162
- - maps/Unforgotten.map
163
- - maps/splashdown.map
164
- - maps/xtcontest.map
165
- - maps/vespers.map
166
- - maps/distress.map
167
- - maps/building.map
168
- - maps/gamlet.map
169
- - maps/squarecircle.map
170
- - maps/guilty_bastards.map
171
- - icons/filenew.png
172
- - icons/fileopen.png
173
- - icons/filesave.png
174
- - icons/filesaveas.png
175
- - icons/cut.png
176
- - icons/copy.png
177
- - icons/paste.png
178
- - icons/help.png
179
- - icons/kill.png
180
- - icons/redo.png
181
- - icons/saveas.png
182
- - icons/undo.png
183
- - icons/zoom.png
184
- - icons/winapp.png
185
- - icons/printicon.png
186
- - icons/prevpage.png
187
- - icons/nextpage.png
188
- - icons/room_n.xpm
189
- - icons/room_nw.xpm
190
- - icons/room_ne.xpm
191
- - icons/room_se.xpm
192
- - icons/room_sw.xpm
193
- - icons/room_s.xpm
194
- - icons/room_w.xpm
195
- - icons/room_e.xpm
196
- - icons/room_n.gif
197
- - icons/room_s.gif
198
- - icons/room_sw.gif
199
- - icons/room_se.gif
200
- - icons/room_ne.gif
201
- - icons/room_nw.gif
202
- - icons/room_e.gif
203
- - icons/room_w.gif
204
- - HISTORY.txt
205
- - TODO.txt
206
- - docs/start.html~
207
- - docs/index.html
208
- - docs/images
209
- - docs/start.html
210
- - docs/images/IFMapper_main.gif
211
- - docs/images/room_description.gif
212
- - docs/images/room_small.gif
213
- - docs/images/connection.gif
214
- - docs/images/connection_menu.gif
215
- - docs/images/complex_connection.gif
216
- - docs/images/automap.gif
31
+ - IFMapper.rbw
32
+ - bin/IFMapper
33
+ - lib/IFMapper/FXSpline.rb
34
+ - lib/IFMapper/FXRoom.rb
35
+ - lib/IFMapper/FXSectionDialogBox.rb
36
+ - lib/IFMapper/FXConnection.rb
37
+ - lib/IFMapper/FXMapColorBox.rb
38
+ - lib/IFMapper/IFMReader.rb
39
+ - lib/IFMapper/FXWarningBox.rb
40
+ - lib/IFMapper/IFMWriter.rb
41
+ - lib/IFMapper/FXMapperSettings.rb
42
+ - lib/IFMapper/AStar.rb
43
+ - lib/IFMapper/Connection.rb
44
+ - lib/IFMapper/FXDCPostscript.rb
45
+ - lib/IFMapper/MapPrinting.rb
46
+ - lib/IFMapper/FXDCPrint.rb
47
+ - lib/IFMapper/FXMapDialogBox.rb
48
+ - lib/IFMapper/InformReader.rb
49
+ - lib/IFMapper/FXSection.rb
50
+ - lib/IFMapper/TADSReader.rb
51
+ - lib/IFMapper/GUEReader.rb
52
+ - lib/IFMapper/FXRoomDialogBox.rb
53
+ - lib/IFMapper/FXConnectionDialogBox.rb
54
+ - lib/IFMapper/MapReader.rb
55
+ - lib/IFMapper/FXAboutDialogBox.rb
56
+ - lib/IFMapper/FXSearchDialogBox.rb
57
+ - lib/IFMapper/Section.rb
58
+ - lib/IFMapper/Map.rb
59
+ - lib/IFMapper/TranscriptDialogBox.rb
60
+ - lib/IFMapper/PDFMapExporter.rb
61
+ - lib/IFMapper/FXRoomList.rb
62
+ - lib/IFMapper/FXMap.rb
63
+ - lib/IFMapper/FXMapFileDialog.rb
64
+ - lib/IFMapper/Room.rb
65
+ - lib/IFMapper/TranscriptReader.rb
66
+ - lib/IFMapper/InformWriter.rb
67
+ - lib/IFMapper/TADSWriter.rb
68
+ - lib/IFMapper/Inform7Writer.rb
69
+ - lib/IFMapper/FXMapperWindow.rb
70
+ - maps/Zork_Zero.ifm
71
+ - maps/anchor.ifm
72
+ - maps/atrox.ifm
73
+ - maps/awaken.ifm
74
+ - maps/babel.ifm
75
+ - maps/bse.ifm
76
+ - maps/Bureaucracy.ifm
77
+ - maps/change.ifm
78
+ - maps/curses.ifm
79
+ - maps/curves.ifm
80
+ - maps/edifice.ifm
81
+ - maps/frozen.ifm
82
+ - maps/glow.ifm
83
+ - maps/Hollywood_Hijinx.ifm
84
+ - maps/Jigsaw.ifm
85
+ - maps/LGOP.ifm
86
+ - maps/library.ifm
87
+ - maps/Mercy.ifm
88
+ - maps/mindelec.ifm
89
+ - maps/minster.ifm
90
+ - maps/muse.ifm
91
+ - maps/paperchase.ifm
92
+ - maps/Planetfall.ifm
93
+ - maps/Plundered_Hearts.ifm
94
+ - maps/Ralph.ifm
95
+ - maps/Robots_of_Dawn.ifm
96
+ - maps/Seastalker.ifm
97
+ - maps/Sherlock.ifm
98
+ - maps/SoFar.ifm
99
+ - maps/space_st.ifm
100
+ - maps/Starcross.ifm
101
+ - maps/stationfall.ifm
102
+ - maps/Suspended.ifm
103
+ - maps/theatre.ifm
104
+ - maps/toonesia.ifm
105
+ - maps/tortoise.ifm
106
+ - maps/vgame.ifm
107
+ - maps/weather.ifm
108
+ - maps/windhall.ifm
109
+ - maps/Wishbringer2.ifm
110
+ - maps/Wishbringer.ifm
111
+ - maps/zebulon.ifm
112
+ - maps/Zork1.ifm
113
+ - maps/Zork2.ifm
114
+ - maps/Zork3.ifm
115
+ - maps/deadline.map
116
+ - maps/lurkinghorror.map
117
+ - maps/DDIV.map
118
+ - maps/muldoon_legacy.map
119
+ - maps/bluechairs.map
120
+ - maps/inhumane.map
121
+ - maps/ballerina.map
122
+ - maps/sherbet.map
123
+ - maps/delusions.map
124
+ - maps/zdungeon.map
125
+ - maps/Bureaucracy.map
126
+ - maps/Tangle.map
127
+ - maps/spring.map
128
+ - maps/trinity.map
129
+ - maps/slouch.map
130
+ - maps/pawn.map
131
+ - maps/anchor.map
132
+ - maps/risorgimento.map
133
+ - maps/christminster.map
134
+ - maps/AllRoads.map
135
+ - maps/CityOfSecrets.map
136
+ - maps/pytho.map
137
+ - maps/eas.map
138
+ - maps/eas2.map
139
+ - maps/eas3.map
140
+ - maps/worlds.map
141
+ - maps/SavoirFare.map
142
+ - maps/Heroine.map
143
+ - maps/metamorphoses.map
144
+ - maps/break_in.map
145
+ - maps/moonmist.map
146
+ - maps/dreamhold.map
147
+ - maps/AMFV.map
148
+ - maps/wasp.map
149
+ - maps/Janitor.map
150
+ - maps/bear.map
151
+ - maps/zerosum.map
152
+ - maps/balances.map
153
+ - maps/fallacy.map
154
+ - maps/heist.map
155
+ - maps/pkgirl.map
156
+ - maps/heroes.map
157
+ - maps/photograph.map
158
+ - maps/drift3.map
159
+ - maps/party.map
160
+ - maps/devours.map
161
+ - maps/djinni.map
162
+ - maps/A New Life.map
163
+ - maps/History Repeating.map
164
+ - maps/Unforgotten.map
165
+ - maps/splashdown.map
166
+ - maps/xtcontest.map
167
+ - maps/vespers.map
168
+ - maps/distress.map
169
+ - maps/building.map
170
+ - maps/gamlet.map
171
+ - maps/squarecircle.map
172
+ - maps/guilty_bastards.map
173
+ - maps/WinterWonderland.map
174
+ - maps/kaged.map
175
+ - maps/Bronze.map
176
+ - maps/Reliques_of_Tolti_Alph.map
177
+ - maps/simple.map
178
+ - icons/filenew.png
179
+ - icons/fileopen.png
180
+ - icons/filesave.png
181
+ - icons/filesaveas.png
182
+ - icons/cut.png
183
+ - icons/copy.png
184
+ - icons/paste.png
185
+ - icons/help.png
186
+ - icons/kill.png
187
+ - icons/redo.png
188
+ - icons/saveas.png
189
+ - icons/undo.png
190
+ - icons/zoom.png
191
+ - icons/winapp.png
192
+ - icons/printicon.png
193
+ - icons/prevpage.png
194
+ - icons/nextpage.png
195
+ - icons/room_n.xpm
196
+ - icons/room_nw.xpm
197
+ - icons/room_ne.xpm
198
+ - icons/room_se.xpm
199
+ - icons/room_sw.xpm
200
+ - icons/room_s.xpm
201
+ - icons/room_w.xpm
202
+ - icons/room_e.xpm
203
+ - icons/room_n.gif
204
+ - icons/room_s.gif
205
+ - icons/room_sw.gif
206
+ - icons/room_se.gif
207
+ - icons/room_ne.gif
208
+ - icons/room_nw.gif
209
+ - icons/room_e.gif
210
+ - icons/room_w.gif
211
+ - HISTORY.txt
212
+ - TODO.txt
213
+ - docs/index.html
214
+ - docs/images
215
+ - docs/start.html
216
+ - docs/images/IFMapper_main.gif
217
+ - docs/images/room_description.gif
218
+ - docs/images/room_small.gif
219
+ - docs/images/connection.gif
220
+ - docs/images/connection_menu.gif
221
+ - docs/images/complex_connection.gif
222
+ - docs/images/automap.gif
217
223
  test_files: []
224
+
218
225
  rdoc_options: []
226
+
219
227
  extra_rdoc_files:
220
- - HISTORY.txt
221
- - TODO.txt
222
- - docs/start.html~
223
- - docs/index.html
224
- - docs/images
225
- - docs/start.html
226
- - docs/images/IFMapper_main.gif
227
- - docs/images/room_description.gif
228
- - docs/images/room_small.gif
229
- - docs/images/connection.gif
230
- - docs/images/connection_menu.gif
231
- - docs/images/complex_connection.gif
232
- - docs/images/automap.gif
228
+ - HISTORY.txt
229
+ - TODO.txt
230
+ - docs/index.html
231
+ - docs/images
232
+ - docs/start.html
233
+ - docs/images/IFMapper_main.gif
234
+ - docs/images/room_description.gif
235
+ - docs/images/room_small.gif
236
+ - docs/images/connection.gif
237
+ - docs/images/connection_menu.gif
238
+ - docs/images/complex_connection.gif
239
+ - docs/images/automap.gif
233
240
  executables: []
241
+
234
242
  extensions: []
243
+
235
244
  requirements: []
245
+
236
246
  dependencies:
237
- - !ruby/object:Gem::Dependency
238
- name: fxruby
239
- version_requirement:
240
- version_requirements: !ruby/object:Gem::Version::Requirement
241
- requirements:
242
- -
243
- - ">="
244
- - !ruby/object:Gem::Version
245
- version: 1.2.16
246
- version:
247
- - !ruby/object:Gem::Dependency
248
- name: pdf-writer
249
- version_requirement:
250
- version_requirements: !ruby/object:Gem::Version::Requirement
251
- requirements:
252
- -
253
- - ">="
254
- - !ruby/object:Gem::Version
255
- version: 1.1.1
256
- version:
247
+ - !ruby/object:Gem::Dependency
248
+ name: fxruby
249
+ version_requirement:
250
+ version_requirements: !ruby/object:Gem::Version::Requirement
251
+ requirements:
252
+ - - ">="
253
+ - !ruby/object:Gem::Version
254
+ version: 1.2.16
255
+ version:
256
+ - !ruby/object:Gem::Dependency
257
+ name: pdf-writer
258
+ version_requirement:
259
+ version_requirements: !ruby/object:Gem::Version::Requirement
260
+ requirements:
261
+ - - ">="
262
+ - !ruby/object:Gem::Version
263
+ version: 1.1.1
264
+ version: