Exemple #1
0
 void Start()
 {
     panelMove   = GameObject.Find("StatusPanel").GetComponent <PanelMove>();
     statusPanel = GameObject.Find("StatusPanel").GetComponent <StatusPanel>();
     gameObject.GetComponent <Button>().onClick.AddListener(ButtonDown);
     panlFlag = false;
 }
Exemple #2
0
        public EnemyOverlay(Common common) : base(common)
        {
            PanelMove = new PanelMove(new Vector2(EmemyItemPanelMenu.PositionXItem, EmemyItemPanelMenu.PositionYItem));
            PanelMove.ValueChanged += PanelMoveChanged;

            EmemyItemPanelMenu.MoveItem.ValueChanged += OnMoveValueChanged;

            RendererManager.LoadTextureFromAssembly("Divine.BeAware.Resources.Textures.ui_manabar.png");
            RendererManager.LoadTextureFromAssembly("Divine.BeAware.Resources.Textures.item_panel.png");
        }
 void Awake()
 {
     ResetMultySelectSystems();
     nodeCamera             = GameObject.FindGameObjectWithTag("NodeCamera").GetComponent <Camera>();
     myAudio                = GetComponent <AudioSource>();
     spriteRenderer         = GetComponent <SpriteRenderer>();
     SelectBoxTr.localScale = new Vector3(0, 0, 1);
     InfoBoxText            = InfoBox.GetComponentInChildren <Text>();
     panelMove              = GameObject.Find("BottomLine").GetComponent <PanelMove>();
     InfoBox.SetActive(false);
 }
Exemple #4
0
    public int killCount = 0; //任务进度数值
    private void Start()
    {
        panelMove = GameObject.Find("Canvas/Quest").GetComponent <PanelMove>();
        //设置关闭按钮
        GameObject.Find("Canvas/Quest/ButtonCloset").GetComponent <Button>().onClick.AddListener(HideQuest);

        textDes      = GameObject.Find("Canvas/Quest/TextDes").GetComponent <Text>();
        buttonAccept = GameObject.Find("Canvas/Quest/ButtonAccept");
        buttonCancel = GameObject.Find("Canvas/Quest/ButtonCancel");
        buttonOK     = GameObject.Find("Canvas/Quest/ButtonOK");
        buttonCancel.GetComponent <Button>().onClick.AddListener(HideQuest);
        buttonAccept.GetComponent <Button>().onClick.AddListener(OnAcceptButoonDown);
        buttonOK.GetComponent <Button>().onClick.AddListener(OnOKButtonDown);
    }
        public BaseRenderer(BaseCommon common)
        {
            MenuConfig            = common.MenuConfig;
            ComboMenu             = MenuConfig.ComboMenu;
            WithMuteMenu          = MenuConfig.ComboMenu.WithMuteMenu;
            UnitComboMenu         = MenuConfig.UnitMenu.UnitComboMenu;
            UnitControlMenu       = MenuConfig.UnitMenu.UnitControlMenu;
            UnitFarmMenu          = MenuConfig.UnitMenu.UnitFarmMenu;
            SettingsMenu          = MenuConfig.SettingsMenu;
            DamageCalculationMenu = SettingsMenu.DrawingMenu.DamageCalculationMenu;
            TextPanelMenu         = common.MenuConfig.SettingsMenu.DrawingMenu.TextPanelMenu;

            TargetSelector = common.TargetSelector;

            PanelMove = new PanelMove(TextPanelMenu.Position.Value);

            if (!SettingsMenu.DisableDrawingItem)
            {
                RendererManager.TextureManager.LoadFromDivine(@"others\green_arrow.png");

                if (TextPanelMenu.ComboPanelItem)
                {
                    Size.Y += 60;
                }

                if (TextPanelMenu.UnitComboPanelItem)
                {
                    Size.Y += 90;
                }

                PanelMove.Size = Size;

                RendererManager.OnDraw += RendererOnDraw;
                Drawing.OnDraw         += OnDraw;

                TextPanelMenu.MoveItem.Changed += MoveChanged;
                PanelMove.ValueChanged         += PanelMoveChanged;

                TextPanelMenu.ComboPanelItem.Changed     += ComboPanelChanged;
                TextPanelMenu.UnitComboPanelItem.Changed += UnitComboPanelChanged;
            }

            SettingsMenu.DisableDrawingItem.Changed += DisableChanged;
        }