Christoph Oelckers
45dc9a7b47
- renamed the level variables.
...
currentUILevel is now primaryLevel.
For ZScript, currentVMLevel was added. This is also exported as 'level' and will change as needed.
This also means that no breaking deprecations will be needed in the future, because in order to sandbox a level only 4 variables need to be handled: level, players, playeringame and consoleplayer.
The remaining global variables are not relevant for the level state.
The static 'level' has been mostly removed from the code except some places that still need work.
2019-02-02 00:25:51 +01:00
Christoph Oelckers
ff903da19a
Merge remote-tracking branch 'remotes/origin/master' into new_level_refactor
2019-01-31 20:43:24 +01:00
Major Cooke
b1c508fa6c
Added CheckReplacee.
...
- Allows defining of what actor is replacing another for information.
- If multiple arachnotrons, a modder can attribute them as being a replacer of Arachnotron itself, allowing A_BossDeath and GetReplacee to work with it.
2019-01-31 19:05:44 +01:00
Erick Tenorio
b9e71d6db3
- DOOM.WAD fixes
2019-01-31 19:03:57 +01:00
Christoph Oelckers
cfa35f548f
- make the file name of savegame nodes read only.
2019-01-31 17:57:39 +01:00
Christoph Oelckers
68bff17d63
- this was missing
2019-01-31 03:29:45 +01:00
Christoph Oelckers
ddab2c3e78
- removed the playernum parameter from CheckLocalView
...
This was always used with 'consoleplayer' which really is the only thing making sense here. But this is a part of the global state which should be avoided in play code.
In particular, this makes no real sense in case of secondary maps where it should always return false.
2019-01-31 03:29:25 +01:00
Christoph Oelckers
0eb3b2abca
Merge branch 'master' into new_level_refactor
2019-01-30 22:03:21 +01:00
Christoph Oelckers
a2065cae4b
- fixed: RecreateAllAttachedLights must activate the lights it creates.
...
This also removes the gl_attachedlights CVAR because with the new management this doesn't really work anymore.
2019-01-30 20:21:00 +01:00
Christoph Oelckers
b12de04258
- fixed the remaining deprecation warnings in the base script.
...
All these required access to the sector's Level reference.
The remaining references to the global 'level' variable are all in deprecated functions which is ok.
2019-01-30 00:58:44 +01:00
Christoph Oelckers
6451b7d592
- moved the combined compatibility flags into FLevelLocals.
2019-01-29 19:28:22 +01:00
Christoph Oelckers
14101fa447
- health groups and software rendering textures freed of 'level'
...
Edited cherry-pick of an older commit.
2019-01-29 16:06:17 +01:00
Christoph Oelckers
f9239f6e0f
- added a compiler-side workaround for the formerly static methods of FLevelLocals.
...
LevelLocals on the left side of.a function call will now always be remapped to 'Level', which will either remap to the same-named instance variable or the global deprecated one.
In a few degenerate cases where there is a conflicting local variable named 'level' it may error out but that is unavoidable here but this is very unlikely.
2019-01-29 02:04:31 +01:00
Christoph Oelckers
60873bc5d6
Moved the PointInSector functions into FLevelLocals
2019-01-29 01:30:41 +01:00
Christoph Oelckers
259ae41774
- sanitized the 'frozen level' code.
...
This had two different flags that were checked totally inconsistently, and one was not even saved.
Moved everything into a few subfunctions so that these checks do not have to be scattered all over the code.
2019-01-28 20:15:48 +01:00
Christoph Oelckers
3721771934
- forgot to save this.
2019-01-28 18:44:42 +01:00
Christoph Oelckers
3c14a7db76
- use map time, not hub time for map actions.
2019-01-28 18:42:56 +01:00
Christoph Oelckers
66695ac6a0
- made most of the player spawn spot handliing functions members of FLevelLocals.
2019-01-28 02:44:05 +01:00
Christoph Oelckers
b4acb857ad
- the final batch of easy level replacements.
...
What's left will require a bit more work...
2019-01-27 21:59:19 +01:00
Christoph Oelckers
73ea59179c
- fixed some deprecation warnings about 'level'.
2019-01-27 14:48:35 +01:00
Christoph Oelckers
84baa5bb4d
- deprecated the global 'level' variable.
...
This will currently output 9 warnings for the UDMF property getters. To silence these a bit more work is needed.
2019-01-27 14:33:02 +01:00
Christoph Oelckers
05830455e7
- made the automap an object.
...
This simplifies handling a lot because it allows to make the level the owner of its map.
2019-01-26 15:21:20 +01:00
Christoph Oelckers
10feb446fa
- made most of the EV_* functions part of FLevelLocals.
2019-01-26 08:28:45 +01:00
Christoph Oelckers
4e052f2857
- use a separate variable pointing to the current level for the UI code.
...
UI always runs on the primary level, so this does not need the ability to operate on multiple levels. Additionally, this can later be set to null when running play code so that scope violations result in an abort.
2019-01-25 18:31:40 +01:00
Christoph Oelckers
bf3dc2f99b
Merge branch 'rolling_back' into new_level_refactor
2019-01-25 00:57:01 +01:00
Christoph Oelckers
b2ee99c7cc
- call level compatibility handlers for all levels and pass the map name as a second parameter.
...
This is for user-made handlers for which the checksum is rather useless both for deciding whether to call the handler and for identifying the map.
2019-01-25 00:56:15 +01:00
Christoph Oelckers
3cef56249d
- moved most functions of portals.cpp into FLevelLocals.
...
Much of this is used during level init and needs to be independent of the current level.
2019-01-25 00:30:55 +01:00
Christoph Oelckers
0e5986769e
- moved the tid hash into FLevelLocals and adjusted the interface to the iterators.
2019-01-24 19:28:40 +01:00
Christoph Oelckers
1f2162fea8
- moved the scripted creation functions for tag iterators to LevelLocals
...
The old static methods are now deprecated, this was done to clarify the relationships at play here.
2019-01-24 02:17:10 +01:00
Christoph Oelckers
5c8ae72453
- fixed: ScriptUtil.PlayerAmmo must be declared static.
2019-01-23 21:50:11 +01:00
Rachael Alexanderson
dc27011370
- remove vid_hwgamma, force always use shader gamma
...
*** note to drfrag: Please don't cherry-pick this commit. Systems that do not use renderbuffers will still need this feature!
2019-01-23 21:50:11 +01:00
Christoph Oelckers
477560e1ef
- swapped order of checks for picking up an item.
...
Failure must take precedence over the morph check because this does not return a proper toucher.
2019-01-23 21:50:10 +01:00
Christoph Oelckers
f6ce5f59ae
- fixed armor bonus giving in A_CustomPunch
2019-01-23 21:49:18 +01:00
nashmuhandes
d911fa99a1
Move the "time" string in saved game comment into the LANGUAGE lump.
...
# Conflicts:
# src/g_game.cpp
2019-01-23 21:48:30 +01:00
alexey.lysiuk
12db808307
- fixed 'missing interpolation point' warning
2019-01-23 21:46:46 +01:00
Rachael Alexanderson
b378b29421
- modify the wording in the preset scaling menu to imply that all it does is pixel scaling, not change the actual screen resolution
2019-01-23 21:45:26 +01:00
Rachael Alexanderson
8f7038aa53
- add 4k UHD resolution to presets
2019-01-23 21:44:27 +01:00
Rachael Alexanderson
c280457635
- fix spacing on one of the resolution preset entries
2019-01-23 21:44:14 +01:00
alexey.lysiuk
7d4765b5cd
- workaround code generation issue in PlayerPawn.FindMostRecentWeapon()
...
Multiple values in returned from a subfunction cannot be used directly as a function result
https://forum.zdoom.org/viewtopic.php?t=63284
2019-01-23 21:41:03 +01:00
alexey.lysiuk
8aa47e664e
- fixed disappearing inventory after morphing pickup
...
When player is picked up item that does morph, the corresponding toucher actor is changed in process
Previously, morhing item was removed from original actor leaving player's inventory in inconsistent state
https://forum.zdoom.org/viewtopic.php?t=63124
2019-01-23 21:40:44 +01:00
Christoph Oelckers
5e4ef04a4d
- allow assignment of line IDs through LevelCompatbility.
2019-01-23 21:40:19 +01:00
alexey.lysiuk
c6ee8e084c
- fixed condition to produce blood splatter during line attack
...
https://forum.zdoom.org/viewtopic.php?t=63186
2019-01-23 21:23:35 +01:00
Christoph Oelckers
2d90cc288b
- fixed: Strife was missing the move factors.
2019-01-23 21:21:22 +01:00
Marrub
af06d7cb9e
Make LevelLocals::ExecuteSpecial return int
...
# Conflicts:
# wadsrc/static/zscript/base.txt
2019-01-23 21:15:33 +01:00
Christoph Oelckers
4126f8ce72
- made OP_NEW a builtin function instead of an opcode.
...
The code was present 3 times due to the JIt, and this is not something that benefits from being a real opcode, even in the interpreted case.
2019-01-23 21:12:23 +01:00
Christoph Oelckers
a1ae01e392
- fixed last PR.
...
The result of GetPointer must be null checked as well!
2019-01-23 20:43:23 +01:00
Cacodemon345
70a07e154c
Move receiver NULL check above the orresult check ( #695 )
...
This is to prevent a VM abort from happening here if orresult is false.
2019-01-23 20:42:41 +01:00
Christoph Oelckers
c651045ed3
- let RunHealth clamping respect the newly added global properties.
2019-01-05 15:37:14 +01:00
Christoph Oelckers
dab68184f5
- moved the global spot state into FLevelLocals.
...
This way it doesn't even have to be a thinker.
2019-01-05 10:04:27 +01:00
Christoph Oelckers
bfbf7ff9c9
- made forwardmove and sidemove defaults configurable through the gameinfo section.
2019-01-05 08:48:57 +01:00