/
haleyjd_changelog_4.txt
3407 lines (2607 loc) · 165 KB
/
haleyjd_changelog_4.txt
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
NOTE: This file has been retired, and contains changelog entries
from v3.35.92 up to the release of v3.39.20.
See haleyjd_changelog_5.txt for more recent updates.
================================================================================
Changes since Eternity Engine v3.37.00
================================================================================
--------------------------------------------------------------------------------
10/09/10
Added iwad_hacx variable and added the HACX titlescreen to startup.wad, and
made modifications to the IWAD picker to allow choosing it, to finish up
support for the HACX 1.2 release.
Updated the changelog and version info for upcoming 3.39.20 "Resheph" release.
--------------------------------------------------------------------------------
10/05/10
I added an r_voxels module and code to load .vox format voxel models.
--------------------------------------------------------------------------------
10/03/10
CSonicGo found a bug in the d_fastrefresh tweak which caused -timedemo to break
completely - it would dump you to the console, where you could enter commands
that would be acknowledged but never executed, and where you could access the
menus, but changing certain variables would cause the game to crash. Indeed,
the game was stuck in GS_STARTUP state because the first gametic could never
be run with TryRunTics returning immediately every time.
The fix is to not do the early return from TryRunTics if the timer is being
used unlatched, as in -timedemo mode.
--------------------------------------------------------------------------------
09/07/10
I made some changes to d_fastrefresh which make it even faster and allow it to
behave as proper unlatched framerate support - though note that there is still
no interpolation support and so the apparent FPS is 35 even though the drawn
framerate is 200 or higher. I can definitely tell the difference though,
especially since d_fastrefresh=false cannot attain even 35 FPS under Windows 7
due to some kind of bizarre lag in getting the refresh to the display. I
suspect this is related to Aero somehow, and seems to affect all SDL apps when
running under Vista or 7.
I also added a new d_drawfps cvar that will show the drawn FPS on screen,
rather than the count of gameloops per second, which caps at 35.
--------------------------------------------------------------------------------
08/15/10
Added a logical warning output system for EDF which, with use of the
-edf-show-warnings parameter, can print out warnings to the Win32 (or Linux)
console window. Warnings will additionally always appear in the verbose log
even when this parameter is not used. A count of EDF warnings is always shown
on the console.
printz found another DECORATE states bug; I needed to allow transition back to
the NEEDLABELORKWORSTATE state after accepting a 'bright' keyword as well, and I
somehow failed to notice this oversight while adding support for making the
transition after parsing the tics token.
It is now possible to edit the default values of sync-critical variables while
a demo is in progress, rather than being told by the menu system that you cannot
do something because a demo is playing. This required some special checks in
the console system which switch over to setting only defaults when the cvars
are in a state where their runtime value should not be modified.
The end of a demo will automatically propagate defaults of sync-critical vars
back into their runtime versions, courtesy of the BOOM code which has always
worked this way, and so this is just exploiting a facility that already exists
and was only overlooked by fraggle while implementing the console in SMMU.
--------------------------------------------------------------------------------
08/14/10
After attempting to implement modification-safe blockamp list traversal, I
realized that nullification of blockmap and sector lists in P_UnsetThingPosition
is actually unnecessary and causes many more problems than it solves. Instead
it suffices entirely to do the addition of MF_NOBLOCKMAP|MF_NOSECTOR when
removing the thing, so that it cannot be relinked into the lists. Not nullfiying
the links does at least still allow the object to be traversed through while
completing traversals during the current gametic, while the object is still
valid in memory even though it has been removed from the gamesim.
--------------------------------------------------------------------------------
08/13/10
Added some safety tweaks when demos are not being played. Sector and blockmap
links should be nullified in P_UnsetThingPosition, and the old_sectorlist in
mobj_t should be cleared when calling P_RemoveMobj. MF_NOBLOCKMAP and
MF_NOSECTOR *must* be set on objects when they are removed, or other code in the
engine could force them to be relinked into the blockmap and sector lists while
they are pending to be freed.
The sound engine is also now allowed to increment and decrement reference counts
on objects, in the unlikely event that a thing plays a sound AFTER having
S_StopSound called on it but before actually getting freed. This may come in
handy later for supporting transient sound origins.
--------------------------------------------------------------------------------
08/09/10
Another major bug was found in edf-branch code, this time by printz. I was using
the wrong ehash_t specialization for the new system of state hashing which would
cause lower-case state names to inappropriately go unrecognized. Fixed by
changing E_StateNumForName to use the case-insensitive specialization.
I also added additional use of ZONEVERBOSE in z_native.c to #if out some more
dangerous message prints which can wipe out the original cause of a memory error
when the game is trying to report it.
--------------------------------------------------------------------------------
08/08/10
I removed the SMMU limit on console argvs and tokens, including a fix to an
unchecked crash condition if a command had more than 64 tokens. The token and
argv arrays are now fully dynamic and will reallocate if their initial size
is exceeded.
--------------------------------------------------------------------------------
07/29/10
A long-time fear of mine was confirmed today when I discovered that DOOM sets
the game into the GS_LEVEL gamestate too early - at the start of G_DoLoadLevel
instead of at the end of P_SetupLevel when everything has been created. To fix
this I added a new GS_LOADING gamestate which is entered in G_DoLoadLevel, and
then I do not set GS_LEVEL until everything is actually ready to be manipulated
externally.
I have rewritten (already) the DECORATE state parser so that it is semi-tolerant
of errors, rather than bombing out for any little mistake. No states defind in
an erroneous DECORATE state block can be used, however, and the DSO will be
disposed of when any error occurs, causing a NULL return value from
E_ProcessDecorateStates.
DECORATE state processing errors will now appear in the EDF verbose log file.
--------------------------------------------------------------------------------
07/26/10
esselfortium found a major bug from edf-branch which disabled the ability to
load EDF from wads - this was caused by returning lump->index (the hash chain)
instead of i (the lump number) from E_FindLumpInclude.
--------------------------------------------------------------------------------
07/25/10
Implemented an experimental change to dynasegs that hopefully fixes the problem
of inconsistent splitting of polyobjects with vertices that are too close to
node lines found by Graf Zahl in ZDoom. I also added QStrFindFirstOfChar and
QStrFindFirstNotOfChar routines which are similar to std::string's
find_first_of in C++, and employed them immediately in the console. I rewrote
tab completion in the console to use qstrings and to eliminate some dangerous
unchecked static limits from SMMU.
--------------------------------------------------------------------------------
07/24/10
I have eliminated most of the rest of the static limits in the console via
additional application of qstrings.
--------------------------------------------------------------------------------
07/18/10
I added a QStrCDupAuto method for creating an automatic-allocation copy of a
qstring_t's contents, so that temporary, disposable copies of qstrings can be
made for one-off operations
I made E_SpiltTypeAndState in e_things.c global so that it can be used by the
state evaluator in e_args.c, and implemented a new E_ArgAsStateLabel evaluator
with support for the :: scope operator in state jump targets. This allows the
A_Jump codepointer to jump to any foreign object state.
All other state evaluators also now support DECORATE state labels, when the
jump target is not found as a global state name first (this makes DECORATE
labels a fall-back in pointers that use these routines). I also added an
args[2] parameter to A_Scratch which allows the pointer to play a sound when it
is invoked from a DECORATE state.
--------------------------------------------------------------------------------
07/16/10
I gave the qstring module another massive overhaul. I changed all size and index
variables/parameters to use size_t rather than unsigned int, changed the
QStrBuffer, QStrSize, and QStrLen functions into macros for efficiency, and
added new macros and functions QStrConstPtr, QStrClearOrCreate, QStrBufferAt,
QStrCNCopy, QStrInsert, QStrMakeQuoted, QStrNCaseCmp, QStrNCmp, QStrQCat,
QStrQCopy, and QStrToDouble.
--------------------------------------------------------------------------------
07/12/10
I have added a basic inheritance mechanism to metatype_t's so that they can call
into their parent class's methods. For example, in the new toString method for
metastrings, the metaobject base class copy method is invoked first to do a
shallow copy, and then the referenced string is sent to strdup so that the new
metastring gets an independent copy of the string.
I also added a toString method for speedsets, the only metaobject type that was
currently missing this method.
Tweaked the w_levels module so that the w_masterlevels command cannot be
exploited to load PWADs in shareware games.
--------------------------------------------------------------------------------
07/10/10
I found a problem in Z_Realloc that would have crashed the game if a memory
outage occurred and the game tried and failed to remove purgable blocks. I was
also able, with a realization that the currently reallocating block is detached
from the zone block list beforehand, to restore support for reallocation of
purgable blocks.
--------------------------------------------------------------------------------
07/08/10
I got sick of typing M_ everywhere just to do string operations, and so I
dropped this prefix from all qstring routines, leaving them with names such as
QStrCopy. I think this is a vast improvement.
While in m_qstr.c I took the opportunity to reorganize the module, giving each
function a proper categorization.
I rewrote the native heap's zone alloca system to exploit the native heap's
blockbytag list so that it no longer has to add an extra header into the
allocation or do its own linked list tracking. This allows me to add a
Z_Realloca for reallocation of automatic blocks.
--------------------------------------------------------------------------------
07/07/10
I re-removed the error message length limitation in E_EDFLogPrintf by using two
va_list objects. An initial implementation of M_QStrPrintf, a function that can
do formatted printing into a qstring, has been added. I started replacing all
instances of psnprintf/M_QStrCpy pairs with calls to this new function.
--------------------------------------------------------------------------------
07/05/10
Added support for the mythic, unimplemented vt_toggle cvar type mentioned in
comments from SMMU, and then I changed all actual boolean variables to use that
cvar type, so that they are not using int * to write into boolean locations
(even though this is generally perfectly safe under C, it's still semantically
poor).
I have created a stopgap solution for associating cvars with their corresponding
default_t in the config file, so that the console now has access to defaults.
The default value is now printed when the cvarhelp command is used. I also
rewrote cvarhelp so that it properly uses the console's hashing mechanism,
rather than doing an inefficient linear search over all console command objects.
Console.argv and Console.argc have been changed from char arrays into qstring_t
objects, eliminating all SMMU static limits on console token and command length.
Fixed undefined strcpy behavior in C_SetVariable in the process.
cvars can now be reset to their default value by using the syntax:
<variablename> *
That is, following the variable name with a star character.
--------------------------------------------------------------------------------
07/03/10
I rewrote the config file system to use a pseudo-object-oriented design for
default_t objects, default_t's are populated with methods from their
corresponding static interfaces at startup.
--------------------------------------------------------------------------------
07/02/10
I have added full support for floating point cvars to menu slider controls,
including the snazzy ability to display the current value of the slider above
the slider in a framed box while the slider is the currently selected menuitem.
--------------------------------------------------------------------------------
06/25/10
Work continues on the LevelInfo rewrite but I'm running into some problems that
may take a good while to overcome.
--------------------------------------------------------------------------------
06/24/10
edf-branch has been merged into trunk, bringing in support for dynamic states,
sprites, and DECORATE states.
Some post-merge cleanup work was required, including resolving the issue in
w_wad.c so that all wad files, even ones loaded into private directories, are
given a unique source identification number.
The A_Jump DECORATE pointer is now fully functional.
I finally got around to changing all EMACS mode select strings in the source
code so that automatic source code analyzers such as ohloh will not misidentify
the code as C++.
--------------------------------------------------------------------------------
06/21/10
Started work on rewrites that will hopefully enable LevelInfo to be cached, so
that Hexen-style MAPINFO can be supported properly within the same system.
--------------------------------------------------------------------------------
06/20/10
Added a GIF_HUDSTATBARNAME flag to GameModeInfo which controls the position of
the automap levelname widget, rather than branching on GameModeInfo->type in
HU_Init. I also added a clear method to the leveltime widget which will move
the widget up if the automap level name is so long that it would overlap with
the timer.
--------------------------------------------------------------------------------
06/19/10
I finally got around to changing the array of gamemission paths in d_main into
a field in GameModeInfo. Now when new gamemissions are added I don't have to
remember to add an item to an array in another module.
--------------------------------------------------------------------------------
06/18/10
The Master Levels directory can now be re-enumerated if the path is changed at
runtime.
--------------------------------------------------------------------------------
06/17/10
Master Levels support is now complete with the ability to set the directory to
use, and support for reading the author names and map titles out of their wad
template files when such are present.Added w_masterlevels command to bring up
the special loading menu.
--------------------------------------------------------------------------------
06/16/10
Additional work has been done on the w_levels module. It is now possible to save
and reload the game while on a level loaded out of a managed private wad
directory. Did another round of GCC warning fixing.
--------------------------------------------------------------------------------
06/15/10
Added a new w_levels module for maintaining managed private wad directories.
Made modifications to mn_files that will allow the file selector widget to be
used externally on an arbitrary directory structure, rather than being
restricted to operating on a single data structure private to that module.
Fixed a bug whereby the IWAD picker module could access freed memory while
closing startup.wad.
--------------------------------------------------------------------------------
06/14/10
I have added support for ZDoom's new uncompressed extended node format, which
has support for maps too massive for the original format. Also fixed a problem
I caused in the new texture system that temporarily broke runtime loading of
PWADs with new textures in them.
Mouse motion events are now finally ignored for real at startup, so you once
again shouldn't start out facing a random direction and looking up at the
ceiling when starting games with parameters such as -warp.
Finally, I have gotten support into p_setup.c for loading levels out of private
wad directories. This is going to come in handy for an idea I have for the
implementation of native Master Levels support.
--------------------------------------------------------------------------------
06/13/10
Simplified the screenshot IO macros in m_shots.c. Also made an experimental
change to span projection to use a Mozilla routine from SpiderMonkey for what I
hope is a portable means of converting doubles into unsigned integers. It works
on PC, but needs to be tested on Linux and MacOS.
--------------------------------------------------------------------------------
06/09/10
Static analyzer fixes continue, though they are all very minor now. I fixed the
low-precision span drawers to use the proper fixedunit (65536). This was lost
during the experimental rewrite when SoM decoupled the x and y scaling factors
in order to support non-symmetric flat sizes. The low-precision drawer for
64x64 flat drawing requires special treatment in do_draw_plane to fix this.
--------------------------------------------------------------------------------
06/08/10
I have done more work on I_Error-class functions to ensure that they never
return to the caller. Allowing this to happen in recursive error situations is
incorrect, as the calling code will almost certainly assume exiting as a post
condition of I_Error, and will therefore crash when that post condition is
violated. I_Error etc. will now unconditionally abort if a recursive error
occurs.
I have also added GNU C's __attribute__((noreturn)) to all of these functions,
as it is recognized by the Clang analyzer.
--------------------------------------------------------------------------------
06/07/10
MP2E ran the Clang static analyzer over EE again and it found a new host of
issues, mostly minor, most of which I have fixed. One major problem it uncovered
was an ability to crash in Z_Realloc if the function were invoked on a PU_CACHE
block.
To fix this, I have made reallocation of all purgable resources illegal, since
this has never been supported. The fact that reallocation can cause purgable
resources to be freed makes this inherently unsafe. It may also create issues
with the user pointers for cachable resources.
--------------------------------------------------------------------------------
06/06/10
I have continued to work on honing EE's error/shutdown behavior. Error codes
should only escalate, and not degrade, if reentrancy is detected through any of
the various shutdown routines. Also, each routine invoked from I_Quit should
recheck for the occurance of a fatal error, as some of the routines called invoke
the I_FatalError function.
I found a gigantic memory leak being caused by private wad directories. While I
have been freeing the lumpinfo array, that array is an array of pointers, and
the pointers themselves point to lumpinfo_t objects which are allocated in
separate chunks for each file or group of lumps added to the directory.
This has been repaired by adding a reallocating array to waddir_t which keeps
track of all lumpinfo_t allocations that belong to the wad's directory. A new
routine in w_wad.c can then be invoked when closing the wad file which will
delete all of the lumpinfo_t allocations properly.
--------------------------------------------------------------------------------
06/05/10
SDL_MOUSE_X1 and X2 identifiers don't seem to exist on SDL versions prior to
the latest few, so I've added a define for people who cannot for some reason
update their system headers on Linux. Compiling EE under such cirucmstances
will result in no support for the 6th or 7th mouse buttons.
I fixed a problem caused by my previous I_Error tweaks which was causing any
non-fatal error message to simply not appear. I also added an I_ExitWithMessage
function which can quit the game without causing a logical error condition.
This means that all normal shutdown will proceed in full and the game will not
wait for input at the console in Windows.
--------------------------------------------------------------------------------
06/03/10
I have at last crossed off an ancient FIXME/TODO item by eliminating the
grotesque use of K&R function declaration syntax in m_cheat.c to circumvent ANSI
C type checking, which was being done in order to call functions of multiple
prototypes through the same function pointer member of the cheat_t structure.
Instead, cheat callback functions now accept a void *, which they convert to the
proper type of data inside. This isn't particularly any more type-safe, but at
least it colors within the lines of valid language constructs.
K&R function declaration syntax isn't even supported in the C99 standard as far
as I know, so I have no idea why GCC hasn't been complaining about this for a
long time now.
--------------------------------------------------------------------------------
06/02/10
By user request I have changed the default value of process_affinity_mask to
1. This will have to remain until SDL_mixer gets its crap in order, which at
this point may be never.
I have also enabled the idclev cheat to warp you to *any* ExMy or MAPxy level
(depending on the gamemode), so long as that map actually exists and appears to
be in a valid directory format. This allows directly visiting such locales as
SoD MAP33 and Crucified Dreams MAP99 without use of the console.
--------------------------------------------------------------------------------
06/01/10
The normal "IWAD found" message will now appear when a disk file is in use, and
the canonical resource path and name from the disk file will appear.
After user complaints, I have disabled the ability for the unbind command to
automatically release bindings in the kac_menu and kac_console key action
classes when executing the unbind action with only one argument. It will now
be necessary to explicitly specify the key action class in order to unbind such
actions from the console.
This helps avoid a serious problem that could develop if the user inadvertently
releases both the "toggle console" and "toggle menu" bindings at the same time.
>_>
I have also added support, by request from Gez, for SDL's MOUSE_X1 and MOUSE_X2
mouse button identifiers, which support logical mouse buttons #6 and 7. On my
Logitech Click! mouse, the "application change" button is recognized as X1 under
the default Windows 7 USB mouse driver.
--------------------------------------------------------------------------------
05/31/10
Disk file loading and version recognition have been extended for Ultimate DOOM
disk files.
IdentifyVersion has been split into IdentifyIWAD and IdentifyDisk functions to
resimplify the logic and to allow the eternity.wad file to be consistently
loaded before the IWAD, regardless of whether it comes from a disk file or not.
--------------------------------------------------------------------------------
05/30/10
Support has been added for parsing specific "metadata" files inside disk files,
which can override defaults for LevelInfo, as well as set certain properties
such as the episode name.
--------------------------------------------------------------------------------
05/28/10
I have added support for ".disk" files, which may contain an IWAD and one or
more additional PWAD files. These files have a 72-byte-entry directory structure
at file offset 0 which appears as follows:
00000000: DWORD - number of files (big endian)
00000004: Start of directory
????????: DWORD - total size of file minus header (big endian)
Directory entry:
00000000: char[64] - file path/name, null-terminated and extended with junk
00000040: DWORD - offset of file, relative to end of header (big endian)
00000044: DWORD - length of file in bytes (big endian)
Game mode and mission recognition characteristics have been extended to the one
currently known disk file.
--------------------------------------------------------------------------------
05/27/10
Changes have been made to sidedef loading to match those made to sector loading,
allowing R_SearchWalls to also avoid using a temporary string buffer.
My previous fix to ga_victory avoidance on ExM8 with LevelInfo.killFinale set
needed an additional tweak to avoid returning early from G_DoCompleted.
Otherwise you'd never exit the level, which was quite bizarre.
--------------------------------------------------------------------------------
05/26/10
A Doomworld user found there was a problem with LevelInfo.killFinale on ExM8
levels in Doom 1. I needed to add code which overrides the automatic triggering
of gameaction "ga_victory" in this circumstance.
I have changed the reading of sectors to be done on a field-by-field basis
rather than via structure mapping, so that the flat names may be stored into
char [9] arrays rather than char [8]. This allows proper null-termination of
the strings before they are sent into R_SearchFlats, allowing the hack of
copying the argument into a temporary buffer in that function to be removed.
--------------------------------------------------------------------------------
05/23/10
SoM completed tolerance for missing patches in multipatch textures under the
new "experimental" texture system.
--------------------------------------------------------------------------------
05/22/10
I earlier noticed while doing heap debugging for the V_CopyRect problem that
there were a huge number of 32-byte allocations on the heap stemming from
e_args.c, and I then realized that all states are being given an argument list,
which is in itself a problem that still needs to be addressed.
However, on top of that, all the states are being assigned 5 empty argument
strings when their arguments default via a cmp field. This means that there are
tons of copies of the empty string "" sitting on the heap doing nothing.
I have fixed this by adding code to the e_args module which interns any empty
strings added to arglists by setting them equal in value to a private constant
static empty string. The code to free argument values checks for this before
freeing anything so that it remains safe. This saves a buttload of memory.
--------------------------------------------------------------------------------
05/21/10
I have overhauled I_Error further to add an I_FatalError function, which can be
given an error code as well as a message. This function is now called for
severe errors such as heap corruption, failures in the config file writing
process, etc. which must be immediately fatal; ie., the shutdown code in I_Quit
should not attempt to execute any further.
This restores the ability to save the configuration files when minor errors such
as W_CacheLumpNum occur.
I also audited all I_Error/I_FatalError message strings for \n's at the end, and
added them where needed.
--------------------------------------------------------------------------------
05/20/10
I repaired some more bad problems with interactions between the menu and console
systems from SMMU that were causing some menu widget types to not result in
values being saved to the configuration file if the cvars in question had
default variables.
I have moved almost all c_ variables (such as c_showprompt, currenttarget,
currentheight, c_argv, c_argc, etc) into a new global Console structure.
--------------------------------------------------------------------------------
05/18/10
SoM put in some fixes for slope precision, as well as odd-sized flats such as
some that are found in Heretic and Hexen. Those have to be treated as 64x64
even though their resources are differently sized.
--------------------------------------------------------------------------------
05/17/10
redrawborder *must* be set after the screenwipe routines have finished drawing
for the final time. I have no idea how long this has been broken; possibly
since SMMU.
--------------------------------------------------------------------------------
05/15/10
SoM fixed three more problems with the new experimental branch code:
* The BAADF00D placeholder texture is no longer displayed in the menu background
selection dialogue.
* V_DrawBackground now renders flats with the proper orientation again. They
were, for a short time, rotated 90 degrees due to change in their storage
for interchangeability support.
* r_swirl can now be toggled off at runtime again. It was previously sticking
"on" due to experimental branch changes.
I fixed -solo-net to allow cheats in the same manner as single-player games.
I also rewrote the W_ReadLumpHeader routine so that it caches the target lump.
R_Init was significantly slower under experimental branch conditions due to
constant fseeking through the IWAD to re-read the same patches multiple times.
This fix should bring it back up to pre-experimental spec.
--------------------------------------------------------------------------------
05/11/10
I fixed some problems with warnings from experimental branch found by Gez, and
also fixed a problem with R_MakeMissingTexture having an improper return
statement in it. Added support for experimental code files to the Visual C++
6.0 project as well.
--------------------------------------------------------------------------------
05/09/10
SoM fixed a bug in the experimental flat code that caused 0-length lumps such
as F1_START to be treated as 64x64 flats. The menu would crash quite nicely if
you tried to select such an item as a menu background, since my previous safety
checks were removed or accidentally circumvented in experimental branch.
--------------------------------------------------------------------------------
05/08/10
SoM has merged his experimental branch into trunk, bringing in support for
flat and texture interchangeability, tall textures (>= 256px), and other
awesome features. EE's texturing abilities are now about 99% on par with ZDoom
and PrBoom+, minus the following that may be eventually implemented:
* Support for loading TEXTUREx lumps additively. This is likely to happen very
soon.
* Support for PNG-format textures. This is probably pretty far away right now.
* Support for ZDoom's textual texture definitions. This will probably happen
fairly soon. This will include support for exotic features such as texture
translations, scaling, etc.
* Support for TX_START - TX_END. This should be doable immediately. I hope this
will be in place before the next release.
--------------------------------------------------------------------------------
05/07/10
xlut/ylut pointers are now cleared when freeing VBuffer objects, and are checked
for validity before trying to free them, to avoid potential problems with
dangling pointers and double frees.
--------------------------------------------------------------------------------
05/05/10
Repaired a problem with massive heap corruption originating from V_CopyRect due
to a bad assumption I made about the scaling arrays being consistent regardless
of x/y position (they are not).
--------------------------------------------------------------------------------
05/04/10
I finished a definitive rewrite of SoM's new V_CopyRect after I noticed some
problems in its scaling and clipping code; this should fix multiple issues.
--------------------------------------------------------------------------------
05/02/10
Cleanup work on the menu system continues. I have finally gotten around to
renaming the MN_WriteTextColoured function to MN_WriteTextColored, for
consistency with the rest of the source. My apologies to fraggle ;)
The menu contents widget has been modified to give off sounds upon its
appearance and dismissal, to give proper auditory feedback matching the rest of
the menu system.
I also finally got around to adding code to set the initial index of the
selected item in the contents widget to match the item for the currently
displayed page of the multipage menu. The pointer previously always began on the
first item.
My 4/30 change to add drop shadows to the v-box has required a modification to
V_DrawLoading so that it calls C_Drawer when the game is in startup state.
Otherwise the translucency adds up over the non-redrawing background and just
becomes solid black. This is a problem because of the fact that the main
drawing loop is not yet active while the code is still inside D_DoomInit ;)
--------------------------------------------------------------------------------
05/01/10
Did some major work in the menu system replacing the gigantic switches on menu
item types in the responder and drawer code with tables of function pointers.
After future extension, these modifications may eventually coalesce into a sort
of menuitem pseudoclass structure, bearing method function pointers similar to
what the HUD code already does for HUD widgets.
--------------------------------------------------------------------------------
04/30/10
I added a drop shadow to boxes drawn via the BOOM/SMMU V_DrawBox routine, which
really makes them pop out from the menus, and avoids visual clashes.
The left and right miniskull pointers are now synchronized so that they begin
and end their rotations (which move in the opposite direction) at the same time.
--------------------------------------------------------------------------------
04/27/10 - 4/29/10
Consistency in use of segclip vs ds has been added when determining wall
lighting. I added #if 0 around the now unused R_DrawSprite function which has
been dead since the integration of portals.
Version information is now printed to the console when starting a demo.
The p_markunknowns variable is now saved in the config file - no clue how I
missed this.
Further sound engine tweaks:
* The low-level sound engine is now limited to numChannels, so that it
responds absolutely to the user's settings, and can't fudge it. This
will also allow the variable to offer a real performance improvement
potential, as the mixing callback will no longer loop around all 32
channels even if it's only using 8 or 16 of them.
* snd_channels is now stored in system.cfg
* Hexen thunder sounds are now played from a private sound origin object with
ATTN_NONE, rather than playing on the "NULL" global sound channel. This means
that if, for example, a Heresiarch awakens, thunder will not cut off his
wake-up sound.
* Positioning of sector sound origins is now done in such a way to avoid
numeric overflow when dealing with very large sectors. Thanks to entryway.
* Avoid calling I_SoundID and potentially memset on all inactive sound
channels during every main loop iteration.
* Volume limiting is now performed in the high-level sound code to avoid
oversaturation of the sound mixer when too many sounds are playing.
--------------------------------------------------------------------------------
04/25/10
SoM has attempted to fix flat drawing on MacOS, but we remain unaware of
whether or not the fix actually works.
After getting frustrated with EE's framerate in Speed of Doom MAP28, I have
implemented the drawsegs_xrange optimization from PrBoom+, which cuts down
the number of cache misses generated during vissprite clipping dramatically
(it turns out this code is completely cache bound, and cannot be optimized
effectively in ANY way which does not directly address the motion of cache
RAM). Saves 6 FPS at a particular spot on the map, making the difference
between an almost unplayable 11 FPS and a passable 17 FPS.
--------------------------------------------------------------------------------
04/22/10
3-band EQ should not be run on silence, as it chews a ton of CPU (an amount
drastically disproportionate to running it on actual sound, which must be some
weird consequence of floating-point math on x86).
Fixed a serious bug caused by using a %g specifier to sscanf with a double
variable. Unlike printf, scanf requires explicit notice that the variable it is
writing into is a double vs a float. This is due to lack of promotion semantics
when passing by reference.
--------------------------------------------------------------------------------
04/21/10
After listening to some vanilla Doom sound output and noticing its manly bass
as compared to EE's horrific harsh rasp, I have implemented an experimental
3-band equalizer into the SDL digital sound refresh callback which has support
for bass boost and low-pass filtering.
In order to support this, I have implemented the mythical vt_float console
variable type, which was declared in SMMU but never implemented or supported in
any way. Matching support has also been added to the configuration file, though
groundwork was already laid for this during the previous rewrite to eliminate
pointer-cramming there.
The cvarhelp command now takes unlimited bounds for float and integer variables
into account properly when printing the range of values they can take. It would
previously display the values 123456789 or -123456789 literally. I also added
proper support for string-type variables.
--------------------------------------------------------------------------------
04/19/10
I have been forced to finally fix the "ninja spawn" phenomenon, caused by
integer overflow in G_CheckSpot when spawning players at deathmatch spots. The
code there treats signed mapthing_t::angle as unsigned, and as a result,
generates out-of-bounds indices into the finesine and finecosine table.
Fortunately for purposes of compatibility, this behavior in vanilla has been
reverse engineered by entryway. This is important because ninja spawns can have
an impact on gameplay during intense deathmatch rounds.
I have also repaired a problem from vanilla Doom which involves your spawn
sound getting lost. There was a bizarre hack in G_CheckSpot trying to somehow
magically defer execution of the S_StartSound call - of course this didn't
work, as C doesn't execute in such a way (I really have no idea what they were
thinking, it's mind-boggling).
Instead the sound must be played after the player has been fully spawned and
positioned, back in P_SpawnPlayer.
--------------------------------------------------------------------------------
04/16/10
Changed tmbase and tm to clip and pClip, and then I changed most of the old
clipping engine to simply use clip directly rather than the clip stack, as SoM
says the plan for portals no longer involves implementing recursive clipping in
this code path. This should improve efficiency, as the compiler can compute
constant addresses for members of the global clip struct which it cannot do
when dealing with the pClip pointer.
Sector link collection has been modified to use the clip stack, however, outside
of old demos, replacing the previous fix from PrBoom by cph which simply saved
several members of the tm* family before overwriting them, and then restored
them afterward.
Hexen mapthing z position setting has apparently been broken forever. It should
work now.
I also eliminated the redundant clip.flags field, which is now gotten instead
from clip.thing->flags, as in PrBoom.
--------------------------------------------------------------------------------
04/15/10
THE DEMO IS IN SYNC!
* Changed EE's JUSTHIT fix to match PrBoom+'s, possibly breaking support for
EE 3.35 demos.
* P_TeleportMove compatibility check changed to match PrBoom+.
* PrBoom+ PIT_CheckThing return value compatibility fix applied.
* Added an mobj_t position logging system.
* Dropoff logic, which proved to be the problem causing the Cyberdemon's
position to be incorrect, has been split up into different functions which
are called via a pointer depending on the demo version, because it's simply
too complex to combine all of this code into a single path. This alone was
what finally fixed the demo.
--------------------------------------------------------------------------------
04/13/10
I have not yet succeeded in restoring sync to Okuplok's demo. The PrBoom+ fix
to 2.02/MBF incompatibility in P_LookForPlayers must use the P_SetTarget
function or else risks corrupting the mobj_t reference counts. This is probably
a bug in PrBoom+.
I have found that a previous refactoring in P_TryMove has been responsible for
bad dropoff behavior in EE for quite some time now, so I have had to remove
the refactoring altogether - this is because I cannot understand the original
code. It is impossible to read due to impenetrable abuse of conditional
expressions with side effects, to the point where applying order of operations
rules doesn't even work unless you are a machine.
--------------------------------------------------------------------------------
04/11/10
I have set out on a maddening quest to restore/improve BOOM 2.02 demo sync to
EE, at least well enough that Okuplok's amazing demo of Speed of Doom MAP33
will remain in sync.
Aggravatingly, this demo stays in perfect sync almost all the way to the end,
when the Cyberdemon appears on the "descent to nowhere." As the Cyberdemon
dies, the player appears to become hung up on him for a moment longer than in
PrBoom+, and then appears to continue on as normal.
However, the player's position being just slightly off alters the behavior of
the monsters in subtle ways that begin to add up over the next 30 or so seconds
of gameplay, culminating in an Imp who is in the wrong spot firing a fireball
which shouldn't have been fired, which knocks the player off course, causing him
to miss the Soul Sphere in the central pillar. This ensures his untimely death
shortly thereafter in a hail of Hell Knight plasma balls.
I have started with the following fixes and tweaks:
* G_SetCompatibility has been adapted from PrBoom+ to facilitate tracking of
the versions in which various compatibility tweaks were first added to the
engine, and first became optional as opposed to being hard-coded to the
current demo_version.
* PrBoom+ fixes for incompatibilies between BOOM 2.02 and MBF in P_Move and
P_LookForPlayers.
* BOOM 2.02 friction model code restored for use only during 2.02 demo playback.
* p_map3d functions made to I_Error if ever invoked accidentally during old
demo versions.
* PrBoom+ fixes for incompatibilities between 2.02 and MBF in player bobbing,
particularly when related to friction changes and the effects of voodoo
dolls.
--------------------------------------------------------------------------------
04/10/10
Player color and name settings have finally been restored to full functionality.
Turns out this was accidentally lost by cutting out C_InitNet during the MBF
netcode restoration.
This fix is only good for single player, though, as EE still lacks any ability
to multicast settings to all nodes in order to allow variables which have
unique values on a per-player basis. This is one of the major deficiencies of
Eternity's current netcode and needs a fix badly. Players will still have
auto-generated names and default colors at the start of any netgame.
--------------------------------------------------------------------------------
04/09/10
I have added support for analogues of two more DECORATE actor flags:
SYNCHRONIZED - things with this flag are not subject to having their first
spawnstate's tics randomized in P_SpawnMobj. This is normally
done so that monsters don't all start out doing the exact
same thing, and torches flicker differently, etc.
NORANDOMIZE - As a projectile, a thing marked this way will not have its
spawnstate and first death state tics randomized. Unfortunately
this flag's name and semantics had to be negated from ZDoom, or
else major problems with EDF backward and forward compatibility
would have been created. So in EE, this flag disables the
randomization of projectiles, whereas in ZDoom, RANDOMIZE is
required to enable it.
Because the VPO warning hud widget is entirely inaccurate and has outlived any
usefulness it may have ever had, I have removed that feature in order to spare
ptoing the need to make a new graphic for it. I also made some minor fixes for
menu sliders in Heretic, and drawing of the current crosshair on the HUD options
menu.
--------------------------------------------------------------------------------
04/08/10
SoM rewrote V_CopyRect after deficiencies were found in its clipping abilities.
The header for the frags hud widget is now positioned properly regardless of
the graphic's dimensions, so that ptoing's new graphic for Heretic will appear
in the proper location.
--------------------------------------------------------------------------------
04/07/10
The ZONEVERBOSE define has been added in z_native.c in order to control output
of potentially dangerous fields from the zone memblock structure during error
conditions, because printing these fields when the heap is in a corrupt state
generally results in an immediate segmentation violation, obliterating the
ability to get useful error message output. The primary field in the memblock
struct which is a culprit in this respect is block->file when INSTRUMENTED is
defined.
--------------------------------------------------------------------------------
04/06/10
As I have serious doubts about the sustainability of using floating point code
in the gamecode as far as demo sync goes, I have eliminated use of
tantoangle_acc within the gamecode. It is now only used within the renderer;
P_TanToAngle uses only the old precalculated (and therefore reliably valued)
tantoangle table.
I eliminated most uses of "unsigned" as a type by itself without any further