Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a way to remove 'world' statistics from quakestats? #74

Open
sedawkgrep opened this issue Sep 1, 2023 · 5 comments
Open

Is there a way to remove 'world' statistics from quakestats? #74

sedawkgrep opened this issue Sep 1, 2023 · 5 comments

Comments

@sedawkgrep
Copy link

My buddy and I almost exclusively play 1v1, but even at the most extreme we never have more than five of us.

Is there a reasonably easy way to remove all the 'world' stats/categories?

@brabiega
Copy link
Owner

brabiega commented Sep 5, 2023

Hi there. At the moment it's not possible. However it should be fairly easy to implement.
I'll see what I can do, but my time is quite limited these days...

@sedawkgrep
Copy link
Author

sedawkgrep commented Sep 6, 2023 via email

@sedawkgrep
Copy link
Author

I just realized while looking at the q3 source, that world represents deaths due to the environment (lava, slime, etc). I thought it was some holdover from a team-based match.

Don't waste your time with removing it.

Is there a way to contact you directly? I'd like to ask you a few questions about the database layout and some of the fields in various collections. While we're probably going to use your tool to get the stats into the db, we're going to be using our own little website (with map ratings, comments, etc.) and pull the stats from mongodb.

You can reach me via my username at either yahoo or gmail if you don't mind dropping me an email.
Thanks,
Andrew

@brabiega
Copy link
Owner

brabiega commented Oct 2, 2023

Hey, actually yesterday I had a moment of time to clean up some dust and take a look into the source code.

You may want to take a look if this does the trick. From the other hand as you said world in most cases represents death due to the env.

diff --git a/src/quakestats/dataprovider/analyzer/scores.py b/src/quakestats/dataprovider/analyzer/scores.py
index b5cb4e5..85d0175 100644
--- a/src/quakestats/dataprovider/analyzer/scores.py
+++ b/src/quakestats/dataprovider/analyzer/scores.py
@@ -52,6 +52,9 @@ class PlayerScores:
         victim_id = player_kill.victim_id
         mod = player_kill.mod
 
+        if killer_id == 'q3-world':
+            return
+
         self.kills.append((game_time, killer_id, victim_id, mod))
 
         # not self kill

@brabiega
Copy link
Owner

brabiega commented Oct 2, 2023

Feel free to reach me directly via https://github.com/brabiega/quakestats/blob/master/setup.py#L35

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants