Converts an object definition id into a number which can be used as index for
SetScoreboardData. This function is of interest if an object script intends to access the scoreboard but wants to be sure that it is not using the same column indices as another object definition.