void Awake() { moveObjectTask = gameObject.AddComponent <MoveObjectTask>(); stageCreateTask = gameObject.AddComponent <StageCreateTask>(); uiTask = gameObject.AddComponent <GameUiTask>(); mapObjects = new List <MapObject>(); stageCreateTask.MapDataCreate(GetPath.Txt + "/" + stageName, mapObjects, ref stageData); Special = new SpecialObject(); textEvent = false; eventCount = 0; controllerTask = GetComponent <ControllerTask>(); drawFloorTask = GetComponent <DrawingFloorTask>(); }
private bool okFlag; //これがないと決定と選択の1回で処理を行ってしまう private void Start() { basePos = new Vector2(150f, -100f); gameTask = Utility.GetGameTask(); uiTask = Utility.GetTaskObject().GetComponent <GameUiTask>(); Sprite sprite = Resources.Load <Sprite>(GetPath.Image + "/choice"); choiceMark = uiTask.NewImageUi(sprite, Vector2.zero, Vector2.one * 50f).gameObject; choiceMark.transform.eulerAngles = Vector3.forward * 90f; choiceMark.SetActive(false); objectChoice = GameObject.FindGameObjectWithTag("Player").GetComponent <ObjectChoice>(); }