How to create a ranking formula

1.5k Views Asked by At

This is my first question here. Please forgive if this is the wrong platform for my query.

I am creating a ranking formula for a game I am developing. I want to be able to find out who the best player is based on two criteria :-

-Time
-Steps

There is a task "T" that each player has to complete. The idea is to complete it in

minimum time
minimum steps

I could not come up with anything without keeping a limited time (1800 seconds) and limited steps(25)

enter image description here

Based on the above calculation, player 5 is the best followed by player 1.

But we can clearly see that player 4 has better figures.

How can I improve this or is there any other way of calculating.

Thanks

1

There are 1 best solutions below

5
On BEST ANSWER

You need to apply a weighting to "difference in steps" and "difference in time", such that the minimisation of each of those variables is reflected in how you want it to be 'scored'.

Let $f = f(t) = $ time taken = $t$

Let $g = g(s)$ = number of steps = $s$

Then consider a function $h(s,t) = af(t) + bg(s) = as + bt$, where $a$ and $b$ are the weighting applied to each variable. For instance, if we set $a = 10, b = 1$, then solving it $10$ seconds faster would be equivalent to solving it one step sooner.

You then compare the values of $h(s,t)_{i}$ for each player $i$, and the one with the lowest value of $h(s,t)_{i}$ wins.