Commit Graph

15630 Commits

Author SHA1 Message Date
Magnus Norddahl 0394dc56b7 - generate a memset for the allocated stack memory because that's what the VM does
(this really shouldn't be done by the VM either - the compiler backend should clear its registers if it wants them to be zero!)
2018-11-15 22:33:13 +01:00
Magnus Norddahl f3e0db913c - fix operand size mismatch error 2018-11-15 22:07:27 +01:00
Magnus Norddahl 3b2faf5397 Merge remote-tracking branch 'origin/master' into asmjit 2018-11-15 22:02:11 +01:00
Christoph Oelckers feef0d4b62 - corrected A_DropFire for real, using the SVE source as reference. 2018-11-15 19:35:07 +01:00
Christoph Oelckers 99f1d6b82e - fixed: A_DropFire accidentally cleared the XF_HURTSOURCE flag by setting only XF_NOSPLASH. 2018-11-15 18:49:37 +01:00
Christoph Oelckers 47138b748a Make BounceFlags 32 bit wide. 2018-11-15 16:53:19 +01:00
Cacodemon345 07838f4c2a BOUNCEONUNRIPPABLES flag; makes actors bounce on actors with DONTRIP flag 2018-11-15 12:47:57 +01:00
alexey.lysiuk 39a3527396 - fixed compilation of targets with optimization 2018-11-15 10:59:37 +02:00
Christoph Oelckers aa4de71e6d Merge branch 'master' into asmjit 2018-11-15 09:25:27 +01:00
Christoph Oelckers cf590d73e4 - extended state caller check to work on CustomInventory items as well
Since CallStateChain is a public member in CustomInventory we cannot really be sure that the given state is valid so it needs checking as well.
2018-11-15 09:24:17 +01:00
Christoph Oelckers 0a21d19723 Added a run time check for calling a state action from the wrong actor type.
This can happen if a state that's retrieved with FindState gets used with a different actor type and can lead to hard to trace problems if not checked.
2018-11-15 09:04:38 +01:00
Magnus Norddahl 8bdebd917c
Merge pull request #631 from Doom2fan/asmjit
Fix the code for MODF_RK in the JIT compiler.
2018-11-15 00:07:55 +01:00
Chronos Ouroboros 96b8f12a30 Fix the code for MODF_RK in the JIT compiler. 2018-11-14 21:05:24 -02:00
Christoph Oelckers 9f6091519f - changed the stencil cap drawer to only cover the area which is actually used by the portal.
This will now both exclude floor caps when only ceiling elements are used and everything outside the bounding box of active portal lines.
Hopefully this is enough to fix the issues with portal caps but of course it is not foolproof if someone just makes the right setup.
2018-11-14 23:30:46 +01:00
Christoph Oelckers a23d1c2d25 - went back to the original portal stencil setup from 3.4.0.
The main reason is to unify the portal hierarchy again. The split into a hardware independent and a hardware dependent part turned out to be unnecessary and complicated matters.
Another issue was that the new stencil setup code was having a few subtle problems, so this recreates the original ones with indirect API calls.
2018-11-14 21:03:54 +01:00
Chronos Ouroboros 566eb58000 Fixed the Vector2/3 != operator. 2018-11-14 20:01:13 +01:00
Magnus Norddahl f76109e479
Merge pull request #629 from Doom2fan/asmjit
Added support for CMP_APPROX to EQV_R and moved the code to a template.
2018-11-14 13:35:19 +01:00
Chronos Ouroboros 5375a99cf6 Added support for CMP_APPROX to EQV_R and moved the code to a template. 2018-11-14 10:29:48 -02:00
Magnus Norddahl 8429fc8124 - fix missing type check when using Push or Insert for typed arrays 2018-11-14 10:08:04 +01:00
Magnus Norddahl 99849bc0c5 Merge remote-tracking branch 'origin/master' into asmjit 2018-11-14 01:23:17 +01:00
Christoph Oelckers a6b44b02b7 - fixed incompletely initialized secplanes in sprite splitting code.
The recent optimization of the shader setup needs the negiC value properly set.
2018-11-13 20:36:23 +01:00
Major Cooke 55f17fa90c Changed A_RaiseActor to just RaiseActor. 2018-11-13 19:01:56 +01:00
Major Cooke f47210df4e Fixed inconsistency.
- P_Thing_Raise returned true while P_Thing_CanRaise returned false for the condition of having no raise state. P_Thing_Raise now returns false.
2018-11-13 19:01:56 +01:00
Major Cooke 71d2b39d92 Added A_RaiseActor(Actor other, int flags = 0) 2018-11-13 19:01:56 +01:00
Major Cooke b553be153d Added CanResurrect(Actor other, bool passive)
- Works similarly to CanCollideWith.
- Passive means the caller is trying to be resurrected by 'other'.
- Non-passive means the caller is trying to resurrect 'other'.
2018-11-13 19:01:56 +01:00
Kevin Caccamo 9520a3c640 Fix swapped horizontal/vertical scale
The UDMF specs for things had the descriptions for horizontal and vertical scale swapped.
2018-11-12 23:09:59 +01:00
Christoph Oelckers 33f2f9f34e - fixed: ZScript's finalization code used the last parsed lump for of one translation unit as reference, not the base lump.
This resulted in incorrect messages but also could produce some more subtle errors.
2018-11-12 00:22:50 +01:00
Christoph Oelckers ca2defa6a2 - added ZScript export for side_t::SetSpecialColor. 2018-11-12 00:13:14 +01:00
Christoph Oelckers 65a6866a1b - fixed typo in ceiling render hack code. 2018-11-11 22:22:29 +01:00
Christoph Oelckers 59790302ec - fixed rendering of lower untextured linedef parts. 2018-11-11 22:17:44 +01:00
Christoph Oelckers a0a2230b92 - removed test code that was accidentally left in. 2018-11-11 21:50:33 +01:00
Christoph Oelckers f2dcff4386 - more options for Doom 64 style gradients on walls:
* Colors can npw be defined per sidedef, not only per sector.
* Gradients can be selectively disabled or vertically flipped per wall tier.
* Gradients can be clamped to their respective tier, i.e top and bottom of the tier, not the front sector defines where it starts.

The per-wall colors are implemented for hardware and softpoly renderer only, but not for the classic software renderer, because its code is far too scattered to do this efficiently.
2018-11-11 16:04:36 +01:00
Player701 d37192c1e8 - Fixed: Decal generator should be taken from the current weapon instance instead of the default instance. 2018-11-11 15:07:57 +01:00
Christoph Oelckers d3aa9c6af1 - do not abort on unclosed sections.
Apparently they can indeed happen with broken map setups like isolated linedefs somewhere in the wild (see Strife MAP08.)
Although they are a problem for triangulation, this isn't what sections get used for currently so it's of no real concern.
In case this is needed later their work data gets marked as 'bad' for the time being.
2018-11-11 10:08:13 +01:00
Christoph Oelckers 094afdfd5f - fixed: It may happen that a degenerate subsector ends up without any section or sector. Try to assign the best fit in such a case so that the relevant pointers are not null. 2018-11-11 09:33:40 +01:00
Christoph Oelckers c946edd9bf - instead of copying the sector planes to GLWall, just store pointers to the front and back sector for later use.
Until now this wasn't doable because these could have come from hw_FakeFlat which only were local copies on the stack.
With the recent change these faked sectors live long enough so that they can be passed around here.
2018-11-10 23:19:08 +01:00
Magnus Norddahl e6023c55a8 - modify exception checks to jump ahead if the exception is to be thrown as it limits static misprediction 2018-11-10 22:48:20 +01:00
alexey.lysiuk 67e012e445 - fixed compilation on POSIX-like platforms
src/p_udmf.cpp:2052:6: error: no matching member function for call to 'OpenMem'
src/sc_man.h:24:7: note: candidate function not viable: expects an l-value for 2nd argument
src/sc_man.h:23:7: note: candidate function not viable: requires 3 arguments, but 2 were provided
src/resourcefiles/file_directory.cpp:198:32: error: use of undeclared identifier 'Filename'; did you mean 'FileName'?
2018-11-10 22:32:09 +02:00
Christoph Oelckers a90655b295 - cache the results of hw_FakeFlat for the remainder of the current scene instead of storing this in local variables.
An exception is made for the sprite drawer which needs to call this in the worker thread on some occasions for as-yet unprocessed sectors.
This case may not alter the cache to avoid having to add thread synchronization to it.

The main reason for this change is that pointers to such manipulated sectors can now be considered static in the renderer.
Due to them being short lived local buffers it was not possible to carry them along with the render data for information retrieval.
2018-11-10 20:07:00 +01:00
Magnus Norddahl a7ef178284 - fix a typo 2018-11-10 19:56:54 +01:00
Magnus Norddahl 173fe94736 - fix the throw messages 2018-11-10 19:52:41 +01:00
Major Cooke 9a7f570b19 Added DMG_NO_ENHANCE for DamageMobj.
- Disables PowerDamage's effect, similar to DMG_NO_PROTECT disabling PowerProtect.
2018-11-10 16:18:33 +01:00
Christoph Oelckers 191f2d9d76 - use TArray and FString in resource file management. 2018-11-10 14:19:55 +01:00
Christoph Oelckers 4d06c17a44 - a few more buffers converted. 2018-11-10 14:18:34 +01:00
Christoph Oelckers 6894912f44 - use TArray for most buffers in p_glnodes.cpp. 2018-11-10 14:15:39 +01:00
Christoph Oelckers 3448749de6 - replaced a few temporary allocations with TArray and added a few convenience loader functions for this.
Amazingly with today's optimizers this creates code which is just as good as doing it all manually with the added benefit of being safer.
2018-11-10 11:56:18 +01:00
Christoph Oelckers 602ea8f723 - made some minor changes to TArray after finding out that "new int()" is not the same as "new int".
With parentheses this initializes to 0 which created needless initialization code in a few places.
2018-11-10 10:43:35 +01:00
Christoph Oelckers cfe51f0c30 - hole filling subsectors must also be explicitly triangulated for the automap because they may be non-convex. 2018-11-10 08:04:03 +01:00
Christoph Oelckers fb7345e470 Merge branch 'master' into asmjit 2018-11-09 22:36:16 +01:00
Christoph Oelckers 3c5609537a - fixed vector math instructions to use the same order of operations as the VM. 2018-11-09 22:36:08 +01:00