-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathroodylib.h
12346 lines (11292 loc) · 258 KB
/
roodylib.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
!::
! ROODYLIB - A collection of hugolib updates and additions
!::
#ifclear _ROODYLIB_H
#set _ROODYLIB_H
constant ROODYBANNER "RoodyLib Version 4.3.0"
constant ROODYVERSION "4.3.0"
#ifset VERSIONS
#message "roodylib.h version 4.3.0"
#endif
#ifset DEBUG
#set HUGOFIX
#endif
!----------------------------------------------------------------------------
!* SOME CONSTANTS AND PROPERTIES AND STUFF
!----------------------------------------------------------------------------
constant LAST_TURN 31 ! used by SaveSettings/LoadSettings to keep track of
! what xverb is being used
#ifclear NO_ACCESSIBILITY
constant CHEAP_ON 1
constant CHEAP_MENUS 2
#endif
! some verbosity constants since I can never remember which value is which
enumerate step + 1
{
BRIEF, SUPERBRIEF, VERBOSE
}
! some statustype constants
enumerate step * 2
{
NO_STATUS, SCORE_MOVES = 1, TIME_STATUS, CUSTOM_STATUS, INFOCOM_STYLE,
MILITARY_TIME
}
enumerate start = 32, step * 2
{
FINDOBJECT_LIVING, FINDOBJECT_FOUND , FINDOBJECT_CALLED
FIRSTCOMMAND_F ! first command of input?
}
! "terp_type" values 2, 4, 8
enumerate step * 2
{
NORMAL_TERP = 2, GLK_TERP, SIMPLE_TERP
}
enumerate start = 4096, step * 2
{
DESCFORM_I, DESCFORM_D, CAPLIST_F
}
#ifset USE_RELATIVE_DESCRIPTIONS
global DESCRIBEPLACEFORMAT
enumerate start = 1 , step * 2
{
OVERRIDEHERE_F, ALSO_F
}
#endif
! if newmenu.h is going to be included, it's easier to just declare the
! usage_desc property now
#if undefined usage_desc
property usage_desc alias short_desc
#endif
!----------------------------------------------------------------------------
!* REPLACED HUGOLIB.H ROUTINES
!----------------------------------------------------------------------------
! Roody's note: AfterRoutines and BeforeRoutines called player.react_before
! twice
replace AfterRoutines
{
local i, r
r = player.after
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; player.name;
if debug_flags & D_OBJNUM
print " ["; number player; "]";
print ".after returned "; number r; "]\b"
}
#endif
}
if verbroutine ~= &MovePlayer
r = player.react_after
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; player.name;
if debug_flags & D_OBJNUM
print " ["; number player; "]";
print ".react_after returned "; number r; "]\b"
}
#endif
}
r = location.after
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; location.name;
if debug_flags & D_OBJNUM
print " ["; number location; "]";
print ".after returned "; number r; "]\b"
}
#endif
}
if verbroutine ~= &MovePlayer
r = location.react_after
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; location.name;
if debug_flags & D_OBJNUM
print " ["; number location; "]";
print ".react_after returned "; number r; "]\b"
}
#endif
}
for i in location
{
if i ~= player
r = i.react_after
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; i.name;
if debug_flags & D_OBJNUM
print " ["; number i; "]";
print ".react_after returned "; number r; "]\b"
}
#endif
}
}
}
replace BeforeRoutines(queue)
{
local r, i
if verbroutine ~= &MovePlayer
r = player.react_before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; player.name;
if debug_flags & D_OBJNUM
print " ["; number player; "]";
print ".react_before returned "; number r; "]\b"
}
#endif
return r
}
r = player.before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; player.name;
if debug_flags & D_OBJNUM
print " ["; number player; "]";
print ".before returned "; number r; "]\b"
}
#endif
return r
}
if verbroutine ~= &MovePlayer
r = location.react_before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; location.name;
if debug_flags & D_OBJNUM
print " ["; number location; "]";
print ".react_before returned "; number r; "]\b"
}
#endif
return r
}
r = location.before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; location.name;
if debug_flags & D_OBJNUM
print " ["; number location; "]";
print "before returned "; number r; "]\b"
}
#endif
return r
}
if verbroutine = &MovePlayer
r = object.before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; object.name;
if debug_flags & D_OBJNUM
print " ["; number object; "]";
print "before returned "; number r; "]\b"
}
#endif
return r
}
for i in location
{
if i ~= player
r = i.react_before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; i.name;
if debug_flags & D_OBJNUM
print " ["; number i; "]";
print ".react_before returned "; number r; "]\b"
}
#endif
return r
}
}
if verbroutine = &MovePlayer
return
! queue is -1 if the object was a number (i.e., a literal digit)
if queue ~= -1 and xobject > display
{
r = xobject.before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; xobject.name;
if debug_flags & D_OBJNUM
print " ["; number xobject; "]";
print ".before returned "; number r; "]\b"
}
#endif
return r
}
}
if queue ~= -1 and object > display
{
r = object.before
if r
{
#ifset DEBUG
if debug_flags & D_PARSE
{
print "\B["; object.name;
if debug_flags & D_OBJNUM
print " ["; number object; "]";
print ".before returned "; number r; "]\b"
}
#endif
return r
}
}
}
! Roody's note: Replaced AnyVerb because the player's PreParse check can
! confuse it. Also added an argument for disallowing SpeakTo since that has
! been coming up a lot for me.
!
! Also made it ignore MovePlayer since AnyVerb exists mainly for the handling
! of commands.
replace AnyVerb(obj,disallow_speakto)
{
#ifclear NO_XVERBS
if parser_data[VERB_IS_XVERB]
return false
#endif
if (verbroutine = &PreParse,&MovePlayer) or
(verbroutine = &SpeakTo and disallow_speakto)
return false
elseif obj
return obj
else
return true
}
#ifclear NO_FUSES
!\
Activate - added a warning for when it is called before the player global has
been set. Also added an option to not run daemons/fuses if the Hugofix
fuse/daemon monitor is on.
\!
replace Activate(a, set) ! <set> is for fuses only
{
local err, b
if a.type = fuse
b = "fuse"
else
b = "daemon"
if not player
{
Font(BOLD_ON)
print "[WARNING: The player global must be set before
daemon (object "; number a;") can be activated.]"
err = true
}
#ifset DEBUG
if debug_flags & D_FUSES
{
print "[";
print b; " "; number a;
if a.type = fuse
print " (timer = "; number set; ")";
" called. Allow activation? (Y/N) > ";
while true
{
pause
if word[0] = 'y','Y'
{
print "Y]"
break
}
elseif word[0] = 'n','N'
{
print "N]"
print "["; b; " "; number a; " canceled.]"
return false
}
}
}
#endif
a.in_scope = player
a is active
if a.type = fuse and not err
{
if set
a.timer = set
run a.activate_event
}
elseif a.type = daemon and not err
{
if set and not a.#timer
{
Font(BOLD_ON)
print "[WARNING: Attempt to set nonexistent timer
property on daemon (object "; number a; ")]"
err = true
}
else
a.timer = set
run a.activate_event
}
elseif not err
{
Font(BOLD_ON)
print "[WARNING: Attempt to activate non-fuse/\
daemon (object "; number a; ")]"
err = true
}
#ifset DEBUG
if debug_flags & D_FUSES and not err
{
print "[Activating "; b; " "; number a;
if a.type = fuse
print " (timer = "; number a.timer; ")";
print "]"
}
#endif
if err
{
Font(BOLD_OFF)
"\npress a key to continue..."
HiddenPause
}
return (not err)
}
replace Deactivate(a)
{
local err
#ifset HUGOFIX
move a to fuses_and_daemons
#else
remove a
#endif
a.in_scope = 0
a is not active
if a.type ~= fuse and a.type ~= daemon
{
print "[WARNING: Attempt to deactivate non-fuse/\
daemon (object "; number a; ")]"
err = true
}
else
{
run a.deactivate_event
}
#ifset DEBUG
if debug_flags & D_FUSES and not err
{
print "[Deactivating "; a.name; " "; number a; "]"
}
#endif
return (not err)
}
#endif ! ifclear NO_FUSES
! Roody's note: Added a new global variable so it's not so important to add
! a holding property to all containers. Character objects still have a holding
! property by default.
global holding_global
replace Acquire(newparent, newchild)
{
local p,h
CalculateHolding(newparent)
if newparent.#holding
h = newparent.holding
else
h = holding_global
if h + newchild.size > newparent.capacity
return false
else
{
p = parent(newchild)
move newchild to newparent
CalculateHolding(p)
newchild is moved
newchild is not hidden
if newparent.#holding
newparent.holding = newparent.holding + newchild.size
return true
}
}
! AssignPronoun(object)
! sets the appropriate pronoun global to <object>
!\ Roody's note: This version has added support for animals and things being
! called "it" instead of something gendered, written by Mike Snyder.
! Added a "force" argument. Along with different pronoun handling
! in Parse and other places, just adding a true value to "force"
! should guarantee a pronoun change (no longer requiring the author
! to set last_object to -1.
! Also made it so that if there isn't a current value for the applicable
! pronoun global variable, it sets it anyway.
\!
replace AssignPronoun(obj,force)
{
local a
if ExcludeFromPronouns(obj)
return
! No use if you can't refer to it
if not obj.#noun and not obj.#adjective
return
select true
case (obj is plural)
{
if not them_obj
a = true
}
case (obj is not living or obj.pronoun #2 = "it")
{
if not it_obj
a = true
}
case (obj is female)
{
if not her_obj
a = true
}
case else
{
if not him_obj
a = true
}
! if not a and parser_data[LAST_PARSER_STATUS] & PRONOUNS_SET and not force: return
if parser_data[LAST_PARSER_STATUS] & PRONOUNS_SET and not force: return
if obj is not living
{
if obj is not plural
it_obj = obj
else
them_obj = obj
}
else
{
if obj is plural
them_obj = obj
elseif obj is female
her_obj = obj
elseif (obj.pronouns #2) = "it"
it_obj = obj
else
him_obj = obj
}
if force
parser_data[LAST_PARSER_STATUS] |= PRONOUNS_SET
}
!\ Roody's note: I created a routine for establishing rules for objects
that pronouns should never be set to. Like the original AssignPronoun,
I've included the player object but I also included direction objects. Replace
this routine if you'd like special rules for your game. \!
routine ExcludeFromPronouns(obj)
{
if obj = player: return true
#ifclear NO_OBJLIB
elseif obj.type = direction : return true
#endif
return false
}
!\ Roody's note: This has some extra code added to avoid mobile object
confusion (written by Mike Snyder). Also added support for global_holding
so not all containers necessarily need a holding property. \!
replace CalculateHolding(obj)
{
local i
if obj.#holding
{
obj.holding = 0
for i in obj
{
if not (i is worn and i is clothing and obj = player)
obj.holding = obj.holding + i.size
}
}
else
{
holding_global = 0
for i in obj
{
if not (i is worn and i is clothing and obj = player)
holding_global = holding_global + i.size
}
}
}
! Roody's note: I forget why, but I thought CenterTitle should be available
! even when menus aren't being used.
#ifset NO_MENUS
! if CenterTitle doesn't exist, I declare it here just to be replaced
routine CenterTitle(a, lines,force)
{}
#endif
replace CenterTitle(a, lines,force, do_not_use_menu_colors)
{
#ifclear NO_ACCESSIBILITY
if cheap and not force
return
#endif !ifclear NO_ACCESSIBILITY
local l, b, c
if not lines: lines = 1
if not (SL_TEXTCOLOR or SL_BGCOLOR)
{
b = DEF_SL_BACKGROUND
c = DEF_SL_FOREGROUND
}
#ifclear NO_MENUS
elseif (MENU_SELECTCOLOR or MENU_SELECTBGCOLOR) and
not do_not_use_menu_colors
{
b = MENU_SELECTBGCOLOR
c = MENU_SELECTCOLOR
}
#endif
else
{
b = SL_BGCOLOR
c = SL_TEXTCOLOR
}
Font(BOLD_OFF|ITALIC_OFF|UNDERLINE_OFF|PROP_OFF)
l = string(_temp_string, a)
if not system(61)
window 0 ! remove previous window
if (TERP & GLK_TERP)
{
window 1 ! draw an empty window so glk terps determine screenwidth properly
{}
}
while (l + 1) > (display.linelength * lines)
{
lines++
}
window lines
{
if not (TERP & SIMPLE_TERP)
{
color c,b
cls
locate 1,1
}
print "\_";
if (l+1) < display.linelength
print to (display.linelength/2 - l/2);
print a;
}
color TEXTCOLOR, BGCOLOR, INPUTCOLOR
FONT(DEFAULT_FONT)
if not (TERP & SIMPLE_TERP) and not force
cls
if not system(61) and not force
locate 1, LinesFromTop
}
#ifclear NO_SCRIPTS
! american vs british spelling
replace CancelScript(obj)
{
local o
o = FindScript(obj)
if o = MAX_SCRIPTS
return
scriptdata[o * 3] = 0
if o = number_scripts - 1
number_scripts--
#ifset DEBUG
if debug_flags & D_SCRIPTS
{
print "[Script for obj. ";
print number obj; " ("; obj.name; ") ";
#ifset AMERICAN_ENGLISH
print "canceled]"
#else
print "cancelled]"
#endif
}
#endif ! NO_DEBUG
return true
}
! Roody's note: This CharMove version tries to work better with doors.
replace CharMove(char, dir)
{
#ifclear NO_OBJLIB
local newroom, a
general = 1 ! if general stays true (and the character doesn't go
! through a door or something), we'll get a
! "So-and-so goes <direction>ward." message
if dir.type ~= direction
return
newroom = parent(char).(dir.dir_to)
if newroom.type = door
{
a = newroom
newroom = a.between #((parent(char) = \
a.between #1) + 1)
if a is not open
{
if char in location or newroom = location
{
self = a
RlibOMessage(door, 3)
}
}
elseif newroom = location or char in location
a = 0
}
if char in location and not a and general = 1
{
Message(&CharMove, 1, char, dir)
event_flag = true
}
move char to newroom
#ifset DEBUG
if debug_flags & D_SCRIPTS
{
print "["; CThe(char); IsorAre(char, true); " now in: ";
print capital parent(char).name; ".]"
}
#endif
if char in location and not a and general = 1
{
Message(&CharMove, 2, char, dir)
event_flag = true
}
elseif char in location
event_flag = true
#endif ! ifclear NO_OBJLIB
general = 0 ! always reset it
run parent(char).after
return true
}
! Roody's note: This allows looping scripts without losing a turn.
! When calling it, set a true value for 'loop'
replace LoopScript(obj,loop)
{
local o
while scriptdata[o * 3] ~= obj and o < MAX_SCRIPTS: o++
if o = MAX_SCRIPTS
return
scriptdata[o * 3 + 1] = 0
#ifset DEBUG
if debug_flags & D_SCRIPTS
{
print "[Looping script for obj. ";
print number obj; " ("; obj.name; ")]"
}
#endif
if loop
RunScripts
}
!\ Roody's note: I also replaced CharGet and CharDrop just to add a
make-sure-there's-an-object check. It's probably unnecessary, but my own
experimentation with CharMove and my findpath extension made me think it might
be good to play it safe. \!
!----------------------------------------------------------------------------
! CharGet
! Script usage: &CharGet, <object>
replace CharGet(char, obj)
{
if not obj
return
if FindObject(obj, parent(char)) = 1
{
if Acquire(char, obj)
{
if char in location
{
Message(&CharGet, 1, char, obj)
event_flag = true
}
}
return true
}
}
!----------------------------------------------------------------------------
! CharDrop
! Script usage: &CharDrop, <object>
replace CharDrop(char, obj)
{
if not obj
return
move obj to parent(char)
char.holding = char.holding - obj.size
if char in location
{
Message(&CharDrop, 1, char, obj)
event_flag = true
}
return true
}
#endif ! ifclear NO_SCRIPTS
! Roody's note : This has extra code for components and such, a problem
! first noticed by Jason McWright.
! Also added support for transparent, non-container objects
replace CheckReach(obj)
{
local i
if not obj or obj = parent(player)
return true
#ifclear NO_VERBS
! added a check to make sure the player doesn't have the same parent as the
! object before doing "x is closed." messages
local parentcheck
parentcheck = CheckReachParentCheck
if (verbroutine ~= &DoLook, &DoLookIn) and parent(object) and
parent(object) ~= player and not parentcheck
{
! used to check for transparent here, but FindObject should make that not
! necessary
if parent(object) is openable, not open
{
VMessage(&DoGet, 5) ! "X is closed."
return false
}
elseif parent(object) is transparent, not living, not container
{
#ifset _ROODYLIB_H
RLibMessage(&CheckReach,1,obj) ! "The <obj> is inside the <parent>."
#else
print capital The(obj); " is inside "; The(parent(obj)); "."
#endif
return false
}
}
#endif ! NO_VERBS
if not parent(player).reach or
Contains(parent(player), obj)
return true
#ifclear NO_OBJLIB ! since the component class is part of objlib
local p
p = obj.part_of
while p
{
if Contains(parent(player), p)
return true
p = p.part_of
}
#endif
#ifclear NO_VERBS
if parent(obj) is living
{
if verbroutine ~= &DoGet, &DoLook
! "Except that X has it..."
Message(&CheckReach, 1, obj)
elseif verbroutine = &DoGet and parent(obj) is unfriendly
! "Except that X doesn't want to give it to you..."
Message(&CheckReach, 2, obj)
}
#endif
for (i=1; i<=parent(player).#reach; i++)
{
if Contains(parent(player).reach #i, obj) or ! is the object inside a reach object
obj = parent(player).reach #i ! is the object a reach object
{
return true
}
}
#ifclear NO_OBJLIB
p = obj.part_of
while p
{
for (i=1; i<=parent(player).#reach; i++)
{
if Contains(parent(player).reach #i, p) or ! is the object part of an object inside the reach object
p = parent(player).reach #i ! is the object part of a reach object
{
return true
}
}
p = p.part_of
}
#endif
#ifset USE_ATTACHABLES
if parent(player).type = attachable
{
if InList(parent(player), attached_to, obj)
return true
}
if obj.type = attachable
{
if InList(obj, attached_to, parent(player))
return true
}
#endif
! "You can't reach it..."
Message(&CheckReach, 3, obj)
}
! Roody's note: This exists just to be replaced in the supercontainer
! extension
routine CheckReachParentCheck
{
if parent(object) = parent(player)
return true
return false
}
#ifset USE_DARK_ROOM
! Roody's note: In games with dark rooms, I didn't like how they look like
! non-rooms. This code makes dark rooms look more "room-y" when the player
! moves into them by printing the name of the darkness object as if it were a
! room name.
! the darkness object is not a room because the room class will be replaced
! further down in Roodylib and it doesn't really need to be a room anyway
object darkness "Darkness"
{}
replace DarkWarning
{
PrintRoomName(darkness)
Indent
print CThe(player); " stumble"; MatchSubject(player); \
" around in the dark."
}
#endif
!\ Roody's note : Replaced so a new line is still printed, even if indenting
is turned off. Also changed it so that when FORMAT & LIST_F is on, it indents
by the same method for consistency. \!
replace Indent(newl)
{
local i
if newl or (display.cursor_column > 1 and (FORMAT & LIST_F))
print ""
if override_indent or display.cursor_column > 1
print AFTER_PERIOD;
elseif not (FORMAT & NOINDENT_F)
{
if (FORMAT & LIST_F)
{
print to 2;
}
elseif INDENT_SIZE
{
! See display.cursor_column > 1, above
!print newline
print "\_";
for (i=2; i<=INDENT_SIZE; i++)
print " ";
}
}
override_indent = false
}