Vhati / ftl-profile-editor

Profile editor for FTL: Faster Than Light (www.ftlgame.com)
GNU General Public License v2.0
128 stars 30 forks source link

Calculate the score at any point #67

Closed Niels-NTG closed 9 years ago

Niels-NTG commented 9 years ago

I was wondering if it was possible to get the players score at any point during the game. I can't find anything in this source code that refers to this. Is this because the formula for calculating the final/current score is unknown to the public? Or is just simply because I haven't looked in the right places?

Vhati commented 9 years ago

It's calculated at the end, AFAIK. Neat idea. I hadn't considered doing that. (added to todo list) . . Article: FTLWiki - Score

Score is determined with the following formula (rounded down to nearest integer):

Score = (s+10_b+20_d)*D

. . I haven't tested the math to confirm, but it sounds like these are what you want:

Vhati commented 9 years ago

I'll add a convenience method in the next version of the editor. ; )

Niels-NTG commented 9 years ago

In retrospect I could have googled that myself.. Seems like I could implement that in a minute. I sort of assumed it was something very complicated involving RNG seeds or something last like time.

I will test the math next morning.

Niels-NTG commented 9 years ago

Yup, from this one test it seems to work as intended. Thanks you. schermafbeelding 2015-08-26 om 12 25 26