Commit Graph

10441 Commits

Author SHA1 Message Date
Christoph Oelckers 779f9d7a72 Merge branch 'master' of https://github.com/rheit/zdoom into zscript 2016-11-06 15:13:44 +01:00
Rachael Alexanderson 9f9e4ea19d - Added randi's "bottomclip" parameter to dpJudas's OpenGLSWFrameBuffer::FillSimplePoly implementation. The code refused to compile because of the new changes. Note that this is not tested on Linux or Mac, and will likely need changes there as well. 2016-11-06 08:58:06 -05:00
Major Cooke 2583da9680 Do not allow DMG_FORCED to bypass ultimate degreeslessness/buddha for players. 2016-11-06 07:44:30 -06:00
Christoph Oelckers 10ef430bae Revert "Do not allow DMG_FORCED to penetrate player ultimate degreelessness/buddha."
This reverts commit 0130bde077.

This wasn't supposed to get merged, so get rid of it again. The change in semantics here is not acceptable.
2016-11-06 14:18:13 +01:00
Christoph Oelckers 647fd53a15 - fixed: An 'if' statement with only one branch may never considered to be always returning. 2016-11-06 14:14:54 +01:00
Rachael Alexanderson 901727a7f8 Merge branch 'master' of https://github.com/rheit/zdoom 2016-11-06 08:11:04 -05:00
Christoph Oelckers 6414fd301b - let's add a 'float' cast, too, just in case. It still will cast to double, because single precision floats only can exist as memory values. 2016-11-06 13:21:47 +01:00
Christoph Oelckers 398433b5e6 - fixed: Explicit casts to bool were missing. 2016-11-06 13:20:22 +01:00
Christoph Oelckers 2ac0046cda - fixed and cleaned up state index jump handling
* use the function build list instead of the function to pass the info. The function is permanent so not the best place for compile-time info.
 * pass along the current state index which is needed to calculate the target state.
2016-11-06 13:14:46 +01:00
Christoph Oelckers c354000f1c - block "" and 0 as valid state names in ZScript. There were common workarounds for the lack of a null pointer in DECORATE which no longer are supported as those and would produce errors now. 2016-11-06 12:00:16 +01:00
Magnus Norddahl 3a7532fd9b Improve flat mipmap selection 2016-11-06 11:39:28 +01:00
Christoph Oelckers 062574b726 - fixed damage handling in A_BetaSkullAttack. For unknown reasons this completely bypassed the normal damage function semantics and even multiplied that with a random value.
- made some tests about calling script code from native functions.

 * scriptified A_SkullAttack to have something to test
 * changed the A_SkullAttack call in A_PainShootSkull.
 * use a macro to declare the function pointer. Using local static variable init directly results in hideous code for the need of being thread-safe (which, even if the engine was made multithreaded is not needed here.)
 * Importsnt node here: Apparently passing an actor pointer to the VMValue constructor results in the void * version being called, not the DObject * version.
2016-11-06 11:36:12 +01:00
Christoph Oelckers dbde0971ef - removed the second 'calculated' return value from the damage function call in GetMissileDamage as it is no longer needed or even code being generated for. 2016-11-06 10:28:01 +01:00
Christoph Oelckers c3ae560289 - scriptified two more trivial functions. 2016-11-06 09:22:03 +01:00
Magnus Norddahl aad2cde332 Oops, forced all sandy bridge CPUs to westmere instead of just Pentium G840 2016-11-06 07:37:18 +01:00
Magnus Norddahl 70d4097b34 Fix clamping bug when r_mipmap is off 2016-11-06 07:33:17 +01:00
Marisa Heit 55ee78fc0b Add bottomclip parameter to FillSimplePoly() for the software implementation
- Polygons will be clipped to bottomclip. If this is zero or below, they
  will be clipped to the bottom of the screen instead. This keeps the
  polygons from overwriting the status bar border for sofware 2D. The
  hardware version ignores it, since it always draws the status bar border
  every frame.
2016-11-05 22:49:33 -05:00
Rachael Alexanderson 5e547e9455 Merge branch 'master' of https://github.com/rheit/zdoom
# Conflicts:
#	src/r_segs.cpp
#	src/v_draw.cpp
2016-11-05 23:38:50 -04:00
Marisa Heit dbc54fbca0 Fix FillSimplePoly() for 1-pixel tall or wide textures 2016-11-05 22:30:16 -05:00
Marisa Heit ae28c9b29c Fix divide by 0 in new wallscan functions with 1-pixel tall textures 2016-11-05 22:09:38 -05:00
Major Cooke 0130bde077 Do not allow DMG_FORCED to penetrate player ultimate degreelessness/buddha. 2016-11-05 20:15:41 -05:00
Christoph Oelckers c9a96ed0ae - fixed: CALL_ACTION always set 3 args, even for normal methods. Also moved this to a sunfunction because the macro created a lot of code. 2016-11-06 01:34:54 +01:00
Christoph Oelckers b59f4e950f - fixed: The return prototyxpe may only be retrieved after the return state of the function has been checked. Also made this a real error message instead of an assert because it will inevitably result in a crash if the prototype cannot be generated, making diagnostics impossible. 2016-11-05 21:02:26 +01:00
Christoph Oelckers 0f9ebff3ee - fixed: The return checking code must be inside the nullptr check for item.code. 2016-11-05 18:56:04 +01:00
Christoph Oelckers 0851d698de - don't run constant state indices through the runtime checker. 2016-11-05 18:15:53 +01:00
Christoph Oelckers 1b77a8f491 - fixed: Tacking on a return statement should only be done if the function has branches that actually reach the end. Otherwise it may interfere with return type deduction.
- used the return check to optimize out unneeded jumps at the end of an if statement's first block.
2016-11-05 18:05:57 +01:00
Christoph Oelckers 98fa3d2d93 - added an accessor to the actor defaults. This might have been possible with less work using a function but that would have necessitated some type casts when using it on subclasses.
- scriptified A_BarrelDestroy to test the above.
2016-11-05 17:14:16 +01:00
Magnus Norddahl d084f77546 Fix mipmap generation bug
Fix crash due to dc_source2 not always being set
Add r_lod_bias to control mipmap selection
Improve LOD calculations to take the U texture coordinate into account
2016-11-05 16:12:59 +01:00
Christoph Oelckers 24925c88a8 - added readonly pointers. They need to be defined with 'readonly<classtype>'. These are significantly different from declaring a field readonly in that they do not disallow modification of the variable itself but what it points to. For the actor defaults this is necessary to prevent accidental modification. A readonly pointer is actually a different type than a regular pointer.
- fixed code generation for dynamic cast. It was missing the jump instruction after the compare.
2016-11-05 13:51:46 +01:00
Rachael Alexanderson d4aed28260 Merge branch 'master' of https://github.com/rheit/zdoom 2016-11-05 08:18:53 -04:00
Magnus Norddahl 4b18530047 Add linear filtering to column drawers and fix offsetting bug with wall/span linear filters 2016-11-05 11:29:50 +01:00
Christoph Oelckers ca878b5e6b Merge branch 'master' of https://github.com/rheit/zdoom into zscript 2016-11-05 10:40:02 +01:00
Christoph Oelckers 9ab779fd61 Merge commit '60ae4a8568d9fc929c803036fa16fa0f9bfb68a2' 2016-11-05 10:39:13 +01:00
Christoph Oelckers b890f2b608 - fixed retrieval of constant for state index. 2016-11-05 10:38:23 +01:00
Christoph Oelckers 272dff6b8f Merge branch 'master' into zscript 2016-11-05 10:35:00 +01:00
Christoph Oelckers 76c34d7b2f - block access to private and protected data for the external variabler getter functions.
- fixed: The state index comparison against 0 was broken.
- fixed: Resolving codegen nodes must set the strictness flag per function so that ZSCRIPT and DECORATE are done properly.
2016-11-05 09:50:53 +01:00
Rachael Alexanderson 2fe5cb4f77 Merge branch 'master' of https://github.com/rheit/zdoom 2016-11-04 23:53:05 -04:00
Magnus Norddahl f9fa33c32e Merge branch 'master' of https://github.com/raa-eruanna/qzdoom into qzdoom 2016-11-05 04:50:30 +01:00
Magnus Norddahl 484e1b56be Merge remote-tracking branch 'origin/new_wallscan' into qzdoom 2016-11-05 04:49:54 +01:00
Braden Obrzut dd1f72bbf9 - Check the version of FMOD in CMake to produce an error on the condition that OpenAL is also enabled and the FMOD version is low enough to also export Xiph symbols. 2016-11-04 23:27:04 -04:00
Magnus Norddahl 60ae4a8568 Replace build wallscan with a rewritten version that tile and scale correctly 2016-11-05 04:02:30 +01:00
Christoph Oelckers 514bcfb128 Print a clearer error message if a function name is encountered without parentheses. 2016-11-05 01:24:52 +01:00
Christoph Oelckers 010fd038be - scriptified A_KeenDie.
- added an 'exact' parameter to FThinkerIterator's Next function. This is mainly for scripting which allows to do a lot more checks natively when running the iterator while looking for one specific class.
2016-11-05 01:19:41 +01:00
Christoph Oelckers b6633bc489 - fixed: The states parser tried to simplify the head node for random duration but it has to simplify the two value nodes separately.
- added jump by index to ZScript.
2016-11-05 00:39:00 +01:00
Christoph Oelckers 8ae7aae14a - do not delete duplicate PFields - they are better be destroyed and left to the GC.
- removed two duplicate entries to the flag table.
2016-11-04 15:21:45 +01:00
Christoph Oelckers 407345668a - fixed: ZCCCompiler tried to process replacements too early, it can only be done after all classes have been created. 2016-11-04 15:16:56 +01:00
Rachael Alexanderson a957f72875 Merge branch 'master' of https://github.com/rheit/zdoom 2016-11-04 09:42:25 -04:00
Christoph Oelckers faea61cf01 - fixed: Turbo messages were printed, even when no turbo mode was active. 2016-11-04 12:43:23 +01:00
Christoph Oelckers 540f20882e - fixed: Degeneration should use the same base health value as all the rest of the engine.
- also replaced deh.MaxHealth in the bot code which was the only other remaining case where this was used as health limiter.
2016-11-04 11:32:57 +01:00
Christoph Oelckers 7755a3525a - do not allow menu slider values very close to zero. They not only can produce a glitched number display but also some weird inconsistencies when operating a slider. 2016-11-04 11:17:22 +01:00