public void InitLocationMenu(WorldMapLocationGameObject location, WorldMapManager wmm) { if (location == null) { // ToggleOff(); return; } missionInfoPanel.ToggleOff(); barPanel.ToggleOff(); ClearButtons(); pos = location.location.coords; this.wmm = wmm; missionButtons = new List <TextButton>(); text.text = location.location.AreaName; foreach (Mission mission in location.missions) { InstantiateMissionButton(mission); } foreach (LocationComponent loc in location.location.locationcomponents) { TextButton temp = Instantiate(MissionButtonPrefab, buttonContainer); missionButtons.Add(loc.GenerateButtion(temp, this)); } this.gameObject.SetActive(true); }
public void useNav() { GameData.Instance().navOn = true; WorldMapManager.Instance().ChooseStar.SetActive(true); WorldMapManager.Instance().Touch.SetActive(true); WorldMapManager.Instance().UseNav_ui.SetActive(false); }
//public void mapClean(WorldMapManager worldMan, int size, Color[] colourMap) //{ // int checkSize = checkTerrains.Length; // int xCount = 0; // int yCount = 2; // List<int[,]> dTerrains = new List<int[,]>(); // int[,] currentDTerrain = new int[3, 3]; // for (int i = 0; i < checkSize; i++) // { // foreach(int j in checkTerrains[i].terrainMap) // { // if (xCount == 3) // { // yCount--; // xCount = 0; // } // currentDTerrain[xCount, yCount] = j; // } // dTerrains.Add(currentDTerrain); // currentDTerrain = new int[3, 3]; // } // for (int y = 0; y < size; y++) // { // for (int x = 0; x < size; x++) // { // if (worldMan.worldMap.mapTiles[x, y].BiomeType == 0) // { // continue; // } // else // { // int[,] currentCheck = tileCheck(worldMan, size, x, y); // foreach(int[,] check in dTerrains) // { // if(currentCheck == check) // { // worldMan.worldMap.mapTiles[x, y].toClean = true; // } // } // } // } // } // for (int y = 0; y < size; y++) // { // for (int x = 0; x < size; x++) // { // if (worldMan.worldMap.mapTiles[x, y].toClean) // { // colourMap[y * size + x] = seaTerrains[0].colour; // worldMan.worldMap.mapTiles[x, y].BiomeType = 0; // worldMapMan.worldMap.mapTiles[x, y].Biome = seaTerrains[0].name; // worldMapMan.worldMap.mapTiles[x, y].tile = seaTerrains[0].tile; // } // } // } //} public int[,] tileCheck(WorldMapManager worldMan, int size, int tileX, int tileY) { int[,] surroundingTileTypes = new int[3, 3]; int xCount = 0; int yCount = 2; for (int i = tileY + 1; i >= tileY - 1; i--) { for (int j = tileX - 1; j <= tileX + 1; j++) { if (i < 0 || i >= size || j < 0 || j >= size) { surroundingTileTypes[xCount, yCount] = 3; } else if (worldMan.worldMap.mapTiles[i, j].BiomeType == 0) { surroundingTileTypes[xCount, yCount] = 0; } else if (worldMan.worldMap.mapTiles[i, j].BiomeType == 1 || worldMan.worldMap.mapTiles[i, j].BiomeType == 2) { surroundingTileTypes[xCount, yCount] = 1; } xCount++; } xCount = 0; yCount--; } return(surroundingTileTypes); }
void Start() { if (_instance == null) { _instance = this; } if (GameObject.Find("WorldMapFlag") == null) { GameObject.Find("ReturnButton").gameObject.GetComponent <Button>().onClick.AddListener(() => gameObject.GetComponent <ButtonController>().TransSceneToMain()); } else { UseNav_ui.SetActive(false); Touch.SetActive(true); Touch.transform.FindChild("Choose").gameObject.SetActive(false); Notice.SetActive(true); Notice.GetComponentInChildren <Text>().CrossFadeAlpha(-1, 8.0f, false); //버튼 함수의 동적 할당 //onClick.AddListener(() => gameObject.GetComponent<ButtonController>().TransSceneToManage(파라미터)); 파라미터 사용시 //onClick.AddListener(gameObject.GetComponent<ButtonController>().TransSceneToManage); 파라미터 미사용시 GameObject.Find("ReturnButton").gameObject.GetComponent <Button>().onClick.AddListener(() => gameObject.GetComponent <ButtonController>().TransSceneToManage()); } loadStar(); }
public override void StartServerSide(ICoreServerAPI api) { if (GraveModConfig.Current.ShouldCreateDeathWaypoint) { api.Event.PlayerDeath += OnPlayerDeath; _mapManager = api.ModLoader.GetModSystem <WorldMapManager>(); } }
/// <summary> /// Trick the server into sending waypoints to the client even if they don't have their map opened. /// Credit to Novocain. /// </summary> /// <param name="mapManager">The map manager.</param> public static void ForceSendWaypoints(this WorldMapManager mapManager) { var capi = mapManager.GetField <ICoreClientAPI>("capi"); capi.Event.EnqueueMainThreadTask(() => capi.Event.RegisterCallback(dt => mapManager.GetField <IClientNetworkChannel>("clientChannel") .SendPacket(new OnViewChangedPacket()), 500), ""); }
public void SaveFromWindow() { WorldMapManager manager = GameObject.Find("WorldMapManager").GetComponent <WorldMapManager>(); if (manager != null) { manager.SaveAnyway(); } }
public void OnBeginDrag(PointerEventData eventData) { if (WorldMapManager.Instance().dragState == false) { WorldMapManager.Instance().dragState = true; } oldPos = new Vector2(eventData.position.x, eventData.position.y); //Debug.Log("OnBeginDrag"); }
// Use this for initialization void Awake() { if (instance == null) instance = this; else if (instance != this) Destroy(gameObject); DontDestroyOnLoad(gameObject); worldMapScript = GetComponent<WorldMapManager>(); canvas = GameObject.Find("Canvas"); }
public static void AddWaypointToPlayer(this WorldMapManager mapManager, Waypoint waypoint, IServerPlayer player) { var mapLayer = mapManager.GetWaypointMapLayer(); if (mapLayer != null) { mapLayer.Waypoints.Add(waypoint); ResendWaypoints(mapManager, player, mapLayer); } }
private void Awake() { //gameTileClickHandler.OnGameTileClickedEvent += OnGameTileClickedEvent; inputManager = GetComponent <MapSceneInputManager>(); worldMapManager = GetComponent <WorldMapManager>(); interactableManager = GetComponent <MapInteractableManager>(); cameraController = GetComponent <MapSceneCameraController>(); mapResourcesManager = GetComponent <MapResourceManager>(); animalManager = GetComponent <MapAnimalManager>(); }
public void captialPos(WorldMapManager worldMan, int size, int NumNations, Tilemap townMap, Tile town) { townLocs = new Vector2Int[NumNations]; worldMan.TownNumber = 0; Vector2Int bestTile = new Vector2Int(); float bestLife = 0; for (int i = 0; i < NumNations; i++) { for (int y = 0; y < size; y++) { for (int x = 0; x < size; x++) { bool tooClose = false; if (worldMan.worldMap.mapTiles[x, y].BiomeType == 0 || worldMan.worldMap.mapTiles[x, y].BiomeType == 1 || worldMan.worldMap.mapTiles[x, y].town) { continue; } Vector2Int currentTile = new Vector2Int(x, y); for (int j = 0; j < NumNations; j++) { float distance = Vector2Int.Distance(townLocs[j], currentTile); if (distance < 30) { tooClose = true; } } if (tooClose) { continue; } float LocalLife = worldMan.worldMap.mapTiles[x, y].lifeScore; if (LocalLife >= bestLife) { bestTile.x = x; bestTile.y = y; bestLife = LocalLife; } } } townLocs[i] = bestTile; Vector3Int townPos = new Vector3Int(bestTile.x, bestTile.y, 0); townMap.SetTile(townPos, town); worldMan.addTown(i + 1, true, 0, bestTile.x, bestTile.y); //worldMan.CreateTown(bestTile.x, bestTile.y, i.ToString(), 2, true); bestLife = 0; } }
public static void ResendWaypoints(this WorldMapManager mapManager, IServerPlayer player, WaypointMapLayer mapLayer) { //copied from WaypointMapLayer because the method is not public Dictionary <int, PlayerGroupMembership> memberOfGroups = player.ServerData.PlayerGroupMemberships; List <Waypoint> hisMarkers = new List <Waypoint>(); foreach (Waypoint marker in mapLayer.Waypoints) { if (player.PlayerUID != marker.OwningPlayerUid && !memberOfGroups.ContainsKey(marker.OwningPlayerGroupId)) { continue; } hisMarkers.Add(marker); } mapManager.SendMapDataToClient(mapLayer, player, SerializerUtil.Serialize(hisMarkers)); }
public void OnDrag(PointerEventData eventData) { if (WorldMapManager.Instance().dragState == false) { WorldMapManager.Instance().dragState = true; } if (Input.touchCount == 1) //Build Mode { //Debug.Log("OnDrag"); newPos = new Vector2(eventData.position.x, eventData.position.y); //Debug.Log(eventData.delta); GameObject obj = GameObject.Find("DragCamera"); obj.transform.Rotate(new Vector3(eventData.delta.y / dragRate, -eventData.delta.x / dragRate, 0)); //obj.transform.localRotation = }//Build Mode }
private void StartCommand(IServerPlayer player, int groupId, CmdArgs args) { _mapManager = SAPI.ModLoader.GetModSystem <WorldMapManager>(); var map = _mapManager.MapLayers.OfType <WaypointMapLayer>().FirstOrDefault(); int index; if (int.TryParse(args.PeekWord(), out index)) { if (index < map.Waypoints.Count) { player.Entity.TeleportTo(map.Waypoints[index].Position); } } else if (args.PeekWord() == "list") { string outstr = ""; for (int i = 0; i < map.Waypoints.Count; i++) { var way = map.Waypoints[i]; outstr += i + ": " + way.Title + "\r\n"; } player.SendMessage(groupId, outstr, EnumChatType.Notification); } else { string namelable = args.PopAll(); foreach (var way in map.Waypoints) { if (way.Title == namelable) { player.Entity.TeleportTo(way.Position); return; } } } }
public void Initialize(WorldMapManager worldMapManager) { this.worldMapManager = worldMapManager; }
// Use this for initialization void Start() { manager = GameObject.Find("WorldMap").GetComponent<WorldMapManager>(); }
// called when a list item clicked public void LoadSession(Text worldMapText) { WorldMapManager manager = GameObject.Find("WorldMapManager").GetComponent <WorldMapManager>(); manager.Load(worldMapText.text); }
public WorldMapInputState(WorldMapManager manager, WorldMapUIManager ui) { this.manager = manager; this.ui = ui; }
public Wpex(ICoreClientAPI api) : base(api) { _mapManager = Api.ModLoader.GetModSystem <WorldMapManager>(); Mod = api.ModLoader.GetModSystem <WpexModSystem>(); WpexPatches.Api = api; }
public NavigateWorldInputState(WorldMapManager manager, WorldMapUIManager ui) { this.manager = manager; uiManager = ui; }
public void Setup(string saveName, WorldMapManager worldManager) { fieldName.text = saveName; worldMan = worldManager; }
// 월드맵 public void ReChoose() { WorldMapManager.Instance().ChooseStar.SetActive(true); WorldMapManager.Instance().Touch.SetActive(true); WorldMapManager.Instance().Destination_ui.SetActive(false); }
void Update() { if (WorldMapManager.Instance().dragState == false) { //if (Input.GetButtonUp("Fire1")) // Debug Mode //{ // Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition); // Debug Mode // RaycastHit hit; // Debug Mode foreach (Touch touch in Input.touches) // Build Mode { Ray ray = Camera.main.ScreenPointToRay(touch.position); // Build Mode RaycastHit hit; // Build Mode if (Physics.Raycast(ray, out hit)) { if (WorldMapManager.Instance().dragState == false) { if (hit.transform.tag.Equals("Stars")) { SoundManager.Instance().PlaySfx(SoundManager.Instance().getFood); SelectDB.Instance().column = "locationX,locationY,locationZ,name,zodiac"; SelectDB.Instance().table = "zodiacTable"; SelectDB.Instance().where = "WHERE zID= " + "'" + hit.transform.name + "'"; SelectDB.Instance().Select(1); GameData.Instance().starPosition = SelectDB.Instance().starPosition; WorldMapManager.Instance().ChooseStar.SetActive(false); WorldMapManager.Instance().Touch.SetActive(false); WorldMapManager.Instance().Destination_ui.SetActive(true); if (SelectDB.Instance().zodiacName == "Aquarius") { zodiac = "물병자리"; } else if (SelectDB.Instance().zodiacName == "Pisces") { zodiac = "물고기자리"; } else if (SelectDB.Instance().zodiacName == "Aries") { zodiac = "양자리"; } else if (SelectDB.Instance().zodiacName == "Taurus") { zodiac = "황소자리"; } else if (SelectDB.Instance().zodiacName == "Gemini") { zodiac = "쌍둥이자리"; } else if (SelectDB.Instance().zodiacName == "Cancer") { zodiac = "게자리"; } else if (SelectDB.Instance().zodiacName == "Leo") { zodiac = "사자자리"; } else if (SelectDB.Instance().zodiacName == "Virgo") { zodiac = "처녀자리"; } else if (SelectDB.Instance().zodiacName == "Libra") { zodiac = "천칭자리"; } else if (SelectDB.Instance().zodiacName == "Scorpius") { zodiac = "전갈자리"; } else if (SelectDB.Instance().zodiacName == "Sagittarius") { zodiac = "궁수자리"; } else if (SelectDB.Instance().zodiacName == "Capricornus") { zodiac = "염소자리"; } WorldMapManager.Instance().Destination_ui.GetComponentInChildren <Text>().text = zodiac + " " + SelectDB.Instance().starName; } //else //{ // WorldMapManager.Instance().Touch.SetActive(false); // WorldMapManager.Instance().Destination_ui.SetActive(true); // WorldMapManager.Instance().Destination_ui.GetComponentInChildren<Text>().text = hit.transform.name; //} } } } // Build Mode //} // Debug Mode } WorldMapManager.Instance().dragState = false; }
/// <summary> /// Returns the map layer used for rendering waypoints. /// </summary> /// <param name="mapManager">The <see cref="WorldMapManager" /> instance that this method was called from.</param> public static WaypointMapLayer WaypointMapLayer(this WorldMapManager mapManager) { return(mapManager.MapLayers.OfType <WaypointMapLayer>().FirstOrDefault()); }
public override void UpdateUI() { //IL_0089: Unknown result type (might be due to invalid IL or missing references) //IL_0145: Unknown result type (might be due to invalid IL or missing references) //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_01df: Unknown result type (might be due to invalid IL or missing references) //IL_01e4: Expected O, but got Unknown //IL_05e2: Unknown result type (might be due to invalid IL or missing references) //IL_05ff: Unknown result type (might be due to invalid IL or missing references) //IL_07e0: Unknown result type (might be due to invalid IL or missing references) //IL_07ed: Unknown result type (might be due to invalid IL or missing references) OpenTutorial(); UpdateTitle(); SetSprite(baseRoot, UI.SPR_WINDOW, SPR_WINDOW_TYPE[info.DeliveryTypeIndex()]); SetSprite(baseRoot, UI.SPR_MESSAGE_BG, SPR_MESSAGE_BG_TYPE[info.DeliveryTypeIndex()]); bool flag = false; if (Object.op_Implicit(submissionFrame)) { UpdateSubMissionButton(); UpdateSubMission(); flag = submissionFrame.get_gameObject().get_activeSelf(); SetActive((Enum)UI.STR_BTN_SUBMISSION, !flag); SetActive((Enum)UI.STR_BTN_SUBMISSION_BACK, flag); } Transform root = targetFrame; MonoBehaviourSingleton <DeliveryManager> .I.GetTargetEnemyData(deliveryID, out targetQuestID, out targetMapID, out string map_name, out string enemy_name, out DIFFICULTY_TYPE?difficulty, out targetPortalID); SetLabelText(root, UI.LBL_PLACE_NAME, map_name); MonoBehaviourSingleton <DeliveryManager> .I.GetAllProgressDelivery(deliveryID, out int have, out int need); SetLabelText(root, UI.LBL_HAVE, (!isComplete) ? have.ToString() : need.ToString()); SetColor(root, UI.LBL_HAVE, (!isComplete) ? Color.get_red() : Color.get_white()); SetLabelText(root, UI.LBL_NEED, need.ToString()); SetLabelText(root, UI.LBL_NEED_ITEM_NAME, MonoBehaviourSingleton <DeliveryManager> .I.GetTargetItemName(deliveryID, 0u)); if (info.IsDefeatCondition(0u)) { if (targetQuestID != 0) { isQuestEnemy = true; Transform val = FindCtrl(root, UI.OBJ_DIFFICULTY_ROOT); int value = (int)difficulty.Value; int j = 0; for (int childCount = val.get_childCount(); j < childCount; j++) { Transform t2 = val.GetChild(j); SetActive(t2, j <= value); } SetLabelText(root, UI.LBL_GET_PLACE, base.sectionData.GetText("GET_QUEST")); } else { isQuestEnemy = false; SetLabelText(root, UI.LBL_GET_PLACE, base.sectionData.GetText("GET_AREA")); } SetLabelText(root, UI.LBL_ENEMY_NAME, string.Format(StringTable.Get(STRING_CATEGORY.TEXT_SCRIPT, 3u), enemy_name)); } else { isQuestEnemy = false; SetLabelText(root, UI.LBL_GET_PLACE, StringTable.Get(STRING_CATEGORY.DELIVERY_CONDITION_PLACE, (uint)info.GetConditionType(0u))); SetLabelText(root, UI.LBL_ENEMY_NAME, enemy_name); } SetActive(root, UI.OBJ_DIFFICULTY_ROOT, isQuestEnemy); SetActive(root, UI.OBJ_ENEMY_NAME_ROOT, !isQuestEnemy); UpdateNPC(map_name, enemy_name); if ((isComplete || isNotice) && !isCompletedEventDelivery) { SetActive((Enum)UI.OBJ_BACK, false); SetActive((Enum)UI.BTN_CREATE, false); SetActive((Enum)UI.BTN_JOIN, false); SetActive((Enum)UI.BTN_MATCHING, false); UpdateUIJumpButton(JumpButtonType.Complete); } else { SetActive((Enum)UI.OBJ_BACK, true); bool flag2 = true; bool flag3 = false; if (info == null || info.IsDefeatCondition(0u) || targetMapID != 0) { if (isQuestEnemy) { if (isInGameScene) { flag2 = false; } } else { bool flag4 = FieldManager.HasWorldMap(targetMapID); if (isInGameScene) { if (MonoBehaviourSingleton <FieldManager> .I.currentMapID == targetMapID) { if (flag4) { flag3 = true; } else { flag2 = false; } } else if (flag4) { if (!MonoBehaviourSingleton <FieldManager> .I.CanJumpToMap(targetMapID) || WorldMapManager.IsValidPortalIDs(targetPortalID)) { flag3 = true; } } else if (!MonoBehaviourSingleton <FieldManager> .I.CanJumpToMap(targetMapID)) { flag2 = false; } } else if (flag4) { if (!MonoBehaviourSingleton <FieldManager> .I.CanJumpToMap(targetMapID) || WorldMapManager.IsValidPortalIDs(targetPortalID)) { flag3 = true; } } else if (!MonoBehaviourSingleton <FieldManager> .I.CanJumpToMap(targetMapID)) { flag2 = false; } } } else { flag2 = (info.GetDeliveryJumpType() != DeliveryTable.DELIVERY_JUMPTYPE.UNDEFINED); } JumpButtonType jumpButtonType = JumpButtonType.Invalid; if (flag2) { if (info != null && info.GetDeliveryJumpType() != 0) { jumpButtonType = ConvertDeliveryJumpType(); } else { if (info != null) { QuestTable.QuestTableData questData = info.GetQuestData(); if (questData != null && questData.questType == QUEST_TYPE.WAVE) { jumpButtonType = JumpButtonType.WaveRoom; } } if (jumpButtonType != JumpButtonType.WaveRoom) { jumpButtonType = ((!flag3) ? JumpButtonType.Quest : JumpButtonType.Map); } } UpdateUIJumpButton(jumpButtonType); } else { SetActive(baseRoot, UI.BTN_JUMP_QUEST, false); SetActive(baseRoot, UI.BTN_JUMP_MAP, false); SetActive(baseRoot, UI.BTN_JUMP_GACHATOP, false); SetActive(baseRoot, UI.BTN_JUMP_INVALID, false); SetActive(baseRoot, UI.BTN_WAVEMATCH_NEW, false); SetActive(baseRoot, UI.BTN_WAVEMATCH_PASS, false); SetActive(baseRoot, UI.BTN_WAVEMATCH_AUTO, false); SetActive(baseRoot, UI.BTN_COMPLETE, false); } if (flag3 && MonoBehaviourSingleton <FieldManager> .I.currentMapID != targetMapID) { SetColor(baseRoot, UI.LBL_PLACE_NAME, Color.get_red()); } else { SetColor(baseRoot, UI.LBL_PLACE_NAME, Color.get_white()); } } int money = 0; int exp = 0; if (rewardData != null) { SetGrid(baseRoot, UI.GRD_REWARD, string.Empty, rewardData.Length, false, delegate(int i, Transform t, bool is_recycle) { DeliveryRewardTable.DeliveryRewardData.Reward reward = rewardData[i].reward; bool is_visible = false; if (reward.type == REWARD_TYPE.MONEY) { money += reward.num; } else if (reward.type == REWARD_TYPE.EXP) { exp += reward.num; } else { is_visible = true; ItemIcon itemIcon = ItemIcon.CreateRewardItemIcon(reward.type, reward.item_id, t, reward.num, string.Empty, 0, false, -1, false, null, false, false, ItemIcon.QUEST_ICON_SIZE_TYPE.REWARD_DELIVERY_DETAIL); SetMaterialInfo(itemIcon.transform, reward.type, reward.item_id, null); itemIcon.SetRewardBG(true); } SetActive(t, is_visible); }); } SetLabelText(baseRoot, UI.LBL_MONEY, money.ToString()); SetLabelText(baseRoot, UI.LBL_EXP, exp.ToString()); SetActive(baseRoot, UI.OBJ_COMPLETE_ROOT, isComplete && !flag); SetActive(baseRoot, UI.OBJ_UNLOCK_PORTAL_ROOT, isComplete); if (isComplete) { string text = string.Empty; List <FieldMapTable.PortalTableData> deliveryRelationPortalData = Singleton <FieldMapTable> .I.GetDeliveryRelationPortalData(info.id); switch (deliveryRelationPortalData.Count) { case 1: { FieldMapTable.FieldMapTableData fieldMapData = Singleton <FieldMapTable> .I.GetFieldMapData(deliveryRelationPortalData[0].srcMapID); if (fieldMapData != null) { text = fieldMapData.mapName; } break; } default: text = base.sectionData.GetText("MULTI_UNLOCK"); break; case 0: break; } bool flag5 = !string.IsNullOrEmpty(text); if (!TutorialStep.HasFirstDeliveryCompleted()) { flag5 = false; } SetActive(baseRoot, UI.OBJ_UNLOCK_PORTAL_ROOT, flag5 && !isCompletedEventDelivery); SetLabelText(baseRoot, UI.LBL_UNLOCK_PORTAL, text); if (isCompletedEventDelivery) { SkipTween(baseRoot, UI.OBJ_COMPLETE_ROOT, true, 0); } else { this.StartCoroutine(StartTweenCoroutine(flag5)); } } this.StartCoroutine(SetPointShopGetPointUI()); }
public WorldMapMainMenuInputState(WorldMapManager manager, WorldMapUIManager ui, WorldMapMenu menu) : base(manager, ui) { this.menu = menu; }
public WorldLocationInputState(WorldMapManager manager, WorldMapUIManager ui) : base(manager, ui) { }
public static WaypointMapLayer GetWaypointMapLayer(this WorldMapManager mapManager) => mapManager.MapLayers.OfType <WaypointMapLayer>().FirstOrDefault();
public void Initialize(WorldMapManager worldMapManager, Story.SceneManager sceneManager) { this.worldMapManager = worldMapManager; this.sceneManager = sceneManager; }
public void InitSelector(WorldMapManager managet) { worldMapManager = managet; this.currentMap = managet.currWorldMap; }
void loadStar() { SelectDB.Instance().table = "zodiacTable"; SelectDB.Instance().column = "Count(*)"; SelectDB.Instance().Select(0); for (int i = 1; i <= SelectDB.Instance().starCount; i++) { SelectDB.Instance().table = "zodiacTable"; SelectDB.Instance().column = "rowid, open, find, active, zID, zodiac"; SelectDB.Instance().where = "WHERE \"rowid\" =" + i; SelectDB.Instance().Select(4); if (SelectDB.Instance().starActive == 0) { GameObject.Find(SelectDB.Instance().zodiacID).gameObject.GetComponent <SphereCollider>().enabled = true; GameObject.Find(SelectDB.Instance().zodiacID).gameObject.GetComponent <SphereCollider>().isTrigger = true; } else if (SelectDB.Instance().starActive == 1) { Debug.Log(SelectDB.Instance().zodiacName); if (SelectDB.Instance().zodiacName == "Aquarius") { WorldMapManager.Instance().zodiacCnt1 += 1; } else if (SelectDB.Instance().zodiacName == "Pisces") { WorldMapManager.Instance().zodiacCnt2++; } else if (SelectDB.Instance().zodiacName == "Aries") { WorldMapManager.Instance().zodiacCnt3++; } else if (SelectDB.Instance().zodiacName == "Taurus") { WorldMapManager.Instance().zodiacCnt4++; } else if (SelectDB.Instance().zodiacName == "Gemini") { WorldMapManager.Instance().zodiacCnt5++; } else if (SelectDB.Instance().zodiacName == "Cancer") { WorldMapManager.Instance().zodiacCnt6++; } else if (SelectDB.Instance().zodiacName == "Leo") { WorldMapManager.Instance().zodiacCnt7++; } else if (SelectDB.Instance().zodiacName == "Virgo") { WorldMapManager.Instance().zodiacCnt8++; } else if (SelectDB.Instance().zodiacName == "Libra") { WorldMapManager.Instance().zodiacCnt9++; } else if (SelectDB.Instance().zodiacName == "Scorpius") { WorldMapManager.Instance().zodiacCnt10++; } else if (SelectDB.Instance().zodiacName == "Sagittarius") { WorldMapManager.Instance().zodiacCnt11++; } else if (SelectDB.Instance().zodiacName == "Capricornus") { WorldMapManager.Instance().zodiacCnt12++; } GameObject.Find(SelectDB.Instance().zodiacID).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find(SelectDB.Instance().zodiacID).gameObject.GetComponent <MeshRenderer>().enabled = false; } if (zodiacCnt1 == 6 && cnt1 == false) { for (int cnt = 7; cnt < 17; cnt++) { Debug.Log(GameObject.Find("Aquarius").transform.FindChild("aqua_" + cnt).name); GameObject.Find("Aquarius").transform.FindChild("aqua_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Aquarius").transform.FindChild("aqua_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt1 = true; } if (zodiacCnt2 == 5 && cnt2 == false) { for (int cnt = 6; cnt < 22; cnt++) { GameObject.Find("Pisces").transform.FindChild("pis_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Pisces").transform.FindChild("pis_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt2 = true; } //if (zodiacCnt3 == 4 && cnt3 == false) //{ // //작은별없음 Aries // cnt3 == true; //} if (zodiacCnt4 == 6 && cnt4 == false) { for (int cnt = 7; cnt < 20; cnt++) { GameObject.Find("Taurus").transform.FindChild("tau_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Taurus").transform.FindChild("tau_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt4 = true; } if (zodiacCnt5 == 5 && cnt5 == false) { for (int cnt = 6; cnt < 18; cnt++) { GameObject.Find("Gemini").transform.FindChild("gem_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Gemini").transform.FindChild("gem_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt5 = true; } if (zodiacCnt6 == 5 && cnt6 == false) { for (int cnt = 6; cnt < 8; cnt++) { GameObject.Find("Cancer").transform.FindChild("can_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Cancer").transform.FindChild("can_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt6 = true; } if (zodiacCnt7 == 4 && cnt7 == false) { for (int cnt = 5; cnt < 17; cnt++) { GameObject.Find("Leo").transform.FindChild("leo_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Leo").transform.FindChild("leo_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt7 = true; } if (zodiacCnt8 == 5 && cnt8 == false) { for (int cnt = 6; cnt < 16; cnt++) { GameObject.Find("Virgo").transform.FindChild("vir_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Virgo").transform.FindChild("vir_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt8 = true; } if (zodiacCnt9 == 5 && cnt9 == false) { for (int cnt = 6; cnt < 7; cnt++) { GameObject.Find("Libra").transform.FindChild("lib_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Libra").transform.FindChild("lib_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt9 = true; } if (zodiacCnt10 == 6 && cnt10 == false) { for (int cnt = 7; cnt < 13; cnt++) { GameObject.Find("Scorpius").transform.FindChild("sco_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Scorpius").transform.FindChild("sco_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt10 = true; } if (zodiacCnt11 == 6 && cnt11 == false) { for (int cnt = 7; cnt < 22; cnt++) { GameObject.Find("Sagittarius").transform.FindChild("sag_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Sagittarius").transform.FindChild("sag_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt11 = true; } if (zodiacCnt12 == 6 && cnt12 == false) { for (int cnt = 7; cnt < 13; cnt++) { GameObject.Find("Capricornus").transform.FindChild("cap_" + cnt).gameObject.GetComponent <SphereCollider>().enabled = false; GameObject.Find("Capricornus").transform.FindChild("cap_" + cnt).gameObject.GetComponent <MeshRenderer>().enabled = false; } cnt12 = true; } } }