Is it possible to get the accuracy stat per game? And this might not be possible but are we able to get accuracy per weapon?
GC
Is it possible to get the accuracy stat per game? And this might not be possible but are we able to get accuracy per weapon?
GC
Yes, absolutely.
You can retrieve the [Arena, Warzone, Custom, Campaign] Service Record and interrogate the [Arena, Warzone, Custom, Campaign]Stats.WeaponStats property.
You can calculate accuracy by simply working out TotalShotsLanded / TotalShotsFired (you could also look at TotalHeadshots, TotalKills etc.)
Here’s a quick Python script to showcase this: gist.github.com/gitFurious/60a832ffa20f0bc622ef (you can pull the WeaponId from the Metadata API).
Whoops. You said per game.
You can still do it.
You can look at individual arena stats scoped to the following:
Thank you so much! I will be playing with these soon. Honestly between a Day Job, desire to constantly be playing all different portions of the game, and using the API, There are simply not enough hours in the day.
Hi,
If anyone can direct me. Furiousn00b has great examples on how to start solving this problem. The problem is shows how to display the weapons accuracy’s based on their ID’s. I would like to have the names simply generated programatically from the meta data. The problem is I’m struggling to find a way to break down the meta data by its individual components. I understand the metadata is put into a list but I am failing to access the properties of each element of the list. I would like to search by the weapon ID and have it send back that information associated with that ID.
Can anyone help me out?
Thanks,
GC
Check this out.
https://gist.github.com/DerFlatulator/55682d097624340ad3ea
If you want to run this code you can head here, copy and paste the code in, insert your API key where it says, and hit run.
The code is heavily commented.