mtasa-resources icon indicating copy to clipboard operation
mtasa-resources copied to clipboard

deathmatch: major refactor

Open jlillis opened this issue 5 years ago • 3 comments

When merged, this PR will refactor the deathmatch gamemode. Here is a list of improvements:

  • Integration with defaultstats to handle default weapon stats
  • Integration with mapcycler to trigger a map vote at end-of-round
  • The gamemode will now respect the deathpickups.only_current setting
  • More robust handling of game/player states
  • New loading screen that displays the map name and author
  • Game logic regarding the HUD and camera moved clientside
  • General code quality improvements, including comments
  • Line endings converted to LF - this refactor turned more into a rewrite, so I chose to treat the code as new. As discussed on discord new files are supposed to use LF endings. Unfortunately, this makes some of the diffs a little messy.
  • Redesigned HUD designed to emulate vanilla style
  • Added ability to define infinite frag or time limits (not both simultaneously) and disable respawn

This refactored version is fully compatible with existing deathmatch maps. I believe it is at a point where it is ready for feedback and testing.

Some TODOs:

  • Improvements to textlib code for performance (use rendertargets). Improvements to textlib code should be ported to other resources using textlib.
  • Improvements to existing deathmatch maps - maybe add some new ones?

jlillis avatar Jun 24 '20 04:06 jlillis

@jlillis This is still a draft right? Any plans to continue, or are you waiting for others to do so? (considering it was almost a year ago and this PR is stale)

Dutchman101 avatar Mar 02 '21 04:03 Dutchman101

There are still a few changes I've made but not pushed to a PR yet. I'll have this updated and moved out of draft in a week or two.

jlillis avatar Mar 02 '21 17:03 jlillis

I have a few other PRs that I would ideally like to get merged ahead of this, but I'm going to say that this is ready for review at least.

jlillis avatar Mar 19 '21 18:03 jlillis

Got this cleaned up. I think it's ready to merge but hasn't been playtested beyond me and a VM. If this looks good, I'd like to merge and then give tdm/tdma modes the same treatment.

jlillis avatar Jan 17 '23 02:01 jlillis