public void loadLanguage(XmlNode languagenode, LanguageFamily family)
        {
            String speakingName     = "";
            int    speakingComplex  = 0;
            int    speakingComplex2 = 0;
            String fontName         = "";
            int    fontComplex      = 0;
            int    fontComplex2     = 0;

            foreach (XmlNode node in languagenode)
            {
                switch (node.Name)
                {
                case ManagmentXMLStrings.SpeakingName: speakingName = node.InnerText; break;

                case ManagmentXMLStrings.SpeakingComplex: Int32.TryParse(node.InnerText, out speakingComplex); break;

                case ManagmentXMLStrings.SpeakingComplexSecond: Int32.TryParse(node.InnerText, out speakingComplex2); break;

                case ManagmentXMLStrings.FontName: fontName = node.InnerText; break;

                case ManagmentXMLStrings.FontComplex: Int32.TryParse(node.InnerText, out fontComplex); break;

                case ManagmentXMLStrings.FontComplexSecond: Int32.TryParse(node.InnerText, out fontComplex2); break;
                }
            }

            FontTalent     ft;
            LanguageTalent lt;

            if (speakingComplex2 != 0)
            {
                lt = new LanguageTalent(speakingName, speakingComplex, speakingComplex2);
            }
            else
            {
                lt = new LanguageTalent(speakingName, speakingComplex);
            }

            if (fontComplex2 != 0)
            {
                ft = new FontTalent(fontName, fontComplex, fontComplex2);
            }
            else
            {
                ft = new FontTalent(fontName, fontComplex);
            }

            family.add(lt, ft);
        }
 public void addLanguageRow(LanguageTalent lt, FontTalent ft)
 {
     ltlist.Add(lt);
     ftlist.Add(ft);
 }
        private void loadRow(XmlNode rowElement)
        {
            String FontName     = null;
            String LanguageName = null;

            FontTalent     fTalent = null;
            LanguageTalent ltalent = null;

            foreach (XmlNode node in rowElement)
            {
                switch (node.Name)
                {
                case ManagmentXMLStrings.Language: LanguageName = node.InnerText; break;

                case ManagmentXMLStrings.Font: FontName = node.InnerText; break;
                }
            }
            if (0 != String.Compare("", FontName) && FontName != null)
            {
                InterfaceTalent talent = charakter.getTalent(FontName);
                if (talent == null)
                {
                    Log.writeLogLine("Laden der Language Family " + FamilyName + ". Das Talent " + FontName + " exestiert nicht");
                }
                else
                {
                    if (typeof(FontTalent).IsAssignableFrom(talent.GetType()))
                    {
                        fTalent = (FontTalent)charakter.getTalent(FontName);
                    }
                    else
                    {
                        Log.writeLogLine("Laden der Language Family " + FamilyName + ". Das Talent " + talent.getName() + " ist kein FontTalent");
                    }
                }
            }


            if (0 != String.Compare("", LanguageName) && LanguageName != null)
            {
                InterfaceTalent talent = charakter.getTalent(LanguageName);
                if (talent == null)
                {
                    Log.writeLogLine("Laden der Language Family " + FamilyName + ". Das Talent " + LanguageName + " exestiert nicht");
                }
                else
                {
                    if (typeof(LanguageTalent).IsAssignableFrom(talent.GetType()))
                    {
                        ltalent = (LanguageTalent)charakter.getTalent(LanguageName);
                    }
                    else
                    {
                        Log.writeLogLine("Laden der Language Family " + FamilyName + ". Das Talent " + talent.getName() + " ist kein LanguageTalent");
                    }
                }
            }


            if (fTalent == null)
            {
                fTalent = new FontTalent("", new List <string>());
            }
            if (ltalent == null)
            {
                ltalent = new LanguageTalent("", new List <string>());
            }

            LanguageFamily.addLanguageRow(ltalent, fTalent);
        }
        private static void loadTalentLanguage(XmlNode TalentNode, Charakter charakter)
        {
            foreach (XmlNode LanguageFamily in TalentNode)
            {
                String  familyName = "";
                XmlNode innerNode  = null;

                foreach (XmlNode Node in LanguageFamily)
                {
                    switch (Node.Name)
                    {
                    case (ManagmentXMLStrings.FamilyName): familyName = Node.InnerText; break;

                    case (ManagmentXMLStrings.Language): innerNode = Node; break;
                    }

                    if (String.Compare(familyName, "") != 0 && innerNode != null)
                    {
                        if (String.Compare(familyName, "Zwergisch-Familie") == 0)
                        {
                            Console.WriteLine("Test");
                        }


                        int            x      = charakter.getFamilyCount();
                        LanguageFamily family = null;

                        for (int i = 0; i < x; i++)
                        {
                            LanguageFamily fam = charakter.getFamily(i);
                            if (String.Compare(fam.getName(), familyName) == 0)
                            {
                                family = fam;
                                break;
                            }
                        }
                        if (family != null)
                        {
                            String Speakingname   = "";
                            String SpeakingTaW    = "";
                            String SpeakingMother = "";
                            String FontName       = "";
                            String FontTaW        = "";

                            foreach (XmlNode node in innerNode)
                            {
                                switch (node.Name)
                                {
                                case (ManagmentXMLStrings.SpeakingName): Speakingname = node.InnerText; break;

                                case (ManagmentXMLStrings.SpeakingTaW): SpeakingTaW = node.InnerText; break;

                                case (ManagmentXMLStrings.SpeakingMother): SpeakingMother = node.InnerText; break;

                                case (ManagmentXMLStrings.FontName): FontName = node.InnerText; break;

                                case (ManagmentXMLStrings.FontTaW): FontTaW = node.InnerText; break;
                                }
                            }

                            for (int i = 0; i < family.count(); i++)
                            {
                                LanguageTalent lt = family.getlanguageTalent(i);
                                FontTalent     ft = family.getFontTalent(i);

                                if (String.Compare(Speakingname, lt.getName()) == 0 && String.Compare(FontName, ft.getName()) == 0)
                                {
                                    lt.setTaw(SpeakingTaW);
                                    lt.setMotherMark(SpeakingMother);
                                    ft.setTaw(FontTaW);
                                }
                            }
                        }
                    }
                }
            }
        }