Author Topic: [STAT TRACKING] Soldier Diaries 1.0  (Read 536666 times)

Offline Shoes

  • Commander
  • *****
  • Posts: 502
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #915 on: August 09, 2015, 03:22:21 pm »
Accuracy % should be doable: I think I already track shots fired and shots landed...

Kills per missions can also be done with the tracking that's already there, so it could also be added to the kills screen or another screen.

Total service days should also be doable, but I would need to add a a bit of code as I only track months now.

Graphs I haven't considered. As there is already code to produce graphs, I might be able to graph things...

And now performance rating! I would be interested in calculating one for the soldier, as the soldier score can be the same for a lot of soldiers. What do you think would go into the performance rating? Kills per mission x accuracy?

edit: Regarding timeline, hopefully soon :x I'll ignore bug fixes for the moment and merge to TFTD.
« Last Edit: August 09, 2015, 03:24:31 pm by Shoes »

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #916 on: August 09, 2015, 08:03:44 pm »
Hi Shoes! Glad to hear a new version is coming up. The aquanauts definitely need their medals too!

As for bugs, I've come to the conclusion that the "kill one of every X" awards are not given properly. I have a lot of soldiers with the "Taking Names" medal, even though I have never killed a commander, similarly, I have a lot of "one of every race" even though I have never seen ethereals.

Is it possible that, as currently built, ranks/races that you kill multiple times still give credits, meaning you can kill 7 soldiers and that will give you 7 ranks even though they are all the same rank?

Offline Shoes

  • Commander
  • *****
  • Posts: 502
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #917 on: August 09, 2015, 08:20:35 pm »
Hi Shoes! Glad to hear a new version is coming up. The aquanauts definitely need their medals too!

As for bugs, I've come to the conclusion that the "kill one of every X" awards are not given properly. I have a lot of soldiers with the "Taking Names" medal, even though I have never killed a commander, similarly, I have a lot of "one of every race" even though I have never seen ethereals.

Is it possible that, as currently built, ranks/races that you kill multiple times still give credits, meaning you can kill 7 soldiers and that will give you 7 ranks even though they are all the same rank?

Something is up with how the ruleset is being read, and it's messing up any commendation that has multiple criteria. Instead of reading all the criteria, it reads one of them, and runs with it. That one is going to be hard to track because it's not a change on my end that is causing the problem. Once it gets fixed though, you will be able to debug-clear your medals and get them properly awarded.

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #918 on: August 09, 2015, 08:38:41 pm »
Oh, that sucks.. I wish I knew anything about C++ to help! Too bad scientists use Fortran for coding :(

The way medals are given and can be reset is really neat btw :) It's nice to have such a safe system!

Offline kikimoristan

  • Commander
  • *****
  • Posts: 647
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #919 on: August 10, 2015, 02:16:00 am »
for the time you can convert your month variable into a float and capture it every hours. then you can modify all your regular code to use floor down the month variable as n int. but for graphing type code you use float to generate days, hours etc. ex 1.5 month would be 1 month and 15.5 days but rounded down is 46 days of service. you always round down. right?


for efficiency rating maybe this

i guess as an xcom operative most important is alien kills

however as an efficiency rating maybe enemy percentage of total alien kills / mission / no of missions.

ex:
20% of all enemies killed / mission 1
0% kills / mission 2
50% kills / mission 3

(20% + 0% + 50%) / 3 = 23.3333333333% of all aliens encountered killed


then you find accuracy % / mission / number of missions

then you can do something like

% kills * % accuracy


theoretically max number would be 100 x 100 you killed everything and missed nothing.
but realistically  is probably gonna be much lower.

ideally the higher the number the better performance your unit had in the game or more impact. highest values means valuable assets.


what do you think?
« Last Edit: August 10, 2015, 02:49:18 am by tollworkout »

Offline kikimoristan

  • Commander
  • *****
  • Posts: 647
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #920 on: August 10, 2015, 03:16:57 am »
shoes i don't know how your mod works but i was thinking you could split up this mod into 2 components:
1.  tracking engine & interface enhancements as code and have code provision for awards/medals as a modder feature. uses regular xcom assets.
2.   commendations/awards/medals as a mod in a rul using your modder features  and assets from resource in a mod folder

this way you could easily include 1 in the main branch by making a pull request. warboy or supsuper may be into it

also might simplify your life by focusing on code letting someone else focus on the commendations part. ppl could even make their own awards.

if no awards are defined in any rul file nothing shows up but all the other stats special dialogue is there forever for everyone to use.

the awards as a mod would simply be  conditional if varibles match values then award is given. up to 3 variables . something like that.

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #921 on: August 10, 2015, 04:34:54 am »
That's already how it works :P

The executable tracks the stats and puts them in saves, plus it adds the interface for seeing the records. Then there is a mod that you enable and can tweak which enables the awards and adds the commendations section to the UFOPaedia. It's a pretty good system :)

The only problem is part of the ruleset not being processed properly for some reason (which as far as I know only impacts the kill/stun one of each terrorists/ranks/races awards).

Offline Shoes

  • Commander
  • *****
  • Posts: 502
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #922 on: August 10, 2015, 02:09:18 pm »
@tollworkout, that sounds good. I think rank should be considered too. What do you think is more important, stun or kill?

And as Arthanor says, the mods are seperate :) if you turn off "Commendations" in the mod list, the stats are still tracked and can still be viewed. The commendations buttons in the Records windows and the ufopaedia are removed when the mod is off too. :D

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11408
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #923 on: August 10, 2015, 06:24:13 pm »
@tollworkout, that sounds good. I think rank should be considered too. What do you think is more important, stun or kill?

I'd say stun is better, since it's easier to blow them up than capture them. Besides, having a living alien means you'll get a corpse at some point, too. :)

Offline kikimoristan

  • Commander
  • *****
  • Posts: 647
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #924 on: August 10, 2015, 06:45:30 pm »
shoes, what do you think about this

stun unlocks key research  but since stuns happen less often maybe weigh them equally .

(kills + stun ) / 2

kills = aliens killed / total aliens encountered
stun = aliens stunned / total aliens encountered

this works because it calculates based on total aliens encountered and you cannot stun and kill at the same time. if you stun and they die later counts as stun. so max is 100 if you stun 50% of all aliens encountered and kill 50% of all aliens encountered

then that times acc

(kills + stun ) / 2 * acc

acc = successful hit / total attacks made
 
if you wanna measure efficiency maybe  rank shouldn't count. this would be equal for everyone.  but if you do it should't count too much

Offline Shoes

  • Commander
  • *****
  • Posts: 502
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #925 on: August 10, 2015, 07:03:44 pm »
I suppose you and I have a different thing in mind: if you're measuring efficiency, then yeah rank shouldn't matter and nor should stun or kill; if the alien is down, you dun good. I was thinking more of a "experience" level, where higher ranking aliens and races would award more points, and so would stuns over kills.

I'm not fond of the efficiency rating simply because it would be so low. Compounded with poor accuracy, I would find most soldiers would have a rating of near zero. I prefer the "experience" level, because that just keeps going up. It'll be like score, but more customized to the individual soldier.

All this said, most data is being tracked to calculate the efficiency rating, so it could be added too. Experienced soldiers can be inefficient after all ;p

Offline DoxaLogos (JG)

  • Colonel
  • ****
  • Posts: 358
  • Squaddie cautiously peering through the breach
    • View Profile
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #926 on: August 10, 2015, 07:27:56 pm »
Let's see.  I like a lot ideas so far.  I have concerns though, because some weapons are naturally more efficient than others that don't necessarily represent the skill of the solider (i.e. blaster bombs anyone?).  It feels like the soldier who always carries the blaster launcher is going to be skewed as the most efficient.  I don't know if a weapon scale factor needs to be added to balance that bias out of the rating.  However, given these mods, it may be very hard to come up with a good weapon scaling factor.

I don't mind including rank of the alien as part of the performance rating, but you need to balance it out by including its negative counter part: killing civilians (or your fellow soldier) reduces your rating. 

Of course separate ratings like kill efficiency and a performance could be supported as a way to gauge your soldiers overall experience.
« Last Edit: August 10, 2015, 08:09:49 pm by jgatkinsn »

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11408
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #927 on: August 10, 2015, 08:05:56 pm »
Yeah, even without using explosives (which can be coded to be treated differently) it will come up, since a sniper rifle will hit way more often per bullet than a minigun. (The fact that neither is present in vanilla X-Com is irrelevant.)

What can be done though is factoring the "experience bonus per hit" against weapons' accuracy, and even better against actual accuracy (modified by distance if applicable). Therefore a person who often hits with a pistol would get more exp than one who often hits with a rifle. And explosives would be worth less than normal bullets/beams, too.

Offline Dioxine

  • Commander
  • *****
  • Posts: 5412
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #928 on: August 11, 2015, 12:02:01 am »
What can be done though is factoring the "experience bonus per hit" against weapons' accuracy, and even better against actual accuracy (modified by distance if applicable).

Jesus, this is a very Nietzchean model there, Solar, isn't it too hardcore? :)

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11408
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: [STAT TRACKING] Soldier Diaries 1.0
« Reply #929 on: August 11, 2015, 12:22:28 am »
Jesus, this is a very Nietzchean model there, Solar, isn't it too hardcore? :)

Well, it wasn't me who came up with the idea for performance in the first place. I only said what should be done to make it worthwhile.

While I'm not really excited about rat races, seeing the smug, annoying sniper sarge getting torn to shreds by a cybermite will be satisfying. 8)