Esempio n. 1
0
 private void llenarGrid()
 {
     dataGridView1.Rows.Clear();
     foreach (stdClassCSharp game in games.toArray())
     {
         dataGridView1.Rows.Add(game["Titulo"], dataGridView1.Rows.Count);
     }
 }
Esempio n. 2
0
        public async Task sJustein([Remainder] string inputMessage = "NONE")
        {
            if (!Context.IsPrivate)
            {
                string         mensaje     = inputMessage;
                int            links       = 0;
                string         jdwonloader = "";
                stdClassCSharp dlcs        = new stdClassCSharp(true);
                EmbedBuilder   builderDlc;
                EmbedBuilder   builderJDownloader;

                if (mensaje.Trim().Length > 3)
                {
                    if (Utils.searchDlc(mensaje, ref dlcs))
                    {
                        foreach (stdClassCSharp dlc in dlcs.toArray())
                        {
                            builderDlc         = new EmbedBuilder();
                            builderJDownloader = new EmbedBuilder();
                            jdwonloader        = "";
                            links = 0;
                            if (Utils.generaBuilderDlc(dlc, ref builderDlc, ref jdwonloader, ref links))
                            {
                                if (links > 1)
                                {
                                    builderJDownloader.WithTitle(builderDlc.Title);
                                    builderJDownloader.WithColor(0xFFFFFF);
                                    builderJDownloader.WithDescription(jdwonloader);
                                }
                                await Context.User.SendMessageAsync("", false, builderDlc.Build());

                                if (links > 1)
                                {
                                    await Context.User.SendMessageAsync("", false, builderJDownloader.Build());
                                }
                            }
                        }
                        if (dlcs.Count == 1)
                        {
                            await Context.Channel.SendMessageAsync($"{Context.Message.Author.Mention} he encontrado {dlcs.Count} resultado y te lo he enviado por mp :)");
                        }
                        else
                        {
                            await Context.Channel.SendMessageAsync($"{Context.Message.Author.Mention} he encontrado {dlcs.Count} resultados y te los he enviado por mp :)");
                        }
                    }
                    else
                    {
                        await Context.Channel.SendMessageAsync($"{Context.Message.Author.Mention} no encontre el dlc que me pediste :(, pideselo a bello XD");
                    }
                }
                else
                {
                    await Context.Channel.SendMessageAsync($"{Context.Message.Author.Mention} Debes escribir mas de 3 letras de el/los dlc(s) que buscas.");
                }
            }
        }
Esempio n. 3
0
        private void ObtenerIdiomas()
        {
            string lenguages = DownloadStringServer("https://raw.githubusercontent.com/Urferu/Lan-Play-Server-Manager/english_branch/Lenguages/LengugesDisp.json");

            idiomas = stdClassCSharp.jsonToStdClass(lenguages);
            int indice       = 0;
            int indiceIdioma = 0;

            foreach (stdClassCSharp idioma in idiomas.toArray())
            {
                comboBox1.Items.Add(idioma["language_name"]);
                if (CultureInfo.CurrentCulture.Name.Split('-')[0].ToUpper().Equals(idioma["abbreviation"]))
                {
                    indiceIdioma = indice;
                }
                indice++;
            }
            comboBox1.SelectedIndex = indiceIdioma;
        }
Esempio n. 4
0
        private void CambiaIdiomaSeleccionado()
        {
            string selectedLenguage = "";

            foreach (stdClassCSharp lenguage in idiomas.toArray())
            {
                if (lenguage["language_name"].Contains(comboBox1.Items[comboBox1.SelectedIndex].ToString()))
                {
                    selectedLenguage = lenguage["abbreviation"];
                }
            }
            string lenguageData = DownloadStringServer("https://raw.githubusercontent.com/Urferu/Lan-Play-Server-Manager/master/Lenguages/" + selectedLenguage + ".json");

            if (!string.IsNullOrWhiteSpace(lenguageData))
            {
                stdClassCSharp datosDelIdioma = stdClassCSharp.jsonToStdClass(lenguageData);
                LenguagesManager.StringsPrincipalLenguages.ButtonConnect       = datosDelIdioma["StringsPrincipalLenguages"]["ButtonConnect"];
                LenguagesManager.StringsPrincipalLenguages.ToolTipConnect      = datosDelIdioma["StringsPrincipalLenguages"]["ToolTipConnect"];
                LenguagesManager.StringsPrincipalLenguages.ButtonDisconnect    = datosDelIdioma["StringsPrincipalLenguages"]["ButtonDisconnect"];
                LenguagesManager.StringsPrincipalLenguages.Servers             = datosDelIdioma["StringsPrincipalLenguages"]["Servers"];
                LenguagesManager.StringsPrincipalLenguages.ServersLoading      = datosDelIdioma["StringsPrincipalLenguages"]["ServersLoading"];
                LenguagesManager.StringsPrincipalLenguages.ButtonReload        = datosDelIdioma["StringsPrincipalLenguages"]["ButtonReload"];
                LenguagesManager.StringsPrincipalLenguages.ToolTipReload       = datosDelIdioma["StringsPrincipalLenguages"]["ToolTipReload"];
                LenguagesManager.StringsPrincipalLenguages.ToolTipMTU          = datosDelIdioma["StringsPrincipalLenguages"]["ToolTipMTU"];
                LenguagesManager.StringsPrincipalLenguages.ToolTipMTUValue     = datosDelIdioma["StringsPrincipalLenguages"]["ToolTipMTUValue"];
                LenguagesManager.StringsPrincipalLenguages.ShowConsole         = datosDelIdioma["StringsPrincipalLenguages"]["ShowConsole"];
                LenguagesManager.StringsPrincipalLenguages.ShowConsoleToolTip  = datosDelIdioma["StringsPrincipalLenguages"]["ShowConsoleToolTip"];
                LenguagesManager.StringsPrincipalLenguages.Credits             = datosDelIdioma["StringsPrincipalLenguages"]["Credits"];
                LenguagesManager.StringsPrincipalLenguages.LanPlayConsoleLabel = datosDelIdioma["StringsPrincipalLenguages"]["LanPlayConsoleLabel"];

                LenguagesManager.StringsCreditsLenguages.DesignedBy  = datosDelIdioma["StringsCreditsLenguages"]["DesignedBy"];
                LenguagesManager.StringsCreditsLenguages.DevelopedBy = datosDelIdioma["StringsCreditsLenguages"]["DevelopedBy"];
                LenguagesManager.StringsCreditsLenguages.ListServers = datosDelIdioma["StringsCreditsLenguages"]["ListServers"];
                LenguagesManager.StringsCreditsLenguages.SupportedBy = datosDelIdioma["StringsCreditsLenguages"]["SupportedBy"];
                LenguagesManager.StringsCreditsLenguages.FollowOn    = datosDelIdioma["StringsCreditsLenguages"]["FollowOn"];

                if (Convert.ToInt32(materialRaisedButton1.Tag).Equals(0))
                {
                    materialRaisedButton1.Text = LenguagesManager.StringsPrincipalLenguages.ButtonConnect;
                }
                else
                {
                    materialRaisedButton1.Text = LenguagesManager.StringsPrincipalLenguages.ButtonDisconnect;
                }
                toolTip1.SetToolTip(this.materialRaisedButton1, LenguagesManager.StringsPrincipalLenguages.ToolTipConnect);

                if (labelServers.Text.Contains("..."))
                {
                    labelServers.Text = LenguagesManager.StringsPrincipalLenguages.ServersLoading;
                }
                else
                {
                    labelServers.Text = LenguagesManager.StringsPrincipalLenguages.Servers;
                }

                materialRaisedButton2.Text = LenguagesManager.StringsPrincipalLenguages.ButtonReload;
                toolTip1.SetToolTip(this.materialRaisedButton2, LenguagesManager.StringsPrincipalLenguages.ToolTipReload);
                toolTip1.SetToolTip(linkLabel2, LenguagesManager.StringsPrincipalLenguages.ToolTipMTU);
                toolTip1.SetToolTip(txtPmtu, LenguagesManager.StringsPrincipalLenguages.ToolTipMTUValue);
                ckConsola.Text = LenguagesManager.StringsPrincipalLenguages.ShowConsole;
                toolTip1.SetToolTip(ckConsola, LenguagesManager.StringsPrincipalLenguages.ShowConsoleToolTip);
                labelDatos.Text = LenguagesManager.StringsPrincipalLenguages.LanPlayConsoleLabel;
            }
        }
        private void CambiaIdiomaSeleccionado()
        {
            string selectedLenguage = "";

            foreach (stdClassCSharp lenguage in idiomas.toArray())
            {
                if (lenguage["language_name"].Contains(comboBox1.Items[comboBox1.SelectedIndex].ToString()))
                {
                    selectedLenguage = lenguage["abbreviation"];
                }
            }
            string lenguageData = DownloadStringServer("https://raw.githubusercontent.com/Urferu/Lan-Play-Server-Manager/master/Lenguages/" + selectedLenguage + ".json");

            if (!string.IsNullOrWhiteSpace(lenguageData))
            {
                stdClassCSharp datosDelIdioma = stdClassCSharp.jsonToStdClass(lenguageData);
                LenguagesManager.StringsPrincipalLenguages.ButtonConnect    = datosDelIdioma["StringsPrincipalLenguages"]["ButtonConnect"];
                LenguagesManager.StringsPrincipalLenguages.ButtonDisconnect = datosDelIdioma["StringsPrincipalLenguages"]["ButtonDisconnect"];
                LenguagesManager.StringsPrincipalLenguages.Servers          = datosDelIdioma["StringsPrincipalLenguages"]["Servers"];
                LenguagesManager.StringsPrincipalLenguages.ServersLoading   = datosDelIdioma["StringsPrincipalLenguages"]["ServersLoading"];

                LenguagesManager.StringsCreditsLenguages.DesignedBy  = datosDelIdioma["StringsCreditsLenguages"]["DesignedBy"];
                LenguagesManager.StringsCreditsLenguages.DevelopedBy = datosDelIdioma["StringsCreditsLenguages"]["DevelopedBy"];
                LenguagesManager.StringsCreditsLenguages.ListServers = datosDelIdioma["StringsCreditsLenguages"]["ListServers"];
                LenguagesManager.StringsCreditsLenguages.SupportedBy = datosDelIdioma["StringsCreditsLenguages"]["SupportedBy"];
                LenguagesManager.StringsCreditsLenguages.FollowOn    = datosDelIdioma["StringsCreditsLenguages"]["FollowOn"];

                if (Convert.ToInt32(materialRaisedButton1.Tag).Equals(0))
                {
                    materialRaisedButton1.Text = LenguagesManager.StringsPrincipalLenguages.ButtonConnect;
                }
                else
                {
                    materialRaisedButton1.Text = LenguagesManager.StringsPrincipalLenguages.ButtonDisconnect;
                }
                toolTip1.SetToolTip(this.materialRaisedButton1, datosDelIdioma["StringsPrincipalLenguages"]["ToolTipConnect"]);

                if (labelServers.Text.Contains("..."))
                {
                    labelServers.Text = LenguagesManager.StringsPrincipalLenguages.ServersLoading;
                }
                else
                {
                    labelServers.Text = LenguagesManager.StringsPrincipalLenguages.Servers;
                }

                materialRaisedButton2.Text = datosDelIdioma["StringsPrincipalLenguages"]["ButtonReload"];
                toolTip1.SetToolTip(this.materialRaisedButton2, datosDelIdioma["StringsPrincipalLenguages"]["ToolTipReload"]);
                toolTip1.SetToolTip(linkLabel2, datosDelIdioma["StringsPrincipalLenguages"]["ToolTipMTU"]);
                toolTip1.SetToolTip(txtPmtu, datosDelIdioma["StringsPrincipalLenguages"]["ToolTipMTUValue"]);
                ckConsola.Text = datosDelIdioma["StringsPrincipalLenguages"]["ShowConsole"];
                toolTip1.SetToolTip(ckConsola, datosDelIdioma["StringsPrincipalLenguages"]["ShowConsoleToolTip"]);
                labelDatos.Text            = datosDelIdioma["StringsPrincipalLenguages"]["LanPlayConsoleLabel"];
                materialRaisedButton3.Text = datosDelIdioma["StringsPrincipalLenguages"]["ButtonCredits"];
                toolTip1.SetToolTip(materialRaisedButton3, datosDelIdioma["StringsPrincipalLenguages"]["Credits"]);
                colServidor.HeaderText   = datosDelIdioma["StringsPrincipalLenguages"]["HeaderServer"];
                colUbicacion.HeaderText  = datosDelIdioma["StringsPrincipalLenguages"]["HeaderLocation"];
                colEstatus.HeaderText    = datosDelIdioma["StringsPrincipalLenguages"]["HeaderStatus"];
                colConectados.HeaderText = datosDelIdioma["StringsPrincipalLenguages"]["HeaderUsers"];
                colPing.HeaderText       = datosDelIdioma["StringsPrincipalLenguages"]["HeaderPing"];

                if (datosDelIdioma["StringsPrincipalLenguages"]["ButtonReleases", TiposDevolver.Boleano])
                {
                    materialRaisedButton4.Text = datosDelIdioma["StringsPrincipalLenguages"]["ButtonReleases"];
                }

                if (datosDelIdioma["StringsPrincipalLenguages"]["LanPlayVersionLabel", TiposDevolver.Boleano])
                {
                    lblLanPlayVersion.Text = datosDelIdioma["StringsPrincipalLenguages"]["LanPlayVersionLabel"];
                }

                if (datosDelIdioma["StringsPrincipalLenguages"]["checkAutoInterfaz", TiposDevolver.Boleano])
                {
                    ckAutoSelectInterfaz.Text = datosDelIdioma["StringsPrincipalLenguages"]["checkAutoInterfaz"];
                }

                if (datosDelIdioma["StringsPrincipalLenguages"]["UpdateMessage", TiposDevolver.Boleano])
                {
                    LenguagesManager.StringsPrincipalLenguages.UpdateMessage = datosDelIdioma["StringsPrincipalLenguages"]["UpdateMessage"];
                }
                else
                {
                    LenguagesManager.StringsPrincipalLenguages.UpdateMessage = "There is a new version.\nDo you want to update?";
                }

                if (datosDelIdioma["StringsPrincipalLenguages"]["ButtonLastVersionLP", TiposDevolver.Boleano])
                {
                    buttonLast.Text = datosDelIdioma["StringsPrincipalLenguages"]["ButtonLastVersionLP"];
                }
                else
                {
                    buttonLast.Text = "Last Version";
                }

                if (datosDelIdioma["StringsPrincipalLenguages"]["ToolTipLastVersionLP", TiposDevolver.Boleano])
                {
                    toolTip1.SetToolTip(buttonLast, datosDelIdioma["StringsPrincipalLenguages"]["ToolTipLastVersionLP"]);
                }
                else
                {
                    toolTip1.SetToolTip(buttonLast, "Get the latest version of Lan - Play");
                }
            }
        }
Esempio n. 6
0
        private void FormDatosDelJuego_Load(object sender, System.EventArgs e)
        {
            StringBuilder sbDatos = new StringBuilder();


            if (game.toArray().Length > 0)
            {
                txtTitulo.Text = game["Titulo"];

                if (game["Descripcion", TiposDevolver.Boleano])
                {
                    txtDescripcion.Text = game["Descripcion"];
                }

                if (game["UploadBy", TiposDevolver.Boleano])
                {
                    txtUploadBy.Text = game["UploadBy"];
                }

                if (game["Peso", TiposDevolver.Boleano])
                {
                    txtPeso.Text = game["Peso"];
                }

                if (game["Formato", TiposDevolver.Boleano])
                {
                    txtFormato.Text = game["Formato"];
                }

                if (game["Password", TiposDevolver.Boleano])
                {
                    txtPassword.Text = game["Password"];
                }

                txtPortada.Text   = game["ImagenJuego"];
                txtUrlAvatar.Text = game["ImagenDiscord"];

                foreach (var link in game["Links"].toArray())
                {
                    if (sbDatos.Length > 0)
                    {
                        sbDatos.Append(Environment.NewLine);
                    }

                    sbDatos.Append(link);
                }

                txtGameLinks.Text = sbDatos.ToString();

                sbDatos.Clear();
            }

            if (update.toArray().Length > 0)
            {
                txtVersion.Text = update["Version"];

                if (update["Peso", TiposDevolver.Boleano])
                {
                    txtPesoUpdate.Text = update["Peso"];
                }

                if (update["Formato", TiposDevolver.Boleano])
                {
                    txtFormatoUpdate.Text = update["Formato"];
                }

                if (update["Password", TiposDevolver.Boleano])
                {
                    txtPasswordUpdate.Text = update["Password"];
                }

                foreach (var link in update["Links"].toArray())
                {
                    if (sbDatos.Length > 0)
                    {
                        sbDatos.Append(Environment.NewLine);
                    }

                    sbDatos.Append(link);
                }

                txtLinksUpdate.Text = sbDatos.ToString();

                sbDatos.Clear();
            }

            if (dlc.toArray().Length > 0)
            {
                if (dlc["Peso", TiposDevolver.Boleano])
                {
                    txtPesoDlc.Text = dlc["Peso"];
                }

                if (dlc["Formato", TiposDevolver.Boleano])
                {
                    txtformatoDlc.Text = dlc["Formato"];
                }

                if (dlc["Password", TiposDevolver.Boleano])
                {
                    txtPasswordDlc.Text = dlc["Password"];
                }

                foreach (var link in dlc["Links"].toArray())
                {
                    if (sbDatos.Length > 0)
                    {
                        sbDatos.Append(Environment.NewLine);
                    }

                    sbDatos.Append(link);
                }

                txtLinksDlc.Text = sbDatos.ToString();

                sbDatos.Clear();
            }
        }
Esempio n. 7
0
        private void guardarJuego()
        {
            stdClassCSharp gamesStd   = stdClassCSharp.readJsonFile("games.json");
            stdClassCSharp updatesStd = stdClassCSharp.readJsonFile("updates.json");
            stdClassCSharp dlcStd     = stdClassCSharp.readJsonFile("dlcs.json");

            game["Titulo"] = txtTitulo.Text.Trim();

            if (!string.IsNullOrWhiteSpace(txtDescripcion.Text))
            {
                game["Descripcion"] = txtDescripcion.Text;
            }
            else if (game["Descripcion", TiposDevolver.Boleano])
            {
                game.Remove("Descripcion");
            }

            if (!string.IsNullOrWhiteSpace(txtPeso.Text))
            {
                game["Peso"] = txtPeso.Text;
            }
            else if (game["Peso", TiposDevolver.Boleano])
            {
                game.Remove("Peso");
            }

            if (!string.IsNullOrWhiteSpace(txtFormato.Text))
            {
                game["Formato"] = txtFormato.Text;
            }
            else if (game["Formato", TiposDevolver.Boleano])
            {
                game.Remove("Formato");
            }

            if (!string.IsNullOrWhiteSpace(txtPassword.Text))
            {
                game["Password"] = txtPassword.Text;
            }
            else if (game["Password", TiposDevolver.Boleano])
            {
                game.Remove("Password");
            }

            if (!string.IsNullOrWhiteSpace(txtUploadBy.Text))
            {
                game["UploadBy"] = txtUploadBy.Text;
            }
            else if (game["UploadBy", TiposDevolver.Boleano])
            {
                game.Remove("UploadBy");
            }

            if (!string.IsNullOrWhiteSpace(txtUrlAvatar.Text))
            {
                game["ImagenDiscord"] = txtUrlAvatar.Text;
            }
            else if (game["ImagenDiscord", TiposDevolver.Boleano])
            {
                game.Remove("ImagenDiscord");
            }

            if (!string.IsNullOrWhiteSpace(txtPortada.Text))
            {
                game["ImagenJuego"] = txtPortada.Text;
            }
            else if (game["ImagenJuego", TiposDevolver.Boleano])
            {
                game.Remove("ImagenJuego");
            }

            game["Links"] = new stdClassCSharp(true);

            foreach (string link in txtGameLinks.Text.Trim().Split(new String[] { Environment.NewLine }, StringSplitOptions.None))
            {
                game["Links"].Add(link);
            }

            if (!string.IsNullOrWhiteSpace(txtVersion.Text) && !string.IsNullOrWhiteSpace(txtLinksUpdate.Text))
            {
                update["Titulo"] = txtTitulo.Text.Trim();

                update["Version"] = txtVersion.Text.Trim();

                if (!string.IsNullOrWhiteSpace(txtPesoUpdate.Text))
                {
                    update["Peso"] = txtPesoUpdate.Text;
                }
                else if (update["Peso", TiposDevolver.Boleano])
                {
                    update.Remove("Peso");
                }

                if (!string.IsNullOrWhiteSpace(txtFormatoUpdate.Text))
                {
                    update["Formato"] = txtFormatoUpdate.Text;
                }
                else if (update["Formato", TiposDevolver.Boleano])
                {
                    update.Remove("Formato");
                }

                if (!string.IsNullOrWhiteSpace(txtPasswordUpdate.Text))
                {
                    update["Password"] = txtPasswordUpdate.Text;
                }
                else if (update["Password", TiposDevolver.Boleano])
                {
                    update.Remove("Password");
                }

                if (!string.IsNullOrWhiteSpace(txtUploadBy.Text))
                {
                    update["UploadBy"] = txtUploadBy.Text;
                }
                else if (update["UploadBy", TiposDevolver.Boleano])
                {
                    update.Remove("UploadBy");
                }

                if (!string.IsNullOrWhiteSpace(txtUrlAvatar.Text))
                {
                    update["ImagenDiscord"] = txtUrlAvatar.Text;
                }
                else if (update["ImagenDiscord", TiposDevolver.Boleano])
                {
                    update.Remove("ImagenDiscord");
                }

                if (!string.IsNullOrWhiteSpace(txtPortada.Text))
                {
                    update["ImagenJuego"] = txtPortada.Text;
                }
                else if (update["ImagenJuego", TiposDevolver.Boleano])
                {
                    update.Remove("ImagenJuego");
                }

                update["Links"] = new stdClassCSharp(true);

                foreach (string link in txtLinksUpdate.Text.Trim().Split(new String[] { Environment.NewLine }, StringSplitOptions.None))
                {
                    update["Links"].Add(link);
                }
            }

            if (!string.IsNullOrWhiteSpace(txtLinksDlc.Text))
            {
                dlc["Titulo"] = txtTitulo.Text.Trim();

                if (!string.IsNullOrWhiteSpace(txtPesoDlc.Text))
                {
                    dlc["Peso"] = txtPesoDlc.Text;
                }
                else if (dlc["Peso", TiposDevolver.Boleano])
                {
                    dlc.Remove("Peso");
                }

                if (!string.IsNullOrWhiteSpace(txtformatoDlc.Text))
                {
                    dlc["Formato"] = txtformatoDlc.Text;
                }
                else if (dlc["Formato", TiposDevolver.Boleano])
                {
                    dlc.Remove("Formato");
                }

                if (!string.IsNullOrWhiteSpace(txtPasswordDlc.Text))
                {
                    dlc["Password"] = txtPasswordDlc.Text;
                }
                else if (dlc["Password", TiposDevolver.Boleano])
                {
                    dlc.Remove("Password");
                }

                if (!string.IsNullOrWhiteSpace(txtUploadBy.Text))
                {
                    dlc["UploadBy"] = txtUploadBy.Text;
                }
                else if (dlc["UploadBy", TiposDevolver.Boleano])
                {
                    dlc.Remove("UploadBy");
                }

                if (!string.IsNullOrWhiteSpace(txtUrlAvatar.Text))
                {
                    dlc["ImagenDiscord"] = txtUrlAvatar.Text;
                }
                else if (dlc["ImagenDiscord", TiposDevolver.Boleano])
                {
                    dlc.Remove("ImagenDiscord");
                }

                if (!string.IsNullOrWhiteSpace(txtPortada.Text))
                {
                    dlc["ImagenJuego"] = txtPortada.Text;
                }
                else if (dlc["ImagenJuego", TiposDevolver.Boleano])
                {
                    dlc.Remove("ImagenJuego");
                }

                dlc["Links"] = new stdClassCSharp(true);

                foreach (string link in txtLinksDlc.Text.Trim().Split(new String[] { Environment.NewLine }, StringSplitOptions.None))
                {
                    dlc["Links"].Add(link);
                }
            }

            if (game["UpdateIndex", TiposDevolver.Boleano])
            {
                if (update.toArray().Length == 0)
                {
                    updatesStd.Remove(game["UpdateIndex", TiposDevolver.Entero]);
                    game.Remove("UpdateIndex");
                }
                else
                {
                    updatesStd[game["UpdateIndex", TiposDevolver.Entero]] = update;
                }
            }
            else if (update.toArray().Length > 0)
            {
                updatesStd.Add(update);
                game["UpdateIndex"] = updatesStd.toArray().Length - 1;
            }

            if (game["DlcIndex", TiposDevolver.Boleano])
            {
                if (dlc.toArray().Length == 0)
                {
                    dlcStd.Remove(game["DlcIndex", TiposDevolver.Entero]);
                    game.Remove("DlcIndex");
                }
                else
                {
                    dlcStd[game["DlcIndex", TiposDevolver.Entero]] = dlc;
                }
            }
            else if (dlc.toArray().Length > 0)
            {
                dlcStd.Add(dlc);
                game["DlcIndex"] = dlcStd.toArray().Length - 1;
            }

            if (indexGame == -1)
            {
                gamesStd.Add(game);
            }
            else
            {
                gamesStd[indexGame] = game;
            }

            gamesStd.writeJsonFile("games.json");
            updatesStd.writeJsonFile("updates.json");
            dlcStd.writeJsonFile("dlcs.json");
        }