Good day. The game has a GameScore class, in which there is a certain number of nested classes that must store data for comparisons. Here is the class itself:
public class GameScore : MonoBehaviour { //first level info public class FirstLevel { internal const float HightScore = 7f; internal const float MiddleScore = 11f; internal const float LowScore = 15f; internal static int bestResult = 0; } //second level info public class SecondLevel { internal const float HightScore = 5f; internal const float MiddleScore = 7f; internal const float LowScore = 9f; internal static int bestResult = 0; } } And now the question itself: how can I get access to the FirstLevel nested class from another class, for example?
PS I'm trying to add GameScore to another public class and from there to get access to the nested class, but nothing happens.
Update (as I try to access the FirstLevel class):
public GameScore GameScorePrefab; private void CheckStars() { int bestResult = GameScorePrefab.FirstLevel.bestResult; //другой код } After that he writes: "GameScore. FirstLevel is a type, you can’t get GameScore. FirstLevel instead." And Intel class FirstLevel does not see at all.