Exemplo n.º 1
0
        public BMainForm()
        {
            InitializeComponent();
            PropertiesHandler.CreateDefaultDirectory();

            populateBuilds();
        }
Exemplo n.º 2
0
        public EMainForm()
        {
            InitializeComponent();
            PropertiesHandler.CreateDefaultDirectory();

            foreach (ToolStrip item in this.menuStripMain.Items)
            {
                item.Visible = false;
            }

            this.createBuildsPathLabel();
            this.populateBuilds();
        }
Exemplo n.º 3
0
    void Update()
    {
        if (existingProperties != null)                           //Checks if the data has been downloaded
        {
            PropertiesHandler.SaveProperties(existingProperties); //Saves the downloaded data
        }
        if (existingCards != null)
        {
            PropertiesHandler.SaveCards(existingCards);             //Saves the downloaded data
        }

        if (PropertiesHandler.CheckPropertyExists() && PropertiesHandler.CheckCardExists())
        {
            PlayButton.interactable = true; //Enables the play button
            enabled = false;                //Stops the update loop
        }
    }
Exemplo n.º 4
0
 void Start()
 {
     PlayButton.onClick.AddListener(OpenPlayMenu);
     Debug.Log("User ID: " + UserManager.userID);
     Debug.Log("Username: " + UserManager.username);
     if (!PropertiesHandler.CheckPropertyExists())    //Checks if the properties file doesn't exist.
     {
         StartCoroutine(GetProperties());             //Downloads the properties json.
     }
     else if (!PropertiesHandler.CheckCardExists())
     {
         StartCoroutine(GetCards());             //Downloads the cards json.
     }
     else
     {
         enabled = false;                //Stops the update function.
         PlayButton.interactable = true; //Enables the play button
     }
 }
Exemplo n.º 5
0
        private void populateOptions()
        {
            try
            {
                buildOptions = PropertiesHandler.LoadOptions();
            }
            catch (System.Xml.XmlException ex)
            {
                Dialogs.ErrorMessage(ex.Message);
                return;
            }

            optionsToControl = new Dictionary <string, UserControl>()
            {
                { "General", new GeneralControl(buildOptions) }
            };

            foreach (string option in buildOptions.options)
            {
                listViewOptions.Items.Add(option);
            }
        }