Commit graph

1205 commits

Author SHA1 Message Date
Christoph Oelckers
c8c8fecad3 - fixed a few warnings. 2019-09-16 17:30:39 +02:00
Marisa Kirisame
bcef440511 Squashed commit of the following:
commit 6ecd831eb45a8258995c02664450c3ca8cfe5b48
Merge: a4fb1f61c afbd7f7a2
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Sun Jul 28 22:02:19 2019 +0200

    Merge branch 'master' of github.com:coelckers/gzdoom into f3dfloor_export

commit a4fb1f61c0532d3a6051d4c1fca4ac72ec33e060
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Fri Jul 12 15:43:25 2019 +0200

    Renamed EFFloorType enum in ZScript to the more descriptive EF3DFloorFlags

commit 9ad1c3b5625d53c06229be2a94d44fa0f36f41fd
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Sun Jul 7 20:25:31 2019 +0200

    Add bounds checks to Get3DFloor/GetAttached

commit dd2a7956a887b92ed24ce5e79f10b1a445664d6c
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Sun Jul 7 17:13:44 2019 +0200

    Correct handling of 3d floor plane texture getting.

commit 9b748287892c8fdee9ac67019bf1f66bc4b69eab
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Sun Jul 7 16:14:45 2019 +0200

    Implemented requested changes to F3DFloor exports.
    * Getters for ffloors/attached arrays.
    * Getter for 3D floor top/bottom texture.

commit 6a1482bb0637a70890629e4c13e8759c7a3673f3
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Sat Jul 6 13:42:52 2019 +0200

    Renamed exported extsector pointer in Sector struct to something more descriptive.

commit 7c6783d43b898cbd7a01fb2191fd401ed8e8c300
Merge: ff64e04b2 8d36f0a0c
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Mon Apr 29 12:40:44 2019 +0200

    Merge branch 'master' into f3dfloor_export

commit ff64e04b251f23325d2f72bc25c59f34b4cab6fa
Merge: a90947392 5b6bae409
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Sun Apr 21 16:56:18 2019 +0200

    Merge branch 'master' into f3dfloor_export

commit a90947392a27eb1c2dac7005614592ec2f410274
Author: Marisa Kirisame <marisa@sayachan.org>
Date:   Mon Feb 4 17:47:25 2019 +0100

    Export F3DFloor structure and related data.
    Small changes to Trace code to better use this struct.
2019-09-11 08:19:19 +03:00
alexey.lysiuk
98128d9fa3 - added ability to specify deprecation messages in ZScript
It's an optional extension of deprecated keyword:
    deprecated("2.4", "use ModernFunction instead") int OldFunction();
    deprecated("3.5", "use ModernVariable instead") int OldVariable;

Usage of such members will produce the following report:
    Script warning, ":zscript.txt" line 123:
    Accessing deprecated function OldFunction - deprecated since 2.4.0, use ModernFunction instead
    Script warning, ":zscript.txt" line 456:
    Accessing deprecated member variable OldVariable - deprecated since 3.5.0, use ModernVariable instead
2019-08-28 13:37:48 +02:00
Petr Kobalicek
747b3dfcfe AsmJit update 2019-08-19 21:02:36 +02:00
alexey.lysiuk
28ea567c22 - fixed doubling of deprecation warnings for ZScript code
https://forum.zdoom.org/viewtopic.php?t=65617
2019-08-15 16:31:50 +03:00
Christoph Oelckers
cf74118d53 - fixed the extremely long standing bug that Lost Souls didn't reacquire their target when slamming into something.
This was one of that annoying old design mistakes where Doom and Heretic features were poorly merged together. The Heretic Gargoyle uses very similar coding but performs a subtly different action when actually hitting another actor. This different action was made the default, even for the Lost Soul.
It has now been changed that both monsters use their original action, being distinguished by an actor flag. For compatibility with custom definitions Heretic's behavior, which has been the default in ZDoom will be the preferred one. The one of the Lost Soul can be reactivated by a flag.
2019-08-11 09:00:29 +02:00
alexey.lysiuk
07a2331ca3 - exposed Append() method to ZScript dynamic array
https://forum.zdoom.org/viewtopic.php?t=65570
2019-08-10 16:37:40 +03:00
Christoph Oelckers
3e99216967 - added option to print a map author's name on the summary screen
For now only with font-printed map names. Allowing this with titlepatches will require more work and an option to disable.
2019-08-02 09:11:40 +02:00
Christoph Oelckers
c36dc137ba - made adjustments to the text placement on the summary screen.
With extended fonts much of the old code did not work anymore, this needed more precise checks for the sources of the printed texts.
2019-07-30 10:53:02 +02:00
Major Cooke
15eabfd055 Added A_SoundPitch and an optional pitch parameter to A_PlaySound and S_Sound.
- Note: Because sound channels are not in zscript, there's no way to modify a sound made by S_Sound.
2019-07-24 20:15:24 +02:00
drfrag
416f5d03b7 - Fixed compilation with MinGW. 2019-07-15 19:26:25 +02:00
Christoph Oelckers
cd7438c02e - made some adjustments to the text spacing on the level summary screen.
With the extended fonts some parts here caused too large gaps.
2019-07-14 12:44:42 +02:00
alexey.lysiuk
b7e0a8d2c7 - added validation for presence of drop item classes
https://forum.zdoom.org/viewtopic.php?t=65307
2019-07-11 14:11:01 +02:00
alexey.lysiuk
9332a63ce5 - fixed LevelLocals.isFrozen() return value with JIT disabled
No more 'Number of parameters returned differs from what was expected by the caller' assertion failures
2019-07-07 15:31:06 +03:00
Christoph Oelckers
5df8919b90 Merge branch 'master' into userlights 2019-07-07 08:11:09 +02:00
Rachael Alexanderson
bc88ceea94 - clarify too old ZScript version message 2019-06-30 22:14:23 -04:00
cybermind
1b7aeb35e1 Fixed copy-paste typo in SphericalCoords 2019-06-29 21:32:41 +03:00
Christoph Oelckers
1dcbe43d95 - User definable dynamic lights
This hasn't been tested yet!
2019-06-28 12:35:42 +02:00
Chronos Ouroboros
1b106d109d Fixed "if (!(lhs ~== rhs))" breaking with vectors. 2019-06-14 12:49:57 +02:00
alexey.lysiuk
d27a7cd84b - removed explicit self null tests from dynarray native wrappers
They are useless since d3e6ed3c9b in which generation of implicit self null pointer check was added to JIT
2019-06-09 10:27:21 +03:00
alexey.lysiuk
4a2ae357a2 - report implicitly initialized variable in code generator once
Vectors are no longer reported several times
Previously, warnings were issued per every register
2019-06-08 11:12:34 +03:00
alexey.lysiuk
6f1df5b5ab - added implicit initialization of reused register variables in ZScript 2019-06-07 13:43:51 -04:00
alexey.lysiuk
d3e6ed3c9b - added null check for self pointer before calling a native function
With JIT enabled, an implicit test for null self pointer is added to generated code
This has no effect without JIT as VM verifies a pointer before calling a native method

https://forum.zdoom.org/viewtopic.php?t=64961
2019-06-07 11:02:38 -04:00
Chronos Ouroboros
87c426dcfd Really fixed arrays of dynarrays this time. 2019-06-05 08:24:56 +02:00
Alexander
380398bcd6 added native double round(double) function 2019-06-03 19:48:45 +02:00
alexey.lysiuk
d9c619c800 - adjusted condition for ZScript global variable deprecation warning
The message is always printed for any use of deprecated global variable
If such variable is accessed inside a deprecated function from a core script lump, the message is printed only when verbosity level is set to highest

https://forum.zdoom.org/viewtopic.php?t=64830
2019-05-30 10:20:49 +03:00
alexey.lysiuk
249e658f8b - fixed missing deprecation warnings for ZScript global variables
https://forum.zdoom.org/viewtopic.php?t=64830
2019-05-29 17:37:31 +03:00
alexey.lysiuk
38291dfacc - fixed: version wasn't set for ZScript global variables
https://forum.zdoom.org/viewtopic.php?t=64830
2019-05-29 17:37:08 +03:00
alexey.lysiuk
d336a83355 - fixed code generation for ternary operator with vector result types
https://forum.zdoom.org/viewtopic.php?t=64831
2019-05-29 13:24:03 +03:00
alexey.lysiuk
677b24b108 - fixed crash on message output during decorate parsing
Script position is now initialized at the very beginning of decorate parsing process
Script position no longer contains uninitialized file name

https://forum.zdoom.org/viewtopic.php?t=64836
2019-05-28 18:13:34 +03:00
alexey.lysiuk
64ce71eae2 - fixed wrong native call for Actor.Vec2Offset()
https://forum.zdoom.org/viewtopic.php?t=64810
2019-05-25 17:14:52 +03:00
alexey.lysiuk
f5d80d0d8b - made setting actor TID more explicit
Now it's no longer possible to manipulate TID hash from arbitrary location
For example, this prevents linking of destroyed object into the hash
TID member is still public but writing to it is limited to a few very specific cases like serialization and player traveling between levels

https://forum.zdoom.org/viewtopic.php?t=64476
2019-05-10 11:49:57 +02:00
alexey.lysiuk
3767a9aec1 - fixed missing null checks in JIT generated code
https://forum.zdoom.org/viewtopic.php?t=64307
2019-04-27 17:05:36 +03:00
alexey.lysiuk
dd7ec1fe44 - fixed crash on JIT allocations over 1 MB
https://forum.zdoom.org/viewtopic.php?t=64383
2019-04-27 14:36:55 +03:00
Christoph Oelckers
e0a0be4f7b - added a CanPrint function to FFont and used that to handle the statistics display on the automap HUD to only replace the font when actually needed, not based on the language. 2019-04-22 09:08:43 +02:00
Player701
747906730c Added support for monospacing alignment modes to HUDFont / BaseStatusBar.DrawString (#810)
* - Added support for monospacing alignment modes to HUDFont / BaseStatusBar.DrawString

* - added underlying type declaration for EMonospacing

* - replaced "#include v_video.h" with a declaration of EMonospacing
2019-04-13 18:10:58 +02:00
Christoph Oelckers
3938119192 - added CharUpper and CharLower functions to ZScript.
These, like MakeUpper and MakeLower, use the internal Unicode case conversion tables.
2019-04-13 10:26:55 +02:00
Christoph Oelckers
f7561f25d6 - added Unicode aware MakeUpper/MakeLower functions to FString and ZScript's String and deprecated ToUpper/ToLower because their semantics did not allow fixing them. 2019-04-13 10:12:33 +02:00
Christoph Oelckers
bcf7bc8d34 - added some UTF-8 utilities to FString.
This deprecated CharAt and CharCodeAt for being unsuitable for text processing and in the case of CharCodeAt also for being buggy.
A new replacement, ByteAt has been added that reads a string byte by byte, as well as CodePointCount, which counts the amount of Unicode code points in a string and GetNextCodePoint which reads the string code point by code point.
Note that while this woll work as intended with the currently supported languages as a means to read single characters, there is no guarantee that this will remain so if Unicode support gets extended to things which break the "one code point == one character" assumption.
2019-04-13 09:31:36 +02:00
Christoph Oelckers
9e096c62fd - allow the automap HUD to use the VGA font. 2019-04-10 20:39:15 +02:00
alexey.lysiuk
5c86a1e6b5 - fixed crash with push/insert to null dynarray when JIT is on
https://forum.zdoom.org/viewtopic.php?t=64148
2019-04-04 13:23:08 +03:00
Chronos Ouroboros
8dea4f9523 Fixed arrays of dynamic arrays causing a compilation error. 2019-03-13 12:42:45 +01:00
Chronos Ouroboros
7165b40657 Fixed nested dynamic array indexing causing a compilation error. 2019-03-13 10:23:06 +01:00
Christoph Oelckers
ef3e5ef01e - moved a few parts from g_level.cpp to better fitting places. 2019-02-23 15:21:54 +01:00
Christoph Oelckers
5e7fb16d05 - preparation work for substituting the menu and intermission screen text graphics for localization 2019-02-19 01:22:12 +01:00
Christoph Oelckers
aa550310f6 - allow the language table to supersede the title patches, if appropriate
For the Doom IWADs the provided font looks almost identical to the characters used on the title patches. So, for any level name that got replaced in some language, it will now check if the retrieved name comes from the default table, and if not, ignore the title patch and print the name with the specified font.

This also required removing the 'en' label from the default table,  because with this present, the text would always be picked from 'en' instead of 'default'. Since 'en' and 'default' had the same contents, in any English locale the 'default' table was never hit, so this won't make any difference for the texts being chosen.

Last but not least, wminfo has been made a local variable in G_DoCompleted. There were two places where this was accessed from outside the summary screen or its setup code, and both were incorrect.
2019-02-15 00:29:24 +01:00
Christoph Oelckers
deb233677e - made the menu's text input handler Unicode capable.
Also make sure that the savegame description remains readable. Unlike in-game text this can be done without double-encoding existing UTF-8.
2019-02-16 21:29:46 +01:00
Christoph Oelckers
64685705d0 - made the console Unicode-capable.
This also necessitated some character remapping in the console font to move the Windows-1252 extra characters to their proper Unicode code points.
2019-02-16 13:05:19 +01:00
Christoph Oelckers
88e227f1f3 Merge branch 'new_level_refactor' into localization 2019-02-09 12:22:15 +01:00
Christoph Oelckers
3d3f260137 - exported LevelLocals's compatibility flags to scripting and fixed all places where access to combined compatibility flags is needed. 2019-02-09 09:17:57 +01:00