// シーンをロードする。 void LoadScene() { for (int i = 0; i < gameSequenceList.Count; i++) { GameSequenceData data = gameSequenceList[i]; if (data.sequence == sequence) { SceneManager.LoadScene(data.sceneName, data.loadMode); currentGameSequence = data; } } }
private void LoadCurrentSequence() { int currentSequenceId = PlayerPrefs.GetInt(CurrentSequenceToken, 1); ConfigurationData configData = (ConfigurationData)Resolver.Instance.GetController <ConfigurationManager>().GetSettingValue(ConfigurationData.ConfigurationToken); foreach (GameSequenceData sequenceData in configData.gamesequence) { if (sequenceData.id == currentSequenceId) { currentSequence = sequenceData; break; } } }
// Use this for initialization void Start() { GameSequenceData currentSequence = Resolver.Instance.GetController <GameSceneManager>().currentSequence; ConfigurationData configData = Resolver.Instance.GetController <ConfigurationManager>().GetSettingValue <ConfigurationData>(ConfigurationData.ConfigurationToken); animals = configData.animals; foreach (LevelData level in configData.levels) { if (level.id == currentSequence.typeid) { currentLevel = level; break; } } if (currentLevel == null) { Debug.Log("Unable to find level " + currentSequence.typeid); } timeBetweenTimeSteps = currentLevel.speedfactor * baseTimeBetweenTimeSteps; }