Notable deletions:
- Metal Sonic Race
- Includes all the specialised recording/playback apparatus which made g_demo.c harder to read
- A bunch of hyperspecialised code inside several A_ actions
- EXCEPTION: intentfully left in the spriteless SMK stuff for Sal's add-on down the line.
There were a few remaining cases of bot ticcmd generation editing player structures directly. Fix all of this and make as much of it pass const player pointers so this physically can't be allowed to happen ever again. Appears to improve bot sync in netgames & demos bot support, but I have not tested extensively.
If player is in one of these states:
- Invincibility
- Grow (K_IsBigger)
- Flame Shield dash
- Over 200% speed
And the other object:
- Does not have MF_DONTPUNT
Then, touching a solid object:
- Punts the object, unless the object has MF_ELEMENTAL
- Fizzles the object, if the object has MF_ELEMENTAL
Or, when an object damages the player:
- That object is punted, unless it has MF_ELEMENTAL
- The object fizzles, if it has MF_ELEMENTAL
Punting means:
- A copy of the object is made
- Both the player and copy receive 5 tics of hitlag
- The copy is thrust away from the player at a minimum of
60 FU, or 2x either the player's or object's momentum,
whichever is ultimately greater
- The copy despawns after 2 seconds
- The copy flickers constantly, while thrust away
Fizzling means:
- The object disappears completely
- A puff of smoke is spawned in place of the object
- No hitlag is applied to the player
Both punting and fizzling:
- Hide the original object (intangible and invisible)
- The original object reppears after 30 seconds
- For 2 seconds before reappearing, the object flickers
back in, but is still intangible
A first pass in attempts to fix crashes when ACS causes map changes.
Frustratingly still got a crash, but I think this is definitely the right foundation to work with.
`Condition1 = UfoAttackMethod [type]`
- "smash a UFO Catcher using only [type]"
- Combine with `Prefix_SealedStar` or `Prefix_IsMap [special stage stage]`
- Shows up as "???"
- Types supported:
- `Boost` - "boost power" (sneakers)
- `Whip` - "Insta-Whip"
- `Banana` - "Bananas"
- `Orbinaut`- "Orbinauts"
- `Jawz` - "Jawz"
- `SPB` - "Self Propelled Bombs"
- Other types could be added on request, these were just the easy ones
In addition, the prototype for P_MobjWasRemoved was moved to `p_mobj.h`.
It's EXTREMELY important that we're able to safely check mobj pointers anywhere a mobj_t is possible to observe, without including the full `p_local.h`...
A series of 100 booleans on the roundconditions struct, one per possible lap.
Allows for a full suite of track hazard touching conditions - see the following examples.
- `Condition1 = Prefix_IsMap RR_MOTOBUGMOTORWAY
- `Condition1 = TrackHazard No`
- `Condition1 = IsMap RR_MOTOBUGMOTORWAY`
- "MOTOBUG MOTORWAY: Don't touch any track hazard"
- `Condition1 = Prefix_GrandPrix`
- `Condition1 = IsMap RR_HARDBOILEDSTADIUM`
- `Condition1 = TrackHazard Yes`
- `Condition1 = And`
- `Condition1 = FinishPlace 1`
- "GRAND PRIX: On HARD-BOILED STADIUM, touch a track hazard every lap & finish in 1st"
- `Condition1 = Prefix IsMap RR_DEATHEGG`
- `Condition1 = Trackhazard No 8`
- "DEATH EGG ZONE: Don't touch any track hazard on lap 8"
- `Condition1 = Prefix_IsMap RR_SPEEDHIGHWAY
- `Condition1 = TrackHazard No Final`
- "SPEED HIGHWAY: Don't touch any track hazard on the final lap"
- Avoid iterating displayplayers to find view number and
prefer R_GetViewNumber.
- Iterate over all matching displayplayers if necessary,
instead of stopping at the first match.
- There's a freeze cheat bool to freeze everything except for players.
- There's a level freeze bool to freeze literally everything.
- There's a frozen bool on mobj_t to explicitly control freeze status on an object.
Replaced all mentions of starpostnum and Starpost w/ cheatchecknum and CheatCheck (so Ivo can stop asking why we still need it when its going to save our asses on release patches)
- Replaces a few D00DKart objects because the doomednum specifically replaced one of these
- Reports on load if the map has too many, or if one's assigned but the object doesn't exist
After turning on freecam, the vertical angle is tilted
slightly downward (this is carried over from normal
chasecam).
Interpolate that angle back to normal while moving
forward. This makes it so you don't need to manually
adjust the vertical angle, since it would cause forward
movement to send you into the ground.
(This commit does not compile. Sound test and tunes
command code needs to be ported after this.)
This is a big one. Here's the rundown:
The old music system was very direct, much of the time
just a proxy to the real sound API in i_sound.h.
You could change the music on command, but there wasn't
a consistent way to prevent some music from playing over
others. P_RestoreMusic is one example of needing to
address this problem. The jingles system was intended as
another solution. Furthermore, sound test (Stereo) has its
own needs.
I am removing all of that. Music handling in general is
now a very deliberate system, kind of similar to jingles.
In the new system, "tunes" are registered. The tune stores
info such as whether it should loop or fade out. Most of
the configuration is intended to be initialized only ONCE.
Tunes can be mapped to an actual music lump. They can be
remapped at any time too.
Tunes are also configured with a priority number. This
determines which tune is heard, if multiple are supposed
to be playing at a time. You can even tell a tune how long
it should play, so it's unnecessary to track this with
bespoke timers.
There are two differences between Whumble and Stumble.
- Stumble cannot be combo'd on upwards momentum, while whumble can. (Resolves#522)
- Whumble takes bumpers, while stumble does not.
- Removes the MT_INSTAWHIP hack.
Map things are writeable in Lua, which I am pretty certain is a mistake because mapthings are not sent over the network at all. I considered making them net-synced (it would be relatively easy), but it also aligns with another, more "philosophical" issue: Doom generally copies over properties from mapthing_t into mobj_t, and then only refers to it again when needing to respawn an object -- mapthing_t is not really intended to be referred to very often at runtime. At best it's slightly annoying since some objects rely on a spawnpoint for behavior changes, at worst it may make ACS more confusing in the future since Thing and Mobj tags are mixed together or less useful since they wouldn't be able to modify behaviors of objects that are based on args.
So I decided to solve these two issues at the same time; just treat mapthing_t as something to copy values from, like OG Doom does it. This basically just means that special and args are also part of the mobj now instead of the mapthing, which should fill any desire to edit this stuff from Lua, and reduces the number of instances where objects need to check for their spawnpoint to function properly.