Commit graph

15583 commits

Author SHA1 Message Date
Marisa Kirisame
670c86cd47 Fix a major oversight that caused UE1 models to use the normals of the first frame for all frames. 2018-09-25 21:00:04 +02:00
Marisa Kirisame
a9b25242cd Hotfix: The output from CheckReplacement no longer permanently overrides an actor's replacement. 2018-09-23 23:40:58 +02:00
Magnus Norddahl
3b8b312fae - clamp the software light to never get brighter than the initial light level 2018-09-23 17:58:17 +02:00
Kevin Caccamo
525ab8eda3 Attempt to fix warnings from VS2017 Win64 compiler 2018-09-22 12:49:54 -04:00
Kevin Caccamo
7d4895d9df Calculate normals for OBJ models with smooth groups
Add smoothGroup member to OBJFace struct, and assign the current smooth group number to it
Move face normal calculation code to CalculateNormalFlat
Add AddVertFaces method, which initializes and populates the vertFaces array of arrays, which holds references to triangle references per vertex
Only initialize and populate vertFaces if the model has missing normals and smooth groups
Assign smooth groups to triangle data
Add CalculateNormalSmooth method, which calculates the normals for each face the vertex is attached to, depending on whether or not the faces are part of the given smooth group, and averages them out
Add OBJTriRef struct, which holds references to triangles on OBJ surfaces

Make {agg,cur}SurfFaceCount unsigned ints
Change nvec to a value instead of a pointer
2018-09-22 10:24:01 -04:00
Magnus Norddahl
5bf76523d6 - switch ToMemAddress to imm_ptr where allowed 2018-09-18 18:13:53 +02:00
Magnus Norddahl
05ac219ba6 - switch from ASMJIT_ARCH_X64 to ASMJIT_ARCH_64BIT when checking if we need to use 64-bit pointers 2018-09-18 18:05:53 +02:00
Magnus Norddahl
ad260aa971 - create a very basic OP_IJMP implementation 2018-09-17 21:52:21 +02:00
Magnus Norddahl
61735ddd8b - create CreateCall helper to get rid of a lot of the cc.call boilerplate 2018-09-17 12:00:25 +02:00
Magnus Norddahl
f61df60240 - implement OP_TAIL and OP_TAIL_K 2018-09-17 09:02:23 +02:00
Magnus Norddahl
d032914c3d - use the ParamOpcodes array for finding the OP_PARAM's used by a call 2018-09-17 00:31:25 +02:00
Magnus Norddahl
da040e818c - implement string version of OP_CAST 2018-09-17 00:17:32 +02:00
Magnus Norddahl
102c00ce13 - implement string part of OP_CASTB 2018-09-16 22:39:48 +02:00
Christoph Oelckers
bc1e659c7b Revert "- reworked fog uniforms to move the global fog mode setting to the viewpoint buffer."
This reverts commit 8b26b6dd1e.

This was causing problems with light mode 2 because some edge cases were no longer handled properly.
2018-09-16 22:38:20 +02:00
Marisa Kirisame
38c8f0d585 Adds OnDrop virtual to inventory items. Called on the dropped item at the end of AActor::DropInventory. 2018-09-16 17:58:57 +02:00
Christoph Oelckers
4c13a8df6e Merge branch 'master' of https://github.com/coelckers/gzdoom 2018-09-16 13:52:13 +02:00
Christoph Oelckers
e13d1e4d0d - do not render lights from uninitialized data. 2018-09-16 13:52:02 +02:00
David Carlier
58c6614c03 silent few warnings 2018-09-16 09:09:47 +02:00
Magnus Norddahl
c8e4bf089c - implement OP_LFP 2018-09-16 03:39:54 +02:00
Magnus Norddahl
ba4606c1d5 - read the parameters and registers directly off the stack 2018-09-16 03:20:56 +02:00
Magnus Norddahl
30fb6268bd
Merge pull request #581 from Gutawer/asmjit
Changed a bunch of manual address additions in string opcodes to leas
2018-09-15 23:57:08 +02:00
Jonathan Russell
69bc39914b - changed a bunch of manual address additions in string opcodes to leas 2018-09-15 21:09:43 +01:00
Magnus Norddahl
3477b22714 - more load fixes 2018-09-15 18:08:01 +02:00
Magnus Norddahl
4364feea9a - fix truncated load addresses due to a bug in asmjit
- change ToMemAddress to use uint64_t
2018-09-15 15:38:16 +02:00
Magnus Norddahl
06b54d3aaa - avoid certain x86::ptr overloads as the last argument is not always an offset 2018-09-15 15:05:52 +02:00
Rachael Alexanderson
74d939c0d2 - archive 'multiplayer' flag in savegames. https://forum.zdoom.org/viewtopic.php?f=2&t=61980 2018-09-15 08:16:02 -04:00
Major Cooke
1210e1a951 Added DMG_EXPLOSION flag.
- This allows modders to determine if damage is caused by an actual explosion, assigned by P_RadiusAttack and BlastActor for +TOUCHY actors.
2018-09-15 13:23:11 +02:00
Major Cooke
c988a0b3a4 Allow LineAttack's LAF_NOINTERACT to fill FTranslatedLineTarget's information.
- Originally when the flag was made, LineAttack was not yet exported. This can now be benefitted directly from ZScript.
2018-09-15 13:22:26 +02:00
ZippeyKeys12
60f82d1eb9 Make StatusScreen::End virtual
https://forum.zdoom.org/viewtopic.php?t=59419
2018-09-15 13:21:13 +02:00
ZippeyKeys12
7885a22cad Add NewGame to EventHandler
https://forum.zdoom.org/viewtopic.php?t=61908
2018-09-15 13:20:41 +02:00
alexey.lysiuk
7d1af25b46 Fixed code generation of infinite for loop
https://forum.zdoom.org/viewtopic.php?t=62023
2018-09-15 13:19:28 +02:00
Magnus Norddahl
c505e4eb79
Merge pull request #575 from Gutawer/asmjit
Implemented SS_R, LCS_R, and LKS_R
2018-09-15 13:09:07 +02:00
Christoph Oelckers
3046a7dd81 - be more thorough with 'in menu' checks for certain protected functions.
They would also pass the test if a menu just was open but not the actual invoker.
Also error out if this happens so that modders can see that they are doing unsupported things. Silent failure is not a good idea here.
2018-09-15 12:30:05 +02:00
Christoph Oelckers
53ee7cfc7b - fixed some warnings in OBJ model code.
(This clearly shows that using 'long' as parameters in any interface must be stopped. It is fundamentally unsafe to have a type whose size is not reliable - it's either an int-sized nor a pointer sized value, depending on the platform, and essentially worthless.)
2018-09-15 12:27:14 +02:00
Jonathan Russell
407418a92e - fixed typo in last commit 2018-09-15 00:26:14 +01:00
Jonathan Russell
b83f4f48d6 - implemented SS_R, LCS_R, and LKS_R 2018-09-15 00:25:13 +01:00
Magnus Norddahl
ce9925d257 - fix bug in LKF_R 2018-09-15 01:06:48 +02:00
Magnus Norddahl
7e7bce4965 - fixed OP_VTBL bug 2018-09-15 00:28:34 +02:00
Magnus Norddahl
266f838de7 - fix crash in OP_RET handling 2018-09-15 00:12:12 +02:00
Magnus Norddahl
663e61a4fb - simplify some code 2018-09-14 23:38:57 +02:00
Magnus Norddahl
90d8d4af24
Merge pull request #573 from Gutawer/asmjit
Added string PARAM and RET
2018-09-14 20:07:47 +02:00
Jonathan Russell
11fbd9a0a4 - added string PARAM and RET 2018-09-14 18:20:31 +01:00
Magnus Norddahl
4e85134d8e Merge remote-tracking branch 'gzdoom/master' into asmjit 2018-09-14 02:09:17 +02:00
Magnus Norddahl
d09a377f12 - fix clang errors and warnings 2018-09-14 01:07:05 +02:00
Magnus Norddahl
2ea97bac6d
Merge pull request #571 from Gutawer/asmjit
Added OP_MOVES, OP_CONCAT, OP_LENS, OP_CMPS
2018-09-14 00:50:50 +02:00
Jonathan Russell
0b6c514067 - added OP_MOVES, OP_CONCAT, OP_LENS, OP_CMPS 2018-09-13 20:31:06 +01:00
Magnus Norddahl
c359601737 - fix opcodes not being listed in jit debug assembly 2018-09-13 19:03:30 +02:00
Magnus Norddahl
b92e5fbf2a - move EmitRESULT to jit_call 2018-09-13 02:56:02 +02:00
Magnus Norddahl
fad8c9c7b4 - minor cleanups in header file 2018-09-13 02:38:51 +02:00
Magnus Norddahl
ef170883ef - split JitCompiler into multiple files 2018-09-13 02:29:04 +02:00