/
haleyjd_changelog_1.txt
3272 lines (2610 loc) · 148 KB
/
haleyjd_changelog_1.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 EE v3.29 public beta 3 up to the release of v3.31 public beta 5.
See haleyjd_changelog_2.txt for more recent updates.
=====================================================================
Changes since Eternity Engine v3.31 beta 4
=====================================================================
=====================================================================
12/17/03
Seriously improved EDF error messages to give file name and line
number for parsing errors.
Tested new frames.edf and fixed a few problems.
Removed thing type ETCArachnophyte, its frames, and its one sound.
Added Uint16 casts to the parameters to SDL_WarpMouse. This was
causing two "integer type mismatch in parameter" warnings for a
looong time, and I was getting tired of seeing them :P
Compiled Eternity on release platforms and packaged beta 5!
=====================================================================
12/12/03
Added a new bexinclude function to EDF to allow it to specify
DeHackEd/BEX files to be loaded after EDF processing is finished.
This helps to solidify the union between the two languages, and to
support EDF mods that use BEX features like text replacement, which
will NOT be duplicated in EDF. EDF/BEX can be considered a sort of
superlanguage, if you will.
This will even further cut down the impact of EDF on command-line
lengths, and lessens the need for GFS a bit (although GFS is still
a great thing, and I encourage its use in any multi-file Eternity
project).
Fixed a bug related to the "new game starts on first new map"
option. When it was enabled, Ultimate DOOM would always start on
E1M1 no matter what episode you picked, even though the episode
menu was shown and no PWADs were loaded. This was a simple omission
of a check on "modifiedgame" at ONE point. All other points checked
it, so the behavior was inconsistent.
=====================================================================
12/08/03
Applied SoM's fix to 3D object clipping. My idea about making a
function that only clips against things turned out to be right. He
made a function called P_CheckPositionMobjOnly, which is just the
same as P_CheckPosition, but without a P_BlockLinesIterator call.
The result is that things entering P_ZMovement will only update their
floor or ceiling z values to more restrictive values taken from
things which they may be over/under, and not from sectors their
radius happens to make them touch through 2S lines (which is what was
making bullet puffs jump up to the backsector floor height).
This takes care of the last currently known 3D object clipping bug.
I'd venture to bet there still might be some weird corner cases in
there, but until somebody finds them, we won't worry about it ;)
Adjusted parameters to several codepointers:
FireCustomBullets -- Args1 is now a sound DeHackEd number
CustomPlayerMelee -- Args5 is now a sound DeHackEd number
PlayerThunk -------- Args1 is now only specifiable via EDF
-------- Args3 now uses negative values to mean no frame
MissileAttack ------ Args5 now uses negative values to mean no frame
These changes break backward compatibility for these codepointers,
but the changes are necessary. The PlayerThunk and MissileAttack
frame parameters were just plain wrong, as they excluded use of
S_NULL, which could be made a normal frame in a completely rewritten
user EDF. The FireCustomBullets and CustomPlayerMelee changes were
in response to user requests for better player sound flexibility,
and made perfect sense now that sound DeHackEd numbers are documented
by EDF and can be assigned to totally new sounds as well.
=====================================================================
12/06/03
Fixed a problem with the drag and drop code that made files on
LFN paths not load.
=====================================================================
Changes since Eternity Engine v3.31 beta 3
=====================================================================
=====================================================================
11/29/03
Makefiles updated and Eternity compiled on all supported targets.
Eternity Engine v3.31 Public Beta 4 released!
=====================================================================
11/28/03
I planned to release today, but got lazy, so I'll do it tomorrow
night. Remembered I still needed to bump the default zonebase size
up to 16 MB. -heapsize can still force it as low as 8 MB.
=====================================================================
11/22/03
Added code that should support drag-and-drop file loading for wads,
deh/bex files, EDF, and GFS. I can't really test it due to my setup,
so I'll need to find a volunteer or something.
SoM didn't show up all day today, so I don't know what's going on
with him. Its been three days since I posted the last changelog
entry, and at least 2 since he read it, so I know that he knows its
time for him to get the source code -- but he hasn't even spoken a
word to me about it. I really hope that he's just been busy, and that
he's not thinking about quitting.
If he doesn't show tomorrow, I guess I'll have to talk to him about
it as soon as he does. That's not going to be fun, but I can't delay
the release of Eternity Engine v3.31 beta 4 any further. If he
starts work now, he has a whole week to fix one bug. I'm pretty sure
with his talents that it would be no problem -- especially since we
already have an idea of how to fix it.
Also, there are the excellent editing features he has written for
Eternity that we just haven't had time to integrate yet. I've been
excited about them for a long time, but EDF got in the way, and
that's mostly my fault. That's why I wanted to devote beta 5 entirely
and exclusively to getting those features put in.
=====================================================================
11/19/03
Removed the 11-type boss spawner limit, applying and modifying the
patch that schepe sent me a while back. EDF now supports a list of
numbers named boss_spawner_probs, which must have the same number of
integers as there are thing types in the boss_spawner_types list.
Each number in the new list is the probability out of 256 that the
corresponding thing type will be spawned. The numbers in the list
MUST add up to 256, and this is verified.
If the boss_spawner_probs list doesn't exist, I allow the original
default values to be loaded, but ONLY when there are exactly 11 boss
types defined. Otherwise, results would be undefined. This is wholly
sufficient for backward compatibility.
Everything on the EDF checklist for Eternity Engine v3.31 public beta
4 is now complete. Once I have made a mental checklist and have
everything ready, I will pass the source on to SoM so he can try to
fix the object z clipping bug that Mordeth found. After that, I'll
see if there's time to implement Windows file droploading support
for SargeBaldy, and then it's time for beta 4 launch.
=====================================================================
11/17/03
Applied cph's fix to the DOOM bug that fraggle discovered -- sprite
x offsets were not reversed when sprites were drawn flipped, and for
large sprites, this causes weird alignment problems. Fix is in
R_ProjectSprite.
I also finally discovered the REAL reason that DOOM still crashes
when P_SpawnMissile tries to launch a non-missile object. Since most
non-missile objects (medikits in my case) have their speed field set
to zero, this caused an interesting little situation. When DOOM
calculates the z momentum for a missile, it first divides the
approximate distance between the objects by the missile's speed. If
the speed is zero, this caused a divide-by-zero exception. Under
Windows, this would just kick out with no error message.
Now, if an object with zero speed makes it into P_MissileMomz, that
function will substitute the suitable default value of 10*FRACUNIT
for zero, and avoid a division by zero. Since DOOM would always have
kicked out here, there are no compatibility issues. It should now
be safe to spawn a lot more objects like they're missiles.
=====================================================================
11/15/03
Added support for floating-point values in the EDF thingtype block's
speed field. They are converted into fixed-point numbers by the
libConfuse value-parsing callback for that field, and are meant for
use with missiles, which use a fixed-point speed value instead of a
plain integer.
This might be slightly confusing, since these LOOK like they mean
the same thing:
thingtype FOO { speed = 10 }
thingtype FOO { speed = 10.0 }
But, they aren't the same. The first would set the value to 10, and
would be a suitable speed value for monsters. The second would set
the value to 10*FRACUNIT (655360), which is suitable for missiles.
I'll just have to be sure to point this out carefully in the EDF
docs (I already make a big deal there about missiles being handled
differently, so it should build easily).
=====================================================================
11/14/03
Added compressed state definitions, which allow all the frame block's
fields to be specified in a single string, each delimited with pipes,
and allowing defaults to be specified using stars. This is somewhat
similar to DDF's state definition format, and was requested by a
number of users.
If I convert frames.edf to use compressed states, the file will
shrink considerably, and its processing time should be reduced too.
Compressed states will be required in anonymous state lists, which
will work almost exactly like DDF's in-thing frame lists. Here's a
small example of what one might look like. This would make a two-
state torch object (other fields are left out):
thingtype MyTorch
{
spawnstates =
{
"SPRT|A|*|6|*|@next",
"SPRT|B|*|6|*|@prev"
}
}
Here is an example of a normal frame definition using the compressed
specifier. The only field that the cmp field can't specify is the
dehackednum.
frame S_BLAH { cmp = "SPRT|A|*|6|*|@next"; dehackednum = 10000 }
This might still look big, but consider the alternative:
frame S_BLAH
{
sprite = SPRT
spriteframe = A
tics = 6
nextframe = @next
dehackednum = 10000
}
When you collapse that onto one line, it is much less readable, and
a lot bigger.
Note that frame deltas do NOT support the cmp field, for several
reasons (they're usually much smaller, and it would severely compli-
cate their processing, among others).
=====================================================================
11/11/03
Changed all instances of atoi in EDF to strtol, to orthogonally
support octal and hexadecimal numeric constants in all fields.
Added support for letters in the EDF frame block's spriteframe
field via a libConfuse value-parsing callback function. It tests the
string for characters between A and ], and then translates them to
the appropriate number.
=====================================================================
11/07/03
Added special values for the EDF frame block's nextframe field --
@next, @prev, @this, and @null. These set the nextframe to the next
state defined, the previous state defined, the current state, or
the S_NULL state. These will be particularly useful with anonymous
state lists, which are on the TODO list for beta 6.
=====================================================================
11/05/03
Made sounds completely dynamic and added module sounds.edf. I also
rewrote fraggle's sound precaching code, and made it work under
Windows (the SDL_mixer sound code wasn't taking advantage of pre-
caching even when it was turned on).
=====================================================================
11/04/03
Added default loading for cast.edf. I also attempted to do it for
misc.edf, but figured out that it would cause too many problems,
since misc.edf will contain lots of odds and ends that users could
possibly override in numerous different modules.
=====================================================================
10/20/03
Made some changes to the DEH-in-wad queueing code when I realized
that what I had written wouldn't work due to the same reason that
sound couldn't work without a queue -- lump numbers cached before
W_InitMultipleFiles can become invalid after it runs. Fixed by
restoring MBF's recursive D_ProcessDehInWads function, instead of
handling DEHACKED lumps through fraggle's D_NewWadLumps. You don't
have to collect the lumps as the wads are added; you can just run
down the wad lump hash chain for "DEHACKED" and queue any DEHACKED
lumps in it in reverse order.
=====================================================================
10/19/03
Fixed some weird behavior of the HUD. It would turn itself on or off
alternately every time you went to fullscreen mode (no status bar).
Now it'll always show up right after the status bar, and pressing +
afterwards takes you to fullscreen. I'm not sure how it worked in
BOOM, but that seems pretty logical to me, since you progress from
the status bar to the hud to bare fullscreen.
Fixed an issue I knew about earlier but didn't address. If you were
to start up Eternity with general translucency disabled, then enable
it via the console or otherwise, the flex tran table (used by parti-
cles and other neater stuff) would get used without having been init-
ialized. I can imagine the results would not have looked pleasant.
Now, the code responsible for reinit'ing the tranmap when that
variable changes also checks to see if the flex tran table has been
init'ed yet, and if not, it takes care of it.
=====================================================================
10/17/03
Optimized the sprite name table allocation code in EDF so that room
for all the sprite names is allocated into one long string. This
has three benefits:
1. Saves 3 KB of zone memory and any potential fragmentation caused
by having multiple small blocks 32 bytes in size.
2. Guarantees locality of reference on accesses to sequential sprite
names, as found in several places. Since all the pointers in
sprnames now point into a single string, there's no jumping around
in memory. This makes for better cache performance.
3. It is *slightly* faster to call Z_Malloc once than Z_Strdup almost
200 times.
Because a copy of the sprnames array is made by DeHackEd for use by
the [SPRITES] bex block I added, I applied the same optimization
there as well, doubling all of these benefits.
=====================================================================
10/14/03
I've finished more or less everything I can currently accomplish with
the Heretic status bar, aside from its special fullscreen mode. For
this, I have left the ability for ST_Drawer to call a fullscreen mode
callback for the game mode status bar. This will allow me to easily
add a zdoom- or Legacy-like fullscreen status bar with cute little
sprites and big numbers for DOOM, like I wanted to do a while back.
The only stuff not currently functional for the Heretic status bar
is everything having anything to do with the inventory. The rest of
it is all there now. The flight and tome of power icons, which
wouldn't be usable yet anyways, belong in the HUD, not in the status
bar, so I haven't done anything with those yet.
=====================================================================
10/13/03
Created module st_hbar.c and did a lot of Heretic status bar work.
I am going to have the entire bar draw every frame, since there's
really not much to it. I can leave out several "cover-over" patches
that Raven had to use, and it seems to have zero effect on the
framerate anyways.
I've been even more careful about not using Heretic's code for this.
Though I have looked at it for reference, I have written my own
solutions for unique and special problems, and I have organized the
code in my own fashion. Also, I just used the graphics themselves to
figure out part of the life chain semantics. It was easy to figure
out how to move the gem across the screen, as well as how often to
wrap the chain graphic to its starting coordinate, just by viewing
the graphics in a paint program.
=====================================================================
10/12/03
Began implementation of the Heretic status bar. Moved DOOM-specific
code out of ST_Drawer, ST_Ticker, ST_Start, and ST_Init, and created
a stbarfns_t structure which holds some data about a game mode's
status bar, as well as function pointers to the drawer, ticker,
start, and init functions for that bar. Added a StatusBar member of
that type to gameinfo_t.
Fixed the problem that kept the STF_OUCH face from showing when you
hurt yourself badly. I probably better implement some kind of option
for this though. It's quite possible some mods or skins don't
replace the STF_OUCH face, assuming it isn't used. Also, that face
is kinda scary, so some people might object ;)
=====================================================================
10/09/03
ExtraData integration is complete; mapthing ED entry has been tested
and works! Thanks to schepe for making a little test level for me.
Here's how ED for mapthings works:
The ExtraData control object has doomednum 5004. You put these wher-
ever you want a thing that uses an ExtraData record. Then, you go to
its options (aka flags) field and set it to a numeric value that in-
dicates what ExtraData record it is supposed to use. Most editors
have some method for entering an integer value into the options
field. I'll be talking to gherkin about adding it to doombuilder if
that editor doesn't already have it. There's always CLED, too, for
the desperate.
In a text script with format similar to EDF (uses libConfuse just
like GFS and EDF), you then define a mapthing section, and inside it
you specify the same number in that options field as the record
number field. Then you specify the type and (real) options of the
thing you want to spawn at that point. The x, y, and angle are taken
from the ED control thing. Then - and this is where ExtraData really
comes in - you can specify extended fields, such as tid, args, z,
script specials, etc etc etc -- anything for which I could possibly
add support.
The ExtraData lump for the current level is specified via a MapInfo
variable.
So, here's a simple example:
---------------------------------------------------------------------
*{in map}*
[ ] <-- thing of type 5004; options = 1 (x, y, angle are used)
*{in ExtraData lump, named FOOBAR}*
// This record will spawn an Imp at the location of the control thing
mapthing
{
recordnum = 1 // This matches the options value above
type = 3001 // Note: I could also use thing:DoomImp here!
options = EASY|MEDIUM|HARD|AMBUSH
tid = 5
}
*{in MapInfo}*
[level info]
extradata = FOOBAR
---------------------------------------------------------------------
So, there you have it. Note that any number of things on the map can
use the same ExtraData record, which could come in handy, I'm sure.
Note that if an invalid record number is given, or the thing type to
be spawned isn't valid, you'll either get an "Unknown" thing with the
exclamation point, or nothing at all, depending on which type of error
occurs. If there's no ExtraData at all, you also get an "Unknown" for
all ExtraData control things.
While it's a little bit round-about, I think this is probably the
best possible solution for extending the DOOM map format endlessly
via use of a text script. It's been 6 years in the making, and now
it's finally here! I'm very excited, to say the least.
Note that I am thinking about working on a global MapInfo lump. While
I'll still support putting a level's info into the map header, there
are various reasons why this is undesirable (requires a special
utility, makes some programs angry, makes other programs crash,
editors constantly clear it out, etc). Global MapInfo would use
libConfuse, and each map section would declare by name the map for
which it is used. I'm not totally decided on this, though.
=====================================================================
10/08/03
Large amount of ExtraData work started. Mapthings are very close to
being ExtraData-enabled.
=====================================================================
10/06/03
Added a particle style flag for clipping against floors. Along with
the normal drawing test in R_ProjectParticle, particles with the flag
will be set to the floor and have their z acceleration and momentum
zeroed once they reach it.
This is needed for several of SoM's new particle effects which may be
going in soon, as well as several effects from Millennium, a project
that I'm trying to help out by getting some of their effects into the
engine itself.
Amongst those I'm going to do are drips and rain. I've been intending
to do rain for quite a while, anyways, so this gives me a good excuse
to get to it. Although, these objects would be best implemented using
ExtraData, so I need to wait until it is operational.
=====================================================================
10/03/03
Lots of tweaks today!
Tweaked the formatting in p_saveg.c while I was looking over the save
game code for any problems. Made some variables and functions intro-
duced in SMMU static, as they're only used in that module.
Tweaked the demo_version loading code for Eternity-format demos. It
uses |= now instead of +=, and avoids one += by assigning the first
byte to the variable directly.
Tweaked the GameType loading code also. Collapsed an extra branch
and redundant function call. I've been getting sloppy, I guess. ^_^
=====================================================================
10/02/03
Fixed up demo loading under Heretic so that demos recorded under
Eternity can still play in the intro sequence, and so that you can't
even force it to play old Heretic demos from anywhere.
I found out quickly that Heretic doesn't even store a version number
in its demos (this is probably one amongst many reasons that Heretic
demos seem to have poor sync...). The first byte in the file is the
skill level, and it always has a value between 0 and 4. For safety,
I test against 255, which is the value that Eternity puts in the
old version byte. If it's not 255, I bail out of the demo-loading
process early.
Changed the title/demo sequence in d_main.c to allow it to attempt to
play Heretic demos. That way if a new Heretic mod for Eternity has
demos, they'll play as expected.
=====================================================================
09/30/03
Improved error_printf in r_data.c to use vfprintf, avoiding an
unnecessary large local string buffer and vsnprintf operation.
=====================================================================
09/29/03
Made some changes to the castinfo section in EDF. The changes break
backward compatibility, but are very minor and should have very
little impact on existing EDFs.
The castinfo sections now require mnemonics. This is to allow a new
castorder array to be specified. When it exists, it overrides the
normal behavior of storing the cast call members in the order they
are defined. This allows much more editing flexibility, and it really
should have been done this way to begin with. This is why it's worth
the minor compatibility break.
Updated the local EDF docs to reflect this change, and also edited
them. I caught a few mistakes and fixed a few readability issues.
=====================================================================
09/28/03
Added more code to EDF that allows loading of default frames and
things when no definitions are found. The eventual goal is to have
default fallbacks for every EDF module.
The reason for this is to empower old EDFs with greater forward
compatibility, not so that EDF authors can be irresponsible about
including all the modules.
From a standards point of view, all modules should be included. The
only problem is that when I add new required modules, such as the
soon-to-come sounds.edf, and the later-to-come weapons.edf and
classes.edf, old EDF modifications can't possibly know about them.
But, it is safe to assume that old EDFs just need the defaults, which
are implementing the exact same behaviors that were previously hard-
coded. For that I can rely on being able to separately load any of the
standard EDF modules. Each module is only parsed for its guaranteed
contents rather than any possible EDF structures, and the cfg objects
for the individual files are discarded as soon as processing on the
corresponding file is done.
=====================================================================
09/21/03
Added a new parameterized codepointer, MissileAttack. It's really
cool, and can launch missiles straight or at an angle, with a custom-
izable firing height and optional homing. It can also accept the
DeHackEd number of a frame to use for an optional melee attack, so
that you can create imp/baron/caco-style monsters which use either
attack situationally.
An example EDF that employs this codepointer is currently available
here:
http://www.doomworld.com/eternity/engine/edf/mattack.edf
This obviously cannot be used with EE 3.31 beta 3, however. Just
check it out if you want to see how it works in the code.
To make use of the internal P_SpawnMissileAngle function easier, I
abstracted the code for determining a missile's z momentum out of
P_SpawnMissile and into a new P_MissileMomz function.
Fixed an issue in P_SpawnMissileAngle where the missile's target
field was being set directly. This function originally came from
Heretic, and that's where the problem persisted from. How Heretic
ever ran, I don't know. It compounded the already-existing problems
in DOOM several times and yet still got away with it. I don't think
Heretic has ever crashed on me personally.
=====================================================================
09/19/03
Added several checks and verbose log warning messages in cases where
EDF tries to retrieve the DeHackEd number for a thing, frame, or
sound which was given the DeHackEd number -1. Such entities cannot be
used in fields that are translated to DeHackEd numbers (parameterized
codepointer arguments being the primary ones). The action taken is
to store either the required "unknown" type, or 0 for sounds.
=====================================================================
09/13/03
Added module m_queue.c to implement a generic queue data structure
which can be used to queue up any kind of structure via the same type
of pointer casting used to store thinkers (which is a sort of way to
simulate polymorphism or inheritance in C).
All DeHackEd lumps and wads are now queued in the order they were
once processed, and then all are processed in that order at one time,
immediately after EDF.
Sound lumps found from W_InitMultipleFiles must also be queued. If
their processing is not deferred, EDF doesn't get a chance to define
those sounds first, which results in all the sounds being declared
as new. Also, the sound queue must now store lump names instead of
lump numbers as it was able to do in fraggle's code, because once
W_InitMultipleFiles returns, the master wad directory has been re-
ordered and any cached lump numbers from before will be invalid. This
fact wasn't obvious to me and caused me a LOT of trouble for several
hours.
I am preparing to possibly move all sound definitions into EDF, since
all of these changes are amenable to that happening.
=====================================================================
09/11/03
Began a massive code-reordering effort in d_main.c that will enable
addition of EDF-in-WAD support. Said support may not debut until beta
5 however, because of scheduling constraints.
=====================================================================
09/08/03
Added sound deltas. Updated the EDF docs for the sound and sound
delta sections. Updated the console docs on the openlog and closelog
commands.
=====================================================================
09/07/03
Added a true console logging system which writes all lines to a text
file before they are sent to the console. The new commands openlog
and closelog control this feature. The dumplog command still remains
as a way to save the current console buffer (useful if you need to
get something but didn't have logging on already, in particular).
Changed external use of current_target and current_height console
variables by the animshot command. Now it calls C_InstaPopup, a
function that achieves the same thing it was doing directly. Also
determined that the command prompt strings in c_io.c can be made
static.
With logging enabled, I altered the cmdlist command to print one
command per line, fixing the readability issue with it. Of course,
you will HAVE to use a log to read the whole thing since it is so
long, so this is still kind of annoying. A future idea is to let a
filter be provided that will cut the list down in size.
Added module e_cmd.c to contain EDF-related console commands. Wrote
the e_dumpthings command, which prints out a formatted list of every
thing type's important ID data, including DeHackEd number, editor
number, and mnemonic.
=====================================================================
09/03/03
Added support for dynamic sounds through EDF; added module e_sound.c
and consolidated all sound hashing into the code there. The former
run-time sound hashing code that was in s_sound.c now calls down to
the corresponding EDF functions.
Sounds are no longer hashed by their lump name field, since this is
unreliable. They now also contain a mnemonic, which in some cases is
equal to the lump name, but isn't required to be. They also contain
a DeHackEd number field, like frames and things, so that new sounds
added by EDF can be referred to directly by things and frames.
S_StartSound and the DeHackEd parser use E_SoundForDEHNum now, so
that they can play any sound with a valid DeHackEd number, and not
just the builtin sounds. (Oh yeah, the original sound definitions
are still internal, although they can be edited with sound delta
structures, which I still need to implement).
New sound lumps starting with the DS prefix are still automatically
added to the sound hash, too. They won't be accessible via DeHackEd
of course, since there's no way to assign them a number. They can
be used by script though, and they are given a mnemonic equal to
their lump name minus the DS part, for full backward compatibility.
I also found a bug in i_sound.c where SoM tried to reimplement
channel wrap-around. It wasn't working properly thanks to some screwy
code from PrBoom. I have no idea if it's working right now though; it
needs significant testing. I could swear I've heard a lot of sounds
cutting off since I made the change, but maybe I'm just crazy...
I wish we could just use the SDL_mixer library completely...
=====================================================================
08/28/03 - 08/31/03
Since SoM is unable to work on Eternity right now given his insane
job schedule, we've decided to go ahead and push for a rapid beta 4
release featuring significant EDF revisions and possibly more Small
scripting groundwork (I hope to at least get ExtraData TIDs finished).
Lots of recent tweaks and bugfixes:
* Found a small error in the demo reading code that would prevent
BOOM and MBF demos from loading; fixed it.
* Tweaked the D_HashTableKey function used by EDF and DeHackEd/BEX
hash tables. No significant improvement in EDF resulted :P
* Fixed a problem with savegamename's default value being set after
building BEX hash tables. This might have made BEX save game name
replacement break (but hardly any patches use it, so it wasn't
noticed).
* Put a kludge in FireCGun that stops it from crashing the game when
it is used on guns with different firing frames. It may not be
totally backward-compatible, but its behavior has always been
poorly defined anyways.
* Fixed a MAJOR problem with my custom libConfuse lexer that was
preventing GFS and EDF to load at the same time. I had to write a
function that totally resets the lexer to its initial state after
libConfuse is done parsing. This error was not introduced until
JUST before beta 3 release, which explains why I didn't catch it.
* Fixed a ridiculous problem caused by the incorrect assumption that
SDL key codes range from 0 to 255. Numpad keys generate codes
greater than 255, and were thus causing out-of-bounds accesses in
the shiftxform and keybindings tables. For now, I_GetEvent filters
out-of-range key events. I'd rather actually support the numpad in
the future, though.
* Generalized code in e_edf.c to create E_ProcessThing and
E_ProcessState, and added delta structure support to EDF. The next
release of Eternity will represent EDF version 1.1. BTW, delta
structures allow easier, more flexible editing of existing frames
and things. They can cascade, as each is applied to its target in
the order they're parsed (top to bottom always), and each only
lists the fields it wishes to edit. The other fields of the object
won't change.
* Tweaked the cfg_opt_t structures for EDF to provide for complete
case insensitivity, including the ability to refer to thing and
frame mnemonics without being correct in case. EDF 1.1 won't
error out or goof up if mnemonics differ only by case.
* Slightly edited the speedset and nukespecial code to support later
editing of speedsets and nukespecials, so that delta structures can
alter the values without introducing redundant list and hash table
items.
* Edited C_AdjustLineBreaks to push the console up a line early if
the first segment of a string cannot fit at the end of the current
line. The way I did it is definitely not ideal, but then neither is
most of the other console code. The cmdlist command's output looks
a bit better now, though it is still very difficult to read since
it's so bunched up. I don't have a solution for it yet.
* Made a small change to E_StateNumForDEHNum to support old, incor-
rect DeHackEd patches that use negative state numbers in some
fields. They will automatically be remapped to the null state now,
which is probably what the authors intended in virtually all cases.
For future reference, negative state numbers are NOT to be used
in DeHackEd or EDF.
* Fixed a minor typo in the frame overwriting example in the EDF
documentation. Also added docs on the new features added so far,
so that I don't have to do it all at once later ;)
=====================================================================
Changes since Eternity Engine v3.31 beta 2
=====================================================================
=====================================================================
08/08/03
Eternity Engine v3.31 public beta 3 released!
Moved the call to D_ProcessGFSWads so that command-line wads are
added AFTER them, so that they override any GFS-specified wads.
=====================================================================
07/25/03
Eliminated all direct usage of state number constants; added functions
E_SafeState and E_NullState to EDF, and added a check to make sure the
S_NULL frame is defined. It, like the "Unknown" thing type, is always
required, and the game will bomb out if it's not found.
So far the beta testers haven't found any actual bugs. I think most
of them have stopped testing either out of laziness or boredom. I
will probably release a second alpha, but if there's not much action
on it, I will release v3.31 public beta 3 shortly.
=====================================================================
07/19/03
Fixed the following Small compiler issues:
* error(209) in "doreturn" that was causing a segv was fixed by
changing it into error(209, symname)
* for loop label deletion problem was fixed
* promoted error 54 (mismatched closing brace) to fatal error status
to stop an assertion failure / crash in the parser. This is a kludge,
but is the best that can be done without a full understanding of the
compiler
Schepe helped fix a major problem with pvsnprintf that was causing it
to write past the end of strings with integer formatting in them,
trashing the stack and causing a "two-week bug"-like effect. Problem
was that pvsnfmt_int looked like it was written in two minutes :->
Schepe is now mentioned on the "About" screen under special thanks,
for his consistently helpful disposition toward Eternity ^_^
Also realized that I made the buffer in C_Printf too small. Increased
it to 1024, the limit of reasonability. I'm pretty sure nothing ever
prints a line larger than that to the console. Even if something does,
at least it will only truncate now, and not overflow.
Released EE v3.31 beta 3 private alpha 1 to the beta testing team.
=====================================================================
07/18/03
Fixed one of the known issues in the Small interpreter. Array indices
could be one greater than the maximum index into the array, due to a
simple logical error -- use of > where >= was needed.
Since it looks like Thiadmer has abandoned work on Small, I will begin
to address known issues with it in Eternity's internal copy. The
remaining issues with Small that are known to me, mostly in the
compiler, are listed here for future reference:
* The "expand" function which decompresses AMX binaries on big-
endian machines may not work on some large inputs, especially
programs with large arrays. It seems to use some type of asinine
circular byte queue. There are two possible approaches to fixing
this -- either don't compress AMX binaries on big-endian targets,
thereby bypassing the problem altogether, or try to figure out
precisely what this function is doing and fix it. Since Eternity
hasn't been officially ported to any big-endian targets, this is
low priority.
* A call to the error function in "doreturn" in sc1.c in the compiler
source may cause a SEGV. Problem may be a missing parameter; should
be easy to fix if I can verify the problem exists.
* for loops may delete labels. As with the above, this compiler bug
needs to be verified. If it is for real, I have a fix for it too,
which I found on the Small forums.
* Code near line 236 in sc2.c (compiler again) performs a "ptr--;" on
the current line, but may walk right off the near end of the string
on blank lines. I don't have a fix for this, but it can probably
be hacked at due to the nature of the error (C related, and not
deeply semantic). I'm unsure what triggers this error.
* There may be some confusion going on between the ++ and -- operators.
I have no idea what this is about or what could be causing it, and
furthermore I don't know how to trigger it. If it shows up, I don't
think I'll be able to fix it :(
* The sizeof operator may behave erratically when multidimensional
arrays are passed to functions. The user who reported this error was
vague about it, however. It may just be that they didn't understand
the way that Small uses arrays. I should be able to write some test
programs for this, but I doubt I'll be able to fix it if there's a
problem :/
This is a lot of problems. Most of them are in the compiler, and
can be avoided either by writing correct code (which is always good),
writing slightly different code (who really NEEDS ++ or -- anyways),
or by avoiding things like HUGE arrays, or passing arrays to functions
(could just use a global, or some other approach, and use known array
indices when possible instead of sizeof).
I was getting discouraged about Small, but since fixing the array
issue I feel better and I think I was just being a brat earlier,
wanting everything my way without having to work for it. I will attempt
to trigger more of these errors, and if I can, fix them. The Small
compiler is a beast, though, so I'm not optimistic about fixing very
many of its issues. Hopefully they will turn out to be largely
avoidable. I would love for Eternity to have an almost bugless
scripting language, so that people can write ridiculous, huge, and
impractical scripts in it, but the time for realism is now. The
alternative, changing languages again, is less appealing to me than
having to warn people about a few problems in the Small compiler.
=====================================================================
07/13/03
Eliminated all direct usage of thing types. Features and changes
incurred during the process:
* Rewrote the segment of code in the killem cheat / nuke console
command that took special actions for certain thing types. It is
now codepointer-based. A thing type can specify a "nukespecial"
and give it a BEX codepointer mnemonic. It is then added to a
very small hash table in m_cheat.c, and the special action is run
whenever a thing of that type is killed by the cheat. The only
two pointers expressly made for use with this are PainNukeSpec and
SorcNukeSpec, for the Pain Elemental and D'Sparil's first form,
respectively.
* Made -fast speeds for projectiles editable. When "fastspeed" is
set by a thing type, a speedset_t is allocated and put into a
linked list in g_game.c. Any time the -fast mode of the game is
changed, all the things in the list will have their speeds swapped
appropriately. It saves a significant amount of space to not keep
this field in mobjinfo_t itself, as it does for the above.
* Made particle effects editable as a new flag field in mobjinfo.
Available particle effects are:
* ROCKET -- thing gives off a rocket trail
* GRENADE -- thing gives off a grenade trail (this effect may change)
* FLIES -- thing has a persistent swarm of flies around it
* BFG -- thing has a persistent BFG particle swarm
It is also possible to specify the particle fountain effects, but
only one at a time, and this is of minimal use, so I will not list
them here. Note when missiles explode, their particle effects are
disabled.
* Made monster item drop types editable as a new field in mobjinfo.
Simply specify "droptype" and list another (or the same!) thing
type for it to drop. This is not related to the HticDrop pointer in
any way, so its effects could even be combined with this. There's
absolutely no limit to what something can drop, be it a powerup,
another enemy, keys, etc. Only one drop item is specifiable via
this field, though.
* Added a method-of-death field to mobjinfo and provided a way to
edit MOD types in EDF, although this is currently somewhat insatis-
factory, as I have it using simple integer values rather than strings.
Its a pain to add a bunch of strings and do yet another search over
them 9_9 These were added to enable a total rewrite of the obituary
system...
* Rewrote the obituary system. Two new const char * fields in mobjinfo
point to dynamically allocated obituary strings, one for normal
attacks and one for melee attacks. Non-thing death messages, such
as those for falling damage, nukage, crushers, and deathmatch, are
editable through BEX text mnemonics.
* Made the thing types spawned by Boss Brains through the SpawnFly
codepointer editable. You just specify a list of 11 thing type names
in order, like this:
boss_spawner_types =
{
DoomImp, Demon, Spectre, PainElemental, Cacodemon, Archvile,
Revenant, Arachnotron, Mancubus, HellKnight, BaronOfHell
}
This doesn't allow you to add MORE thing types, and there MUST be
exactly 11. But this is more flexible than it was before. To allow
even more flexibility would either require breaking compatibility,
or providing some very hackish and clumsy extra fields.
* Added the following flags3 values in order to generalize a number
of previously hard-coded thing type behaviors:
* MF3_NOTHRESHOLD -- Archviles have no damage threshold for
acquiring a new target. If anything hurts them at all, they will
start fighting it. Normal enemies won't change targets for a
while.
* MF3_FLOORMISSILE -- Code for the Maulotaur's floor missile has
been in Eternity all along. This generalizes the ability for a
floor-running missile to go up steps and down drop-offs.
* MF3_SUPERITEM -- Specifies that the item will respawn only when
the "super items respawn" deathmatch flag is asserted. The only
things with this status by default are the InvisiSphere and
InvulnSphere.
* MF3_NOITEMRESP -- a new effect, enables an item to not respawn.
This was not previously an option, and would probably be useful
for some "unique" items in mods.
=====================================================================
07/12/03
Began the process of converting direct usage of thing type constants
into DeHackEd number lookups. Identified several new "EDF FIXME"
points and have begun to address them one by one.
Changed the skin viewer code to resolve the MT_PLAYER type in its