Commit Graph

3573 Commits

Author SHA1 Message Date
Christoph Oelckers 25ec3fb8fe - added MF6_RELATIVETOFLOOR flag. 2013-08-10 09:32:55 +02:00
Christoph Oelckers 211d293002 - added MF6_NOTONAUTOMAP flag to exclude things from being shown with the scanner powerup. The IDDT cheat will not be affected by this. 2013-08-10 08:53:37 +02:00
Christoph Oelckers 55f637c906 - fixed: When creating colormaps for 3D floors the model sector's fade value must be used when defining a fog volume. 2013-08-09 23:40:34 +02:00
Christoph Oelckers 9c12c03684 Merge branch 'maint' 2013-08-09 20:36:08 +02:00
Christoph Oelckers 6a07118ea4 - added ML_BLOCKHITSCAN line flag. 2013-08-09 20:35:10 +02:00
Christoph Oelckers a78ad3188b - added MF5_NOFORWARDFALL flag to prevent attacks from making its victim fall forward randomly. 2013-08-09 20:20:23 +02:00
Christoph Oelckers 0a258f95ea - added gravity property to UDMF things. Positive values are multiplied with the class's gravity property, negative values are used as their absolute. 2013-08-09 16:25:16 +02:00
Christoph Oelckers bba092cc0b Merge branch 'master' into scripting
Conflicts:
	src/d_player.h
	src/g_doom/a_archvile.cpp
	src/thingdef/thingdef.h
	src/thingdef/thingdef_properties.cpp
2013-08-09 13:03:28 +02:00
Christoph Oelckers 21bce3b0c4 Merge branch 'maint' 2013-08-09 12:51:26 +02:00
Christoph Oelckers 5d0369d4ed - Ability to set A_VileAttack's initial attack's damage type - by BlueShadow. 2013-08-09 12:18:58 +02:00
Christoph Oelckers b187451a71 - added APROP_ViewHeight and APROP_AttackZOffset submission by TheFortuneTeller. 2013-08-09 12:06:51 +02:00
Christoph Oelckers 34b71baad1 - added Player.Aircapacity property which is used as a multiplier for the level's air supply. 2013-08-09 11:57:14 +02:00
Christoph Oelckers a0c214104d Merge branch 'maint' of https://github.com/rheit/zdoom into maint 2013-08-09 11:47:33 +02:00
Christoph Oelckers e6c880c93a - fixed: The sector's 'hidden' UDMF property did not properly clear the corresponding flag if the value was 'false'.
- added UDMF 'waterzone' property for sectors.
2013-08-09 11:47:25 +02:00
Christoph Oelckers 151d54aaf5 - added 3 more modes for am_cheat: 4-6 are the same as 1-3 with the exception that lines not drawn on the regular automap won't be shown. 2013-08-09 11:32:46 +02:00
Christoph Oelckers 9f35788164 - added custom automap overlay colors.
- extended am_drawmapback so that map backgrounds can only be drawn if used with custom colorsets and Raven's, assuming that these sets were specifically made for the accompanying backgrounds.
2013-08-09 11:00:24 +02:00
Braden Obrzut 5b228ae5a7 Merge branch 'maint' 2013-08-09 00:25:51 -04:00
Braden Obrzut 7e76fb0078 - Fixed: Disable ifitem jumping if a link isn't specified since an invalid value can cause a crash. 2013-08-09 00:25:29 -04:00
Braden Obrzut bb494292c6 - Fixed P_CheckMapData allowed non-map lump names to pass resulting in a crash when actually trying to load the map. 2013-08-08 23:47:58 -04:00
Randy Heit 93cbdd37a5 PArray's size should take alignment into account. 2013-08-08 22:27:40 -05:00
Randy Heit 6c1f3a1396 Added PStruct::AddField() 2013-08-08 22:27:40 -05:00
Randy Heit 476a98652c Remove extraneous PField class
- Remove the existing PField class, rename PMemberField to PField, and
  derive it from PSymbol instead of the old PField.
2013-08-08 22:27:39 -05:00
Randy Heit 7e24f6b00c - Added NewStruct() function. 2013-08-08 22:27:39 -05:00
Randy Heit 0ec33191aa - Added NewEnum() function. 2013-08-08 22:27:39 -05:00
Randy Heit 12a312b6b4 - Fixed: NewArray returned the element type, not the array type. 2013-08-08 22:27:38 -05:00
Randy Heit dbaf72772b Move the symbol table from PClass to PStruct. 2013-08-08 22:27:38 -05:00
Randy Heit 11b588de4a Add names for fallback tokens.
- Fixed: When falling back to the IDENTIFIER token, the identifier it
  would get was undefined, because it never got initialized.
2013-08-02 21:54:50 -05:00
Randy Heit 5cc8a9c2a7 Remove redundant Resolves
- ParseExpression() calls Resolve() on the FxExpression before returing
  it, so there's no need to immediately Resolve() what it returns.
2013-08-02 21:19:05 -05:00
Randy Heit 4f528e3832 Remove lax from FCompileContext
- It's always set to true these days, so let's get rid of it.
2013-08-02 21:13:40 -05:00
Randy Heit 09c902ce55 Remove isconst from FCompileContext.
- It's not used anymore, so keeping it around is pointless.
2013-08-02 21:09:49 -05:00
Christoph Oelckers 8f45e906d4 Merge branch 'automap_colors' 2013-08-02 18:16:05 +02:00
Christoph Oelckers aa72857c72 - implemented automap color parser for MAPINFO (code not tested yet!) 2013-08-02 16:56:42 +02:00
alexey.lysiuk 5c05f1f3cd - Ignored dehacked.exe from *.zip files to enable loading of *.deh files. 2013-08-02 10:17:06 +03:00
Christoph Oelckers 845020c617 - ovthingcolors were not properly set.
- added all the missing color CVARs for the overlays which previously duplicated use of one of the other CVARs.
2013-07-31 23:13:20 +02:00
Christoph Oelckers d77673d681 - reorganization of automap color handling for easier maintenance
Mostly preparation to implement a per-mod automap option but also fixes a few minor issues with some colors that are not defined in the original game specific colorsets.
2013-07-31 22:59:35 +02:00
Edoardo Prezioso 0dc70f847c - Be more compatible with C++11 narrowing conversions system. 2013-07-31 12:27:54 +02:00
Edoardo Prezioso 8cab8f180b - Be clear about the safe 'memset/memcpy' operations on virtual classes.
Since I remember that 'memset/memcpy' is safe in this code, it should be okay to cast to the generic pointer all the 'virtual class' arguments before calling the above functions. Shuts up Clang warnings.
2013-07-31 12:23:31 +02:00
Randy Heit 58f088c1ab Remove FxExpression::EvalExpression() entirely
- For the purposes of getting constant values from expressions, the only
  class where Resolve doesn't duplicate the functionality of
  EvalExpression was FxConstant. So, every other class has had its
  EvalExpression taken away, and FxConstant has had it renamed to GetValue.
2013-07-30 22:52:27 -05:00
Christoph Oelckers 4eb6f74e36 Merge branch 'maint' 2013-07-30 16:53:00 +02:00
Christoph Oelckers 3480d40484 - fixed: AActor::Die may only randomize the death state's duration if it is positive. Otherwise -1 (infinite) gets clobbered. 2013-07-30 16:52:36 +02:00
Christoph Oelckers 9c08a029b1 Merge branch 'maint' 2013-07-30 15:14:10 +02:00
Christoph Oelckers a13af5cc65 Merge branch 'maint' of https://github.com/edward-san/zdoom into maint 2013-07-30 15:08:44 +02:00
Edoardo Prezioso 7e21eafc2f - Fixed mismatched alloc/dealloc in FTextureManager.
The 'TextureFrames', which is attached to all the 'mAnimatedDoors', were deleted with one-pointer 'delete' and they were allocated with 'new[]'.
2013-07-30 13:36:56 +02:00
Christoph Oelckers e01c4e0201 Merge branch 'maint' 2013-07-30 13:18:08 +02:00
Christoph Oelckers 16456bec56 - added separate colors for the various types of 2-sided walls for the overlay automap. They previously all mapped to the same CVAR. 2013-07-30 13:17:20 +02:00
Edoardo Prezioso 4ce0574b3f - Use a more conformant C++ preprocessor macro identifier for Unix systems.
The 'unix' identifier isn't defined when '-std' is passed to the compiler (tested with gcc and clang), so use '__unix__' which is well enough documented.
2013-07-30 11:46:14 +02:00
Christoph Oelckers 81334809c4 - changed autoloading of *.deh lumps: it is now controlled by a CVAR with 3 options: never load *.deh lumps, load all of them or only load the last one. *.deh loading is disabled by default. 2013-07-30 09:32:33 +02:00
Christoph Oelckers 27de9f45af - commented out autoloading of .DEH lumps for maint branch. 2013-07-30 09:25:07 +02:00
Christoph Oelckers 805de60aa4 - fixed: ChangeSpy didn't check if a player's camera's player pointer was valid before using it to get an index into the players table. 2013-07-30 09:16:27 +02:00
Braden Obrzut bc71d4537e Merge branch 'maint' 2013-07-29 18:55:29 -04:00
Braden Obrzut eb5d57be06 - Fixed: crash when closing ZDoom in the save menu and a memory leak. 2013-07-29 18:35:19 -04:00
Randy Heit c810b4d724 Use new degree FLOPs for DECORATE expressions.
- Now that the VM supports degrees, use those instructions when emitting
  code for cos and sin DECORATE expressions. (This looks like it also
  fixed a bug where sqrt also did the degree to radian conversion.)
2013-07-28 20:31:23 -05:00
Randy Heit ff7b1f6e5e Add degree variants of FLOP operations
- Added versions of the trig operations supported by FLOP that can work
  with degrees directly instead of radians.
- Reorder FLOPs into more sensible groupings.
2013-07-28 20:22:47 -05:00
Randy Heit 0468b1f9ce Delete default expressions for action definitions
- After StateParams was removed in commit 4a1fbdb, the expressions for
  default paramaters that ParseActionDef() created went nowhere and were
  lost. Properly throw them away by deleting them as soon as they've been
  parsed.
2013-07-28 20:05:07 -05:00
Randy Heit 241622300e Removed some EvalExpression implementations
- Removed EvalExpression() implementations from some subclasses of
  FxExpression that don't make any sense in the context of evaluating a
  constant value.
2013-07-28 19:40:48 -05:00
Randy Heit 2c24e7f9c6 Remove self pointer from FxExpression::EvalExpression()
- Every place that calls this now (which are all in thingdef_parse.cpp)
  passed NULL for the self pointer, so it was superfluous to have around.
2013-07-28 19:28:14 -05:00
Christoph Oelckers c7d167d278 - used TEXTCOLOR_ #defines for colorizing CCMD list, remove use of strbin1. 2013-07-28 17:15:47 +02:00
Christoph Oelckers 6f4b09cc77 Merge branch 'master' of https://github.com/slatenails/zdoom 2013-07-28 16:42:36 +02:00
Christoph Oelckers c253d40fbb - externalize labels for automap statistics display to the string table. 2013-07-28 16:18:57 +02:00
slatenails 48a29b769f Results for console tab-completion are now color-coded. CCMDs appear blue, CVars green and aliases red. 2013-07-28 14:58:30 +03:00
Christoph Oelckers 909ec2e35a Merge branch 'maint' into scripting 2013-07-28 10:47:17 +02:00
Christoph Oelckers 775ecdeebb - fall back to drawing triangles on automap when encountering actors with non-displayable sprites 2013-07-28 10:14:46 +02:00
Randy Heit 4a1fbdb32a Remove all state expression/param stuff
- This all became vestigial code after the relevant information was all
  moved into FStateTempCall. Now that the MBF code pointer code has been
  converted, I can be sure it wasn't still used anywhere.
2013-07-27 22:34:44 -05:00
Randy Heit 9485752b55 Reimplement MBF code pointer parameters
- Where the old code mucked about with parameter lists to convert misc1
  and misc2 values to action function parameters, we now create new script
  functions using a VMFunctionBuilder to pass the parameters to an action
  function. This code is completely untested, as I have no BEX patches to
  test it with, but at least it compiles without error.
2013-07-27 22:07:37 -05:00
Randy Heit 6cf0916f72 Use VMFunctionBuilder::EmitParamInt in thingdef_expression.cpp 2013-07-27 22:06:14 -05:00
Randy Heit 0603295822 Added EmitParamInt to VMFunctionBuilder 2013-07-27 22:06:14 -05:00
Randy Heit 57bb9c2f7a Better disassembly of FLOP instructions.
- Annotate FLOP instructions with the name of the floating point operation
  indicated by the C field.
2013-07-25 22:29:59 -05:00
Randy Heit 070c0a9e30 Stop leaking function damage expressions.
- Function damage expressions parsed from DECORATE are now stored in a
  single array and deleted at the end of FinishThingdef().
2013-07-25 21:42:30 -05:00
Randy Heit e3e32d7cca Added DeleteAndClear method to TDeletingArray.
- Normally, TDeletingArray only deletes its contents when it is destroyed.
  Now you can do it earlier if you want.
2013-07-25 21:41:18 -05:00
Christoph Oelckers 992ba0bbf4 - added handling of MF3_FOILINVUL for A_BFGSpray. This function needs special treatment because the shooting player is considered the inflictor of the spray damage. 2013-07-26 00:52:12 +02:00
Christoph Oelckers 7006df8d96 - fixed sprite rotation in automap submission 2013-07-25 17:19:36 +02:00
Christoph Oelckers 9ed829c3af Merge branch 'map_sprites' of https://github.com/alexey-lysiuk/gzdoom 2013-07-25 16:39:53 +02:00
alexey.lysiuk 76e1e87456 + things as sprites on map, controlled with am_showthingsprites CVAR
drawing of sprites instead of things/players markers with am_cheat >= 2
possible am_showthingsprites values are:
0 - sprites disabled
1 - static front sprites
2 - animated front sprites
3 - animated sprites with actual things angles
2013-07-25 17:01:07 +03:00
Christoph Oelckers 6dd956c0dc - fixed: Speaker names in dialogues were not able to use the string table. 2013-07-25 15:58:47 +02:00
Randy Heit f6bbd5abf7 Simplify AST dumps.
- More forced line breaks.
- Don't use extra parentheses in places where it can still be unambiguous
  without them.
- Don't print the UserType for basic-types that aren't ZCC_UserType.
2013-07-24 21:35:02 -05:00
Randy Heit 7d304a4cb6 Partially revert commit 46c0127
- Being able to omit optional function arguments is not such a nonsensical
  thing after all. However, the previous grammar was still inadequate for
  representing this in a useful way.
2013-07-24 20:59:29 -05:00
Christoph Oelckers cbc0b70e7c - TransferStencilColor A_SpawnItemEx patch / by Ryan Cordell. 2013-07-24 20:15:17 +02:00
Randy Heit 9c86f1c220 Merge branch 'master' into scripting for plugged userinfo memory leak
Conflicts:
	src/d_player.h
	src/p_interaction.cpp
	src/thingdef/thingdef_codeptr.cpp
2013-07-23 21:01:13 -05:00
Randy Heit a136ca65ea Allow functions without parameters
- Fixed: Trying to define a function without any parameters would silently
  discard the function, because the declarator tested FuncParams instead
  of FuncName to decide if it was a function.
2013-07-23 20:43:15 -05:00
Randy Heit 67caf3303b Add the array size to ZCC_VarName 2013-07-23 19:59:47 -05:00
Randy Heit 0d25ed8289 state_call needs parenthesis around func_expr_list
- Fixed: state_call needs to enclose func_expr_list in LPAREN/RPAREN
  itself, because func_expr_list doesn't include them. This means it also
  needs a separate production to accept calls without a parameter list.
2013-07-23 19:34:21 -05:00
Randy Heit 46c0127ebb Don't accept function params starting with a comma
- Fixed: func_expr_list would accept nonsense like this:
    Myfunction(, 1, 2);
2013-07-23 19:28:58 -05:00
Randy Heit aadd4e4de6 ZCCParseNode needs to initialize TopNode
- If the parsing is a complete failure, then TopNode won't ever be set to
  anything during the parsing process.
2013-07-23 18:38:57 -05:00
Christoph Oelckers af470b3d56 - fixed: The global variables holding the view's fixed colormap must be preserved when rendering to a camera texture. 2013-07-23 12:32:33 +02:00
Christoph Oelckers 181181a865 - removed player_t destructor call in CopyPlayer. 2013-07-23 12:31:44 +02:00
Christoph Oelckers f3d8790995 Merge branch 'maint' of https://github.com/rheit/zdoom into maint 2013-07-22 22:54:45 +02:00
Christoph Oelckers cb3275cb40 - added NORANDOMPUFFZ flag for LineAttack - by Blue Shadow. 2013-07-22 22:47:13 +02:00
Christoph Oelckers 83bd8ba1b8 - added NeuralStunner's player.userange submission, but changed it to use the value directly from the PlayerPawn data.
- bumped savegame version for addition of APlayerPawn::userange.
2013-07-22 22:37:50 +02:00
Christoph Oelckers db562142f0 - Fix c++11 literal suffix warnings / patch by Edward-san. 2013-07-22 22:25:44 +02:00
Braden Obrzut 7723613293 - Fixed: ACS function pointer instructions were not updated when library tag size changed.
- Fixed: undefined sequence compiler warning.
2013-07-22 02:09:46 -04:00
Randy Heit 733e5fa2e1 Recognize C-style array declarations
- The variable_name production now accepts an optional array size
  argument. (Not yet passed to the AST.)
- The notation for using dotted ID lists as types has been changed from
  [id1.id2] to .id1.id2, beacuse the former conflicts with the notation
  for arrays.
2013-07-19 23:25:01 -05:00
Randy Heit 9cf9226e86 Don't leave open parentheses hanging at line breaks 2013-07-17 23:47:06 -05:00
Randy Heit c733e4229a Added more linebreaks to AST dumps 2013-07-17 23:47:06 -05:00
Randy Heit 726ecaf01b Added basic pretty printing for AST dumps 2013-07-17 23:47:05 -05:00
Christoph Oelckers a90b49dc72 - added string table replacement for A_Print, A_PrintBold and A_Log. 2013-07-14 14:33:45 +02:00
Christoph Oelckers 0c86650db0 - fixed: The savegame code for player restoration did some undefined things with the userinfo that only worked due to previous memory leaks. It must ensure that the userinfos get properly transferred and not implicitly rely on the copy assignment being used to copy the actual player data. 2013-07-14 14:22:49 +02:00
Christoph Oelckers a59a886f94 - fixed: The SectorDamage 3D-floor code didn't account for Vavoom-style 3D floors where floor and ceiling plane of the control sector are inverted. 2013-07-14 13:24:00 +02:00
Christoph Oelckers 3e8e587ac7 - fixed another leak with userinfos: Since they are no longer POD they may not be memset to 0 in the player_t constructor. 2013-07-14 12:37:25 +02:00
Christoph Oelckers 2d2498d1e2 - fixed: userinfo_t needs a destructor to delete its CVARs when it is destroyed. 2013-07-14 10:58:53 +02:00
Christoph Oelckers e9be49f37d - fixed: R_DeinitPlanes did not free all visplanes because it called R_ClearPlanes with 'fullclear' set to false.
- removed some redundancy from R_ClearPlanes.
2013-07-14 09:47:39 +02:00