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

Discussion - Merging a game stats display into this project #124

Closed
JohannesMerkt opened this issue Jan 5, 2022 · 5 comments
Closed

Discussion - Merging a game stats display into this project #124

JohannesMerkt opened this issue Jan 5, 2022 · 5 comments

Comments

@JohannesMerkt
Copy link
Collaborator

Hi there again,
three months ago I wrote a little electron app that shows the rankings of the players in your current match.
https://github.com/John-Wickedsick/coh2-player-stats

Back then I wanted to continue to extend this application to also have a detail view available and stumbled upon this project. I have looked at this project and its issues (that have been posted on the repo) in detail and it made me think that it might be very interesting to merge these projects together.

Let me elaborate:
I was thinking, since the electron app uses react too, we could use the UI and data of this project to extend the amount of info (with detail player infos) in the app and provide this app as a download on the site. Then inside this app we can ask the user if he is ok with sharing his match data with us. This is fully optional and the user can still use the app even if he declines. If the user agrees we could use the match replays that are generated after each data to collect additional information to show on the website. Such as match balance info: #118
or arranged team info:
#21
in case we have knowledge about how the data of replays are structured, there are even more possibilities, like unit timings:
#102
This data will be processed on the users pc and posted on the server. The replay won't be uploaded of course only the data we want to collect and show on the website.

Now I would love to hear your opinion about this @petrvecera. Is there any interest in such a thing? Does it make sense when coh3 is on the horizon? Is it ok to have incomplete data? Since we cant collect this kind of data for every match of course.

I for sure would find it very exciting to see such stats on this projects website ;)

@petrvecera
Copy link
Member

Problem: I don't think we would get enough people to use the app.
This is something I have been thinking about even before - the analysis on player PCs. My biggest issue with that was and still is to get people to use the app.

I am not sure if you have analytics and knows how many people are using your app?
For example I do have mako celo or other apps installed by I start them only rarely, not actively using it every time I play.

But for this site - even though this is the only site where you can see player card, recent matches online and I think it's the best site for viewing that data (I hate the in-game menu), there is only around ~250 unique users / day , around 2.5k unique users /month.

I think there is at least 25k players who are playing COH2 +- actively, maybe more - it's hard to get this number, so the site is used by less than 10% ? How many people would be using the app and actively upload their matches. 😕


To get analysis from the replays that would be great, for example for the maps we could also count win-rate based on the starting positions - because I think some maps are unbalanced based on where you start and what faction you play.

There is lot of things we could get. However if we went for it, I would probably keep this analysis separated from the current analysis we can get from the API. So the data sources does not mix. You know - you don't know who is using the app most, if high level players etc

But when I am thinking more about this, I have a feeling that it's too late for this with COH3 on the horizon. Even though I think the coh3 will be here by the end of 2022 I think we should rather save our strength and when that game comes - focus on it more! When we create replay analysis for COH3 it will have much bigger life span than project for COH2 at this time.


Improvements to the Electron App

We could merge the repos and re-use the web components in the app. Or what seems like easier for now, if you are interested in improving your app with additional functionality to simply embed the coh2stats via iframe or something like https://www.electronjs.org/docs/v14-x-y/api/browser-view
And for example when user clicks on the player, you could show https://coh2stats.com/players/76561198018614046 this site in the iframe. We could implement something like cookie or localstorage - idk which would be best and hide the top bar, so only the page would be displayed, something like this:
image

Because right now only the player card makes sense to me to be in the desktop app. I don't see much added value in other functionality (leaderborads, stats) be available in the desktop app when you can simply display it in the browser.


And I can for sure add link to your app to the site. I think we could aggregate more apps there / links to other projects - where you can get for example unit stats.

@JohannesMerkt
Copy link
Collaborator Author

JohannesMerkt commented Jan 6, 2022

Totally agree with you there. I am not sure how many people are actually interested in running an app like this. Im likely the only one that is using mine. But this is also very likely because I never bothered to make sure the community knows about it. It was mainly a fun project for myself.

I suppose for a start embedding the player card view on the app and creating a player rank overview that matches the UI and also has a compact streamer friendly view setting, would be a reasonable way to start with. I think the easiest way would be to have a rank overview and when the user clicks on a player it opens a second window showing the full coh2stats page but already loaded in the player card. Then the user still has the freedom to navigate through the website if he feels like it. Another option is to open the player page in the browser, but I think this might not be liked by everyone. Maybe the user can choose what happens in the settings...

After that we can experiment with the analysis if we want.

@petrvecera
Copy link
Member

Btw for the streamers what would actually be better is to generate .html file which can be loaded in OBS. There is similar project https://github.com/sepi4/myCeloJs

@JohannesMerkt
Copy link
Collaborator Author

JohannesMerkt commented Jan 12, 2022

Quick update: The electron-react-boilerplate, that I previously used, does not support yarn. I was looking for ways to build the app with yarn, but ran into issues when using some nodejs specific packages. I will have to resort to using npm due to 1. since I havent found a working solution and 2. its much less complex. I was trying to include this electron package within this monorepo, but now with npm in a yarn monorepo i dont think its a good idea. Previously I thought in the future some reused UI components from the web package could be shared with the app, but including a npm repo will cause yarn to try and install the app package too which will end in an unsuccessful installation.

@JohannesMerkt
Copy link
Collaborator Author

I decided to keep trying and I found a way now...

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