fantasy 0.1.13 → 0.1.17

Sign up to get free protection for your applications and to get access to all the features.
Files changed (84) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +22 -1
  3. data/.yardopts +4 -0
  4. data/CHANGELOG.md +6 -0
  5. data/Gemfile +1 -1
  6. data/Gemfile.lock +55 -0
  7. data/README.md +14 -6
  8. data/docs/Actor.html +2737 -0
  9. data/docs/Background.html +961 -0
  10. data/docs/Camera.html +791 -0
  11. data/docs/Clock.html +753 -0
  12. data/docs/Color.html +776 -0
  13. data/docs/Coordinates.html +730 -0
  14. data/docs/Cursor.html +752 -0
  15. data/docs/Disk.html +236 -0
  16. data/docs/Draggable.html +198 -0
  17. data/docs/Fantasy.html +121 -0
  18. data/docs/Game.html +904 -0
  19. data/docs/Global.html +2791 -0
  20. data/docs/Gravitier.html +179 -0
  21. data/docs/HudImage.html +979 -0
  22. data/docs/HudText.html +1151 -0
  23. data/docs/Image.html +506 -0
  24. data/docs/Jumper.html +189 -0
  25. data/docs/Mouse.html +226 -0
  26. data/docs/MoveByCursor.html +374 -0
  27. data/docs/MoveByDirection.html +179 -0
  28. data/docs/Mover.html +305 -0
  29. data/docs/Music.html +524 -0
  30. data/docs/Shape.html +1057 -0
  31. data/docs/Sound.html +374 -0
  32. data/docs/Tilemap.html +491 -0
  33. data/docs/Tween.html +186 -0
  34. data/docs/UserInputs.html +879 -0
  35. data/docs/Utils.html +345 -0
  36. data/docs/_index.html +346 -0
  37. data/docs/class_list.html +51 -0
  38. data/docs/css/common.css +1 -0
  39. data/docs/css/full_list.css +58 -0
  40. data/docs/css/style.css +497 -0
  41. data/docs/file.CHANGELOG.html +121 -0
  42. data/docs/file.README.html +599 -0
  43. data/docs/file_list.html +61 -0
  44. data/docs/frames.html +17 -0
  45. data/docs/index.html +599 -0
  46. data/docs/js/app.js +314 -0
  47. data/docs/js/full_list.js +216 -0
  48. data/docs/js/jquery.js +4 -0
  49. data/docs/method_list.html +1931 -0
  50. data/docs/top-level-namespace.html +978 -0
  51. data/lib/fantasy/actor.rb +455 -123
  52. data/lib/fantasy/background.rb +109 -13
  53. data/lib/fantasy/base.rb +113 -1
  54. data/lib/fantasy/camera.rb +95 -11
  55. data/lib/fantasy/clock.rb +4 -2
  56. data/lib/fantasy/color.rb +158 -153
  57. data/lib/fantasy/coordinates.rb +5 -9
  58. data/lib/fantasy/cursor.rb +2 -1
  59. data/lib/fantasy/disk.rb +12 -8
  60. data/lib/fantasy/draggable.rb +22 -1
  61. data/lib/fantasy/global.rb +59 -31
  62. data/lib/fantasy/hud_image.rb +5 -3
  63. data/lib/fantasy/hud_text.rb +6 -2
  64. data/lib/fantasy/image.rb +12 -4
  65. data/lib/fantasy/includes/gravitier.rb +2 -0
  66. data/lib/fantasy/includes/jumper.rb +3 -2
  67. data/lib/fantasy/includes/log.rb +12 -0
  68. data/lib/fantasy/includes/move_by_cursors.rb +24 -15
  69. data/lib/fantasy/includes/move_by_direction.rb +2 -0
  70. data/lib/fantasy/includes/mover.rb +3 -0
  71. data/lib/fantasy/includes/user_inputs.rb +6 -0
  72. data/lib/fantasy/loop.rb +41 -44
  73. data/lib/fantasy/mouse.rb +2 -0
  74. data/lib/fantasy/music.rb +4 -2
  75. data/lib/fantasy/shape.rb +11 -2
  76. data/lib/fantasy/sound.rb +3 -1
  77. data/lib/fantasy/tilemap.rb +19 -13
  78. data/lib/fantasy/tween.rb +3 -1
  79. data/lib/fantasy/utils.rb +7 -13
  80. data/lib/fantasy/version.rb +1 -1
  81. data/lib/fantasy.rb +2 -0
  82. metadata +90 -4
  83. data/fantasy.gemspec +0 -40
  84. data/fonts/VT323-Regular.ttf +0 -0
data/docs/HudText.html ADDED
@@ -0,0 +1,1151 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Class: HudText
8
+
9
+ &mdash; Documentation by YARD 0.9.27
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="css/style.css" type="text/css" />
14
+
15
+ <link rel="stylesheet" href="css/common.css" type="text/css" />
16
+
17
+ <script type="text/javascript">
18
+ pathId = "HudText";
19
+ relpath = '';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="_index.html">Index (H)</a> &raquo;
40
+
41
+
42
+ <span class="title">HudText</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Class: HudText
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName">Object</span>
73
+
74
+ <ul class="fullTree">
75
+ <li>Object</li>
76
+
77
+ <li class="next">HudText</li>
78
+
79
+ </ul>
80
+ <a href="#" class="inheritanceTree">show all</a>
81
+
82
+ </dd>
83
+ </dl>
84
+
85
+
86
+
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+ <dl>
96
+ <dt>Defined in:</dt>
97
+ <dd>lib/fantasy/hud_text.rb</dd>
98
+ </dl>
99
+
100
+ </div>
101
+
102
+
103
+
104
+
105
+
106
+ <h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
107
+ <ul class="summary">
108
+
109
+ <li class="public ">
110
+ <span class="summary_signature">
111
+
112
+ <a href="#alignment-instance_method" title="#alignment (instance method)">#<strong>alignment</strong> &#x21d2; Object </a>
113
+
114
+
115
+
116
+ </span>
117
+
118
+
119
+
120
+
121
+
122
+
123
+
124
+
125
+
126
+
127
+
128
+
129
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute alignment.</p>
130
+ </div></span>
131
+
132
+ </li>
133
+
134
+
135
+ <li class="public ">
136
+ <span class="summary_signature">
137
+
138
+ <a href="#background_color-instance_method" title="#background_color (instance method)">#<strong>background_color</strong> &#x21d2; Object </a>
139
+
140
+
141
+
142
+ </span>
143
+
144
+
145
+
146
+
147
+
148
+
149
+
150
+
151
+
152
+
153
+
154
+
155
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute background_color.</p>
156
+ </div></span>
157
+
158
+ </li>
159
+
160
+
161
+ <li class="public ">
162
+ <span class="summary_signature">
163
+
164
+ <a href="#color-instance_method" title="#color (instance method)">#<strong>color</strong> &#x21d2; Object </a>
165
+
166
+
167
+
168
+ </span>
169
+
170
+
171
+
172
+
173
+
174
+
175
+
176
+
177
+
178
+
179
+
180
+
181
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute color.</p>
182
+ </div></span>
183
+
184
+ </li>
185
+
186
+
187
+ <li class="public ">
188
+ <span class="summary_signature">
189
+
190
+ <a href="#in_world-instance_method" title="#in_world (instance method)">#<strong>in_world</strong> &#x21d2; Object </a>
191
+
192
+
193
+
194
+ </span>
195
+
196
+
197
+
198
+
199
+
200
+
201
+
202
+
203
+
204
+
205
+
206
+
207
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute in_world.</p>
208
+ </div></span>
209
+
210
+ </li>
211
+
212
+
213
+ <li class="public ">
214
+ <span class="summary_signature">
215
+
216
+ <a href="#layer-instance_method" title="#layer (instance method)">#<strong>layer</strong> &#x21d2; Object </a>
217
+
218
+
219
+
220
+ </span>
221
+
222
+
223
+
224
+
225
+
226
+
227
+
228
+
229
+
230
+
231
+
232
+
233
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute layer.</p>
234
+ </div></span>
235
+
236
+ </li>
237
+
238
+
239
+ <li class="public ">
240
+ <span class="summary_signature">
241
+
242
+ <a href="#position-instance_method" title="#position (instance method)">#<strong>position</strong> &#x21d2; Object </a>
243
+
244
+
245
+
246
+ </span>
247
+
248
+
249
+
250
+
251
+
252
+
253
+
254
+
255
+
256
+
257
+
258
+
259
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute position.</p>
260
+ </div></span>
261
+
262
+ </li>
263
+
264
+
265
+ <li class="public ">
266
+ <span class="summary_signature">
267
+
268
+ <a href="#size-instance_method" title="#size (instance method)">#<strong>size</strong> &#x21d2; Object </a>
269
+
270
+
271
+
272
+ </span>
273
+
274
+
275
+
276
+
277
+
278
+
279
+
280
+
281
+
282
+
283
+
284
+
285
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute size.</p>
286
+ </div></span>
287
+
288
+ </li>
289
+
290
+
291
+ <li class="public ">
292
+ <span class="summary_signature">
293
+
294
+ <a href="#text-instance_method" title="#text (instance method)">#<strong>text</strong> &#x21d2; Object </a>
295
+
296
+
297
+
298
+ </span>
299
+
300
+
301
+
302
+
303
+
304
+
305
+
306
+
307
+
308
+
309
+
310
+
311
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute text.</p>
312
+ </div></span>
313
+
314
+ </li>
315
+
316
+
317
+ <li class="public ">
318
+ <span class="summary_signature">
319
+
320
+ <a href="#visible-instance_method" title="#visible (instance method)">#<strong>visible</strong> &#x21d2; Object </a>
321
+
322
+
323
+
324
+ </span>
325
+
326
+
327
+
328
+
329
+
330
+
331
+
332
+
333
+
334
+
335
+
336
+
337
+ <span class="summary_desc"><div class='inline'><p>Returns the value of attribute visible.</p>
338
+ </div></span>
339
+
340
+ </li>
341
+
342
+
343
+ </ul>
344
+
345
+
346
+
347
+
348
+
349
+ <h2>
350
+ Instance Method Summary
351
+ <small><a href="#" class="summary_toggle">collapse</a></small>
352
+ </h2>
353
+
354
+ <ul class="summary">
355
+
356
+ <li class="public ">
357
+ <span class="summary_signature">
358
+
359
+ <a href="#destroy-instance_method" title="#destroy (instance method)">#<strong>destroy</strong> &#x21d2; Object </a>
360
+
361
+
362
+
363
+ </span>
364
+
365
+
366
+
367
+
368
+
369
+
370
+
371
+
372
+
373
+ <span class="summary_desc"><div class='inline'></div></span>
374
+
375
+ </li>
376
+
377
+
378
+ <li class="public ">
379
+ <span class="summary_signature">
380
+
381
+ <a href="#draw-instance_method" title="#draw (instance method)">#<strong>draw</strong> &#x21d2; Object </a>
382
+
383
+
384
+
385
+ </span>
386
+
387
+
388
+
389
+
390
+
391
+
392
+
393
+
394
+
395
+ <span class="summary_desc"><div class='inline'><p>rubocop:disable Metrics/AbcSize.</p>
396
+ </div></span>
397
+
398
+ </li>
399
+
400
+
401
+ <li class="public ">
402
+ <span class="summary_signature">
403
+
404
+ <a href="#font-instance_method" title="#font (instance method)">#<strong>font</strong> &#x21d2; Object </a>
405
+
406
+
407
+
408
+ </span>
409
+
410
+
411
+
412
+
413
+
414
+
415
+
416
+
417
+
418
+ <span class="summary_desc"><div class='inline'><p>rubocop:enable Metrics/AbcSize.</p>
419
+ </div></span>
420
+
421
+ </li>
422
+
423
+
424
+ <li class="public ">
425
+ <span class="summary_signature">
426
+
427
+ <a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(position:, text: &quot;&quot;) &#x21d2; HudText </a>
428
+
429
+
430
+
431
+ </span>
432
+
433
+
434
+ <span class="note title constructor">constructor</span>
435
+
436
+
437
+
438
+
439
+
440
+
441
+
442
+
443
+ <span class="summary_desc"><div class='inline'><p>A new instance of HudText.</p>
444
+ </div></span>
445
+
446
+ </li>
447
+
448
+
449
+ <li class="public ">
450
+ <span class="summary_signature">
451
+
452
+ <a href="#move-instance_method" title="#move (instance method)">#<strong>move</strong> &#x21d2; Object </a>
453
+
454
+
455
+
456
+ </span>
457
+
458
+
459
+
460
+
461
+
462
+
463
+
464
+
465
+
466
+ <span class="summary_desc"><div class='inline'></div></span>
467
+
468
+ </li>
469
+
470
+
471
+ <li class="public ">
472
+ <span class="summary_signature">
473
+
474
+ <a href="#width-instance_method" title="#width (instance method)">#<strong>width</strong> &#x21d2; Object </a>
475
+
476
+
477
+
478
+ </span>
479
+
480
+
481
+
482
+
483
+
484
+
485
+
486
+
487
+
488
+ <span class="summary_desc"><div class='inline'></div></span>
489
+
490
+ </li>
491
+
492
+
493
+ </ul>
494
+
495
+
496
+ <div id="constructor_details" class="method_details_list">
497
+ <h2>Constructor Details</h2>
498
+
499
+ <div class="method_details first">
500
+ <h3 class="signature first" id="initialize-instance_method">
501
+
502
+ #<strong>initialize</strong>(position:, text: &quot;&quot;) &#x21d2; <tt><span class='object_link'><a href="" title="HudText (class)">HudText</a></span></tt>
503
+
504
+
505
+
506
+
507
+
508
+ </h3><div class="docstring">
509
+ <div class="discussion">
510
+ <p>Returns a new instance of HudText.</p>
511
+
512
+
513
+ </div>
514
+ </div>
515
+ <div class="tags">
516
+
517
+
518
+ </div><table class="source_code">
519
+ <tr>
520
+ <td>
521
+ <pre class="lines">
522
+
523
+
524
+ 6
525
+ 7
526
+ 8
527
+ 9
528
+ 10
529
+ 11
530
+ 12
531
+ 13
532
+ 14
533
+ 15
534
+ 16
535
+ 17
536
+ 18</pre>
537
+ </td>
538
+ <td>
539
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 6</span>
540
+
541
+ <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='label'>position:</span><span class='comma'>,</span> <span class='label'>text:</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
542
+ <span class='ivar'>@position</span> <span class='op'>=</span> <span class='id identifier rubyid_position'>position</span>
543
+ <span class='ivar'>@text</span> <span class='op'>=</span> <span class='id identifier rubyid_text'>text</span>
544
+ <span class='ivar'>@size</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>medium</span><span class='tstring_end'>&quot;</span></span>
545
+ <span class='ivar'>@color</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="Color.html" title="Color (class)">Color</a></span></span><span class='period'>.</span><span class='id identifier rubyid_palette'><span class='object_link'><a href="Color.html#palette-class_method" title="Color.palette (method)">palette</a></span></span><span class='period'>.</span><span class='id identifier rubyid_white'>white</span>
546
+ <span class='ivar'>@background_color</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="Color.html" title="Color (class)">Color</a></span></span><span class='period'>.</span><span class='id identifier rubyid_palette'><span class='object_link'><a href="Color.html#palette-class_method" title="Color.palette (method)">palette</a></span></span><span class='period'>.</span><span class='id identifier rubyid_black'>black</span>
547
+ <span class='ivar'>@visible</span> <span class='op'>=</span> <span class='kw'>true</span>
548
+ <span class='ivar'>@layer</span> <span class='op'>=</span> <span class='int'>100</span>
549
+ <span class='ivar'>@in_world</span> <span class='op'>=</span> <span class='kw'>false</span>
550
+ <span class='ivar'>@alignment</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>top-left</span><span class='tstring_end'>&quot;</span></span>
551
+
552
+ <span class='const'><span class='object_link'><a href="Global.html" title="Global (module)">Global</a></span></span><span class='period'>.</span><span class='id identifier rubyid_hud_texts'><span class='object_link'><a href="Global.html#hud_texts-class_method" title="Global.hud_texts (method)">hud_texts</a></span></span><span class='period'>.</span><span class='id identifier rubyid_push'>push</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span>
553
+ <span class='kw'>end</span></pre>
554
+ </td>
555
+ </tr>
556
+ </table>
557
+ </div>
558
+
559
+ </div>
560
+
561
+ <div id="instance_attr_details" class="attr_details">
562
+ <h2>Instance Attribute Details</h2>
563
+
564
+
565
+ <span id="alignment=-instance_method"></span>
566
+ <div class="method_details first">
567
+ <h3 class="signature first" id="alignment-instance_method">
568
+
569
+ #<strong>alignment</strong> &#x21d2; <tt>Object</tt>
570
+
571
+
572
+
573
+
574
+
575
+ </h3><div class="docstring">
576
+ <div class="discussion">
577
+ <p>Returns the value of attribute alignment.</p>
578
+
579
+
580
+ </div>
581
+ </div>
582
+ <div class="tags">
583
+
584
+
585
+ </div><table class="source_code">
586
+ <tr>
587
+ <td>
588
+ <pre class="lines">
589
+
590
+
591
+ 4
592
+ 5
593
+ 6</pre>
594
+ </td>
595
+ <td>
596
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
597
+
598
+ <span class='kw'>def</span> <span class='id identifier rubyid_alignment'>alignment</span>
599
+ <span class='ivar'>@alignment</span>
600
+ <span class='kw'>end</span></pre>
601
+ </td>
602
+ </tr>
603
+ </table>
604
+ </div>
605
+
606
+
607
+ <span id="background_color=-instance_method"></span>
608
+ <div class="method_details ">
609
+ <h3 class="signature " id="background_color-instance_method">
610
+
611
+ #<strong>background_color</strong> &#x21d2; <tt>Object</tt>
612
+
613
+
614
+
615
+
616
+
617
+ </h3><div class="docstring">
618
+ <div class="discussion">
619
+ <p>Returns the value of attribute background_color.</p>
620
+
621
+
622
+ </div>
623
+ </div>
624
+ <div class="tags">
625
+
626
+
627
+ </div><table class="source_code">
628
+ <tr>
629
+ <td>
630
+ <pre class="lines">
631
+
632
+
633
+ 4
634
+ 5
635
+ 6</pre>
636
+ </td>
637
+ <td>
638
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
639
+
640
+ <span class='kw'>def</span> <span class='id identifier rubyid_background_color'>background_color</span>
641
+ <span class='ivar'>@background_color</span>
642
+ <span class='kw'>end</span></pre>
643
+ </td>
644
+ </tr>
645
+ </table>
646
+ </div>
647
+
648
+
649
+ <span id="color=-instance_method"></span>
650
+ <div class="method_details ">
651
+ <h3 class="signature " id="color-instance_method">
652
+
653
+ #<strong>color</strong> &#x21d2; <tt>Object</tt>
654
+
655
+
656
+
657
+
658
+
659
+ </h3><div class="docstring">
660
+ <div class="discussion">
661
+ <p>Returns the value of attribute color.</p>
662
+
663
+
664
+ </div>
665
+ </div>
666
+ <div class="tags">
667
+
668
+
669
+ </div><table class="source_code">
670
+ <tr>
671
+ <td>
672
+ <pre class="lines">
673
+
674
+
675
+ 4
676
+ 5
677
+ 6</pre>
678
+ </td>
679
+ <td>
680
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
681
+
682
+ <span class='kw'>def</span> <span class='id identifier rubyid_color'>color</span>
683
+ <span class='ivar'>@color</span>
684
+ <span class='kw'>end</span></pre>
685
+ </td>
686
+ </tr>
687
+ </table>
688
+ </div>
689
+
690
+
691
+ <span id="in_world=-instance_method"></span>
692
+ <div class="method_details ">
693
+ <h3 class="signature " id="in_world-instance_method">
694
+
695
+ #<strong>in_world</strong> &#x21d2; <tt>Object</tt>
696
+
697
+
698
+
699
+
700
+
701
+ </h3><div class="docstring">
702
+ <div class="discussion">
703
+ <p>Returns the value of attribute in_world.</p>
704
+
705
+
706
+ </div>
707
+ </div>
708
+ <div class="tags">
709
+
710
+
711
+ </div><table class="source_code">
712
+ <tr>
713
+ <td>
714
+ <pre class="lines">
715
+
716
+
717
+ 4
718
+ 5
719
+ 6</pre>
720
+ </td>
721
+ <td>
722
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
723
+
724
+ <span class='kw'>def</span> <span class='id identifier rubyid_in_world'>in_world</span>
725
+ <span class='ivar'>@in_world</span>
726
+ <span class='kw'>end</span></pre>
727
+ </td>
728
+ </tr>
729
+ </table>
730
+ </div>
731
+
732
+
733
+ <span id="layer=-instance_method"></span>
734
+ <div class="method_details ">
735
+ <h3 class="signature " id="layer-instance_method">
736
+
737
+ #<strong>layer</strong> &#x21d2; <tt>Object</tt>
738
+
739
+
740
+
741
+
742
+
743
+ </h3><div class="docstring">
744
+ <div class="discussion">
745
+ <p>Returns the value of attribute layer.</p>
746
+
747
+
748
+ </div>
749
+ </div>
750
+ <div class="tags">
751
+
752
+
753
+ </div><table class="source_code">
754
+ <tr>
755
+ <td>
756
+ <pre class="lines">
757
+
758
+
759
+ 4
760
+ 5
761
+ 6</pre>
762
+ </td>
763
+ <td>
764
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
765
+
766
+ <span class='kw'>def</span> <span class='id identifier rubyid_layer'>layer</span>
767
+ <span class='ivar'>@layer</span>
768
+ <span class='kw'>end</span></pre>
769
+ </td>
770
+ </tr>
771
+ </table>
772
+ </div>
773
+
774
+
775
+ <span id="position=-instance_method"></span>
776
+ <div class="method_details ">
777
+ <h3 class="signature " id="position-instance_method">
778
+
779
+ #<strong>position</strong> &#x21d2; <tt>Object</tt>
780
+
781
+
782
+
783
+
784
+
785
+ </h3><div class="docstring">
786
+ <div class="discussion">
787
+ <p>Returns the value of attribute position.</p>
788
+
789
+
790
+ </div>
791
+ </div>
792
+ <div class="tags">
793
+
794
+
795
+ </div><table class="source_code">
796
+ <tr>
797
+ <td>
798
+ <pre class="lines">
799
+
800
+
801
+ 4
802
+ 5
803
+ 6</pre>
804
+ </td>
805
+ <td>
806
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
807
+
808
+ <span class='kw'>def</span> <span class='id identifier rubyid_position'>position</span>
809
+ <span class='ivar'>@position</span>
810
+ <span class='kw'>end</span></pre>
811
+ </td>
812
+ </tr>
813
+ </table>
814
+ </div>
815
+
816
+
817
+ <span id="size=-instance_method"></span>
818
+ <div class="method_details ">
819
+ <h3 class="signature " id="size-instance_method">
820
+
821
+ #<strong>size</strong> &#x21d2; <tt>Object</tt>
822
+
823
+
824
+
825
+
826
+
827
+ </h3><div class="docstring">
828
+ <div class="discussion">
829
+ <p>Returns the value of attribute size.</p>
830
+
831
+
832
+ </div>
833
+ </div>
834
+ <div class="tags">
835
+
836
+
837
+ </div><table class="source_code">
838
+ <tr>
839
+ <td>
840
+ <pre class="lines">
841
+
842
+
843
+ 4
844
+ 5
845
+ 6</pre>
846
+ </td>
847
+ <td>
848
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
849
+
850
+ <span class='kw'>def</span> <span class='id identifier rubyid_size'>size</span>
851
+ <span class='ivar'>@size</span>
852
+ <span class='kw'>end</span></pre>
853
+ </td>
854
+ </tr>
855
+ </table>
856
+ </div>
857
+
858
+
859
+ <span id="text=-instance_method"></span>
860
+ <div class="method_details ">
861
+ <h3 class="signature " id="text-instance_method">
862
+
863
+ #<strong>text</strong> &#x21d2; <tt>Object</tt>
864
+
865
+
866
+
867
+
868
+
869
+ </h3><div class="docstring">
870
+ <div class="discussion">
871
+ <p>Returns the value of attribute text.</p>
872
+
873
+
874
+ </div>
875
+ </div>
876
+ <div class="tags">
877
+
878
+
879
+ </div><table class="source_code">
880
+ <tr>
881
+ <td>
882
+ <pre class="lines">
883
+
884
+
885
+ 4
886
+ 5
887
+ 6</pre>
888
+ </td>
889
+ <td>
890
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
891
+
892
+ <span class='kw'>def</span> <span class='id identifier rubyid_text'>text</span>
893
+ <span class='ivar'>@text</span>
894
+ <span class='kw'>end</span></pre>
895
+ </td>
896
+ </tr>
897
+ </table>
898
+ </div>
899
+
900
+
901
+ <span id="visible=-instance_method"></span>
902
+ <div class="method_details ">
903
+ <h3 class="signature " id="visible-instance_method">
904
+
905
+ #<strong>visible</strong> &#x21d2; <tt>Object</tt>
906
+
907
+
908
+
909
+
910
+
911
+ </h3><div class="docstring">
912
+ <div class="discussion">
913
+ <p>Returns the value of attribute visible.</p>
914
+
915
+
916
+ </div>
917
+ </div>
918
+ <div class="tags">
919
+
920
+
921
+ </div><table class="source_code">
922
+ <tr>
923
+ <td>
924
+ <pre class="lines">
925
+
926
+
927
+ 4
928
+ 5
929
+ 6</pre>
930
+ </td>
931
+ <td>
932
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 4</span>
933
+
934
+ <span class='kw'>def</span> <span class='id identifier rubyid_visible'>visible</span>
935
+ <span class='ivar'>@visible</span>
936
+ <span class='kw'>end</span></pre>
937
+ </td>
938
+ </tr>
939
+ </table>
940
+ </div>
941
+
942
+ </div>
943
+
944
+
945
+ <div id="instance_method_details" class="method_details_list">
946
+ <h2>Instance Method Details</h2>
947
+
948
+
949
+ <div class="method_details first">
950
+ <h3 class="signature first" id="destroy-instance_method">
951
+
952
+ #<strong>destroy</strong> &#x21d2; <tt>Object</tt>
953
+
954
+
955
+
956
+
957
+
958
+ </h3><table class="source_code">
959
+ <tr>
960
+ <td>
961
+ <pre class="lines">
962
+
963
+
964
+ 44
965
+ 45
966
+ 46</pre>
967
+ </td>
968
+ <td>
969
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 44</span>
970
+
971
+ <span class='kw'>def</span> <span class='id identifier rubyid_destroy'>destroy</span>
972
+ <span class='const'><span class='object_link'><a href="Global.html" title="Global (module)">Global</a></span></span><span class='period'>.</span><span class='id identifier rubyid_hud_texts'><span class='object_link'><a href="Global.html#hud_texts-class_method" title="Global.hud_texts (method)">hud_texts</a></span></span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span>
973
+ <span class='kw'>end</span></pre>
974
+ </td>
975
+ </tr>
976
+ </table>
977
+ </div>
978
+
979
+ <div class="method_details ">
980
+ <h3 class="signature " id="draw-instance_method">
981
+
982
+ #<strong>draw</strong> &#x21d2; <tt>Object</tt>
983
+
984
+
985
+
986
+
987
+
988
+ </h3><div class="docstring">
989
+ <div class="discussion">
990
+ <p>rubocop:disable Metrics/AbcSize</p>
991
+
992
+
993
+ </div>
994
+ </div>
995
+ <div class="tags">
996
+
997
+
998
+ </div><table class="source_code">
999
+ <tr>
1000
+ <td>
1001
+ <pre class="lines">
1002
+
1003
+
1004
+ 23
1005
+ 24
1006
+ 25
1007
+ 26
1008
+ 27
1009
+ 28
1010
+ 29
1011
+ 30
1012
+ 31
1013
+ 32</pre>
1014
+ </td>
1015
+ <td>
1016
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 23</span>
1017
+
1018
+ <span class='kw'>def</span> <span class='id identifier rubyid_draw'>draw</span>
1019
+ <span class='kw'>if</span> <span class='id identifier rubyid_visible'>visible</span>
1020
+ <span class='kw'>unless</span> <span class='ivar'>@background_color</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
1021
+ <span class='id identifier rubyid_font'>font</span><span class='period'>.</span><span class='id identifier rubyid_draw_markup_rel'>draw_markup_rel</span><span class='lparen'>(</span><span class='id identifier rubyid_text'>text</span><span class='comma'>,</span> <span class='id identifier rubyid_screen_position'>screen_position</span><span class='period'>.</span><span class='id identifier rubyid_x'>x</span> <span class='op'>+</span> <span class='id identifier rubyid_shadow_offset'>shadow_offset</span><span class='comma'>,</span> <span class='id identifier rubyid_screen_position'>screen_position</span><span class='period'>.</span><span class='id identifier rubyid_y'>y</span> <span class='op'>+</span> <span class='id identifier rubyid_shadow_offset'>shadow_offset</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='id identifier rubyid_position_rel'>position_rel</span><span class='period'>.</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_position_rel'>position_rel</span><span class='period'>.</span><span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='id identifier rubyid_background_color'>background_color</span><span class='rparen'>)</span>
1022
+ <span class='kw'>end</span>
1023
+ <span class='id identifier rubyid_font'>font</span><span class='period'>.</span><span class='id identifier rubyid_draw_markup_rel'>draw_markup_rel</span><span class='lparen'>(</span><span class='id identifier rubyid_text'>text</span><span class='comma'>,</span> <span class='id identifier rubyid_screen_position'>screen_position</span><span class='period'>.</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_screen_position'>screen_position</span><span class='period'>.</span><span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='id identifier rubyid_position_rel'>position_rel</span><span class='period'>.</span><span class='id identifier rubyid_x'>x</span><span class='comma'>,</span> <span class='id identifier rubyid_position_rel'>position_rel</span><span class='period'>.</span><span class='id identifier rubyid_y'>y</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='id identifier rubyid_color'>color</span><span class='rparen'>)</span>
1024
+ <span class='kw'>end</span>
1025
+
1026
+ <span class='id identifier rubyid_draw_debug'>draw_debug</span> <span class='kw'>if</span> <span class='const'><span class='object_link'><a href="Global.html" title="Global (module)">Global</a></span></span><span class='period'>.</span><span class='id identifier rubyid_debug'><span class='object_link'><a href="Global.html#debug-class_method" title="Global.debug (method)">debug</a></span></span>
1027
+ <span class='kw'>end</span></pre>
1028
+ </td>
1029
+ </tr>
1030
+ </table>
1031
+ </div>
1032
+
1033
+ <div class="method_details ">
1034
+ <h3 class="signature " id="font-instance_method">
1035
+
1036
+ #<strong>font</strong> &#x21d2; <tt>Object</tt>
1037
+
1038
+
1039
+
1040
+
1041
+
1042
+ </h3><div class="docstring">
1043
+ <div class="discussion">
1044
+ <p>rubocop:enable Metrics/AbcSize</p>
1045
+
1046
+
1047
+ </div>
1048
+ </div>
1049
+ <div class="tags">
1050
+
1051
+
1052
+ </div><table class="source_code">
1053
+ <tr>
1054
+ <td>
1055
+ <pre class="lines">
1056
+
1057
+
1058
+ 35
1059
+ 36
1060
+ 37
1061
+ 38
1062
+ 39
1063
+ 40
1064
+ 41
1065
+ 42</pre>
1066
+ </td>
1067
+ <td>
1068
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 35</span>
1069
+
1070
+ <span class='kw'>def</span> <span class='id identifier rubyid_font'>font</span>
1071
+ <span class='id identifier rubyid_found_font'>found_font</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="Global.html" title="Global (module)">Global</a></span></span><span class='period'>.</span><span class='id identifier rubyid_pixel_fonts'><span class='object_link'><a href="Global.html#pixel_fonts-class_method" title="Global.pixel_fonts (method)">pixel_fonts</a></span></span><span class='lbracket'>[</span><span class='ivar'>@size</span><span class='rbracket'>]</span>
1072
+ <span class='kw'>if</span> <span class='id identifier rubyid_found_font'>found_font</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
1073
+ <span class='id identifier rubyid_raise'>raise</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>HudText.size value not valid &#39;</span><span class='embexpr_beg'>#{</span><span class='ivar'>@size</span><span class='embexpr_end'>}</span><span class='tstring_content'>&#39;. Valid values: &#39;small, medium, big, huge&#39;</span><span class='tstring_end'>&quot;</span></span>
1074
+ <span class='kw'>end</span>
1075
+
1076
+ <span class='id identifier rubyid_found_font'>found_font</span>
1077
+ <span class='kw'>end</span></pre>
1078
+ </td>
1079
+ </tr>
1080
+ </table>
1081
+ </div>
1082
+
1083
+ <div class="method_details ">
1084
+ <h3 class="signature " id="move-instance_method">
1085
+
1086
+ #<strong>move</strong> &#x21d2; <tt>Object</tt>
1087
+
1088
+
1089
+
1090
+
1091
+
1092
+ </h3><table class="source_code">
1093
+ <tr>
1094
+ <td>
1095
+ <pre class="lines">
1096
+
1097
+
1098
+ 20</pre>
1099
+ </td>
1100
+ <td>
1101
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 20</span>
1102
+
1103
+ <span class='kw'>def</span> <span class='id identifier rubyid_move'>move</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre>
1104
+ </td>
1105
+ </tr>
1106
+ </table>
1107
+ </div>
1108
+
1109
+ <div class="method_details ">
1110
+ <h3 class="signature " id="width-instance_method">
1111
+
1112
+ #<strong>width</strong> &#x21d2; <tt>Object</tt>
1113
+
1114
+
1115
+
1116
+
1117
+
1118
+ </h3><table class="source_code">
1119
+ <tr>
1120
+ <td>
1121
+ <pre class="lines">
1122
+
1123
+
1124
+ 48
1125
+ 49
1126
+ 50</pre>
1127
+ </td>
1128
+ <td>
1129
+ <pre class="code"><span class="info file"># File 'lib/fantasy/hud_text.rb', line 48</span>
1130
+
1131
+ <span class='kw'>def</span> <span class='id identifier rubyid_width'>width</span>
1132
+ <span class='id identifier rubyid_font'>font</span><span class='period'>.</span><span class='id identifier rubyid_markup_width'>markup_width</span><span class='lparen'>(</span><span class='id identifier rubyid_text'>text</span><span class='comma'>,</span> <span class='int'>1</span><span class='rparen'>)</span>
1133
+ <span class='kw'>end</span></pre>
1134
+ </td>
1135
+ </tr>
1136
+ </table>
1137
+ </div>
1138
+
1139
+ </div>
1140
+
1141
+ </div>
1142
+
1143
+ <div id="footer">
1144
+ Generated on Sat Apr 2 14:24:12 2022 by
1145
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1146
+ 0.9.27 (ruby-3.0.2).
1147
+ </div>
1148
+
1149
+ </div>
1150
+ </body>
1151
+ </html>