예제 #1
0
        private void ProcessAttributeCommand(SetAttributeCommand command, string s, ref int targetPoints)
        {
            var op           = FindOperation(s);
            var numberString = Regex.Match(s, @"\d+").Value;

            if (string.IsNullOrWhiteSpace(numberString))
            {
                WrmChargenCommon.SendErrorMessage(Session, "No valid number was found.");
                return;
            }

            int n;

            if (!int.TryParse(numberString, out n))
            {
                WrmChargenCommon.SendErrorMessage(Session, "Could not process the number.");
                return;
            }

            if (string.IsNullOrWhiteSpace(op))
            {
                // No operator? Try to set the value directly to the number provided.
                SetAttributeTarget(ref targetPoints, n);
            }
            else if (op == "+")
            {
                SetAttributeTarget(ref targetPoints, targetPoints + n);
            }
            else if (op == "-")
            {
                SetAttributeTarget(ref targetPoints, targetPoints - n);
            }
        }
예제 #2
0
        /// <summary>ProcessInput is used to receive the user input during this state.</summary>
        /// <param name="command">The command text to be processed.</param>
        public override void ProcessInput(string command)
        {
            var currentCommand = command.ToLower().Trim();

            switch (currentCommand)
            {
            case "view":
                ViewRaceDescription(currentCommand);
                break;

            case "list":
                RefreshScreen();
                break;

            default:
                var race = GetRace(currentCommand);
                if (race != null)
                {
                    var playerBehavior = Session.Thing.Behaviors.FindFirst <PlayerBehavior>();
                    playerBehavior.Race = race;
                    StateMachine.HandleNextStep(this, StepStatus.Success);
                }
                else
                {
                    WrmChargenCommon.SendErrorMessage(Session, "Invalid race. Try again, or use 'view [race]' or 'list'.");
                }
                break;
            }
        }
예제 #3
0
        private bool SetSkill(string skillName)
        {
            var selectedSkill = (from s in this.gameSkills
                                 where s.Name.Equals(skillName, StringComparison.OrdinalIgnoreCase)
                                 select s).FirstOrDefault();

            if (selectedSkill == null)
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That skill does not exist.");
                return(false);
            }

            var alreadySelected = (from s in this.selectedSkills
                                   where s.Name.Equals(skillName, StringComparison.OrdinalIgnoreCase)
                                   select s).Any();

            if (alreadySelected)
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "You have already selected that skill.");
                return(false);
            }

            if (this.selectedSkills.Count() >= 3)
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "You have already selected all 3 skills.");
                return(false);
            }

            this.selectedSkills.Add(selectedSkill);
            this.RefreshScreen();
            this.Session.WritePrompt();
            return(true);
        }
예제 #4
0
        private bool SetSkill(string skillName)
        {
            var selectedSkill = GetSkill(skillName);

            if (selectedSkill == null)
            {
                WrmChargenCommon.SendErrorMessage(Session, "That skill does not exist.");
                return(false);
            }

            if (selectedSkills.Contains(selectedSkill))
            {
                WrmChargenCommon.SendErrorMessage(Session, "You have already selected that skill.");
                return(false);
            }

            if (selectedSkills.Count() >= 3)
            {
                WrmChargenCommon.SendErrorMessage(Session, "You have already selected all 3 skills.");
                return(false);
            }

            selectedSkills.Add(selectedSkill);
            RefreshScreen();
            return(true);
        }
예제 #5
0
        private void ViewRaceDescription(string race)
        {
            var raceToView = race.Replace("view ", string.Empty);

            var cultureInfo = Thread.CurrentThread.CurrentCulture;
            var textInfo    = cultureInfo.TextInfo;

            var properCaseRace = textInfo.ToTitleCase(raceToView);

            var foundRace = (from r in gameRaces
                             where r.Name == properCaseRace
                             select r).FirstOrDefault();

            if (foundRace != null)
            {
                var output = new OutputBuilder();
                output.AppendSeparator('=', "yellow", true);
                output.AppendLine($"Description for {foundRace.Name}");
                output.AppendSeparator('-', "yellow");
                output.AppendLine($"<%b%><%white%>{foundRace.Description}<%n%>");
                output.AppendSeparator('=', "yellow", true);
                Session.Write(output);
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(Session, "That race does not exist.");
            }
        }
예제 #6
0
        private void ViewRaceDescription(string race)
        {
            string raceToView = race.Replace("view ", string.Empty);

            CultureInfo cultureInfo = Thread.CurrentThread.CurrentCulture;
            TextInfo    textInfo    = cultureInfo.TextInfo;

            string properCaseRace = textInfo.ToTitleCase(raceToView);

            var foundRace = (from r in this.gameRaces
                             where r.Name == properCaseRace
                             select r).FirstOrDefault();

            if (foundRace != null)
            {
                var sb = new StringBuilder();
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=" + Environment.NewLine);
                sb.AppendFormat("Description for {0}" + Environment.NewLine, foundRace.Name);
                sb.Append("=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>" + Environment.NewLine);
                sb.Append("<%b%><%white%>" + foundRace.Description + Environment.NewLine);
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>");

                this.Session.Write(sb.ToString());
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That race does not exist.");
            }
        }
예제 #7
0
        /// <summary>Processes the text that the player sends while in this state.</summary>
        /// <param name="command">The command that the player just sent.</param>
        public override void ProcessInput(string command)
        {
            var    commandParts   = command.Split(' ');
            string currentCommand = commandParts[0].ToLower();

            switch (currentCommand)
            {
            case "clear":
                this.ClearSkills();
                break;

            case "view":
                if (commandParts.Length > 1)
                {
                    this.ViewSkillDescription(commandParts[1]);
                }
                else
                {
                    WrmChargenCommon.SendErrorMessage(this.Session, "Please select which skill you would like to view details for, like 'view axes'.");
                }
                break;

            case "list":
                this.RefreshScreen();
                break;

            case "done":
                this.ProcessDone();
                break;

            default:
                this.SetSkill(currentCommand);
                break;
            }
        }
예제 #8
0
 /// <summary>ProcessInput is used to receive the user input during this state.</summary>
 /// <param name="command">The command text to be processed.</param>
 public override void ProcessInput(string command)
 {
     if (!string.IsNullOrEmpty(command) && this.SetGender(command))
     {
         this.ProcessDone();
     }
     else if (!this.HandleCommand(command))
     {
         WrmChargenCommon.SendErrorMessage(this.Session, "Invalid command. Please select a gender.");
     }
 }
예제 #9
0
 private void ProcessDone()
 {
     if (this.selectedTalent != string.Empty)
     {
         // Proceed to the next step.
         this.StateMachine.HandleNextStep(this, StepStatus.Success);
     }
     else
     {
         WrmChargenCommon.SendErrorMessage(this.Session, "Please select a talent before proceeding to the next step.");
     }
 }
예제 #10
0
        private void ProcessDone()
        {
            if (this.selectedRace != null)
            {
                var playerBehavior = this.StateMachine.NewCharacter.Behaviors.FindFirst <PlayerBehavior>();
                playerBehavior.Race = this.selectedRace;

                // Proceed to the next step.
                this.StateMachine.HandleNextStep(this, StepStatus.Success);
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "You must select a valid race before continuing.");
            }
        }
예제 #11
0
        private bool SetGender(string specifiedGender)
        {
            // Support strings of format "select m" and "m" by ignoring "select " from the input.
            string currentGender = specifiedGender.Replace("select ", string.Empty);

            this.selectedGender = (from g in GameSystemController.Instance.GameGenders
                                   where g.Name.Equals(currentGender, StringComparison.CurrentCultureIgnoreCase) ||
                                   g.Abbreviation.Equals(currentGender, StringComparison.CurrentCultureIgnoreCase)
                                   select g).FirstOrDefault();
            if (this.selectedGender == null)
            {
                WrmChargenCommon.SendErrorMessage(this.Session, string.Format("'{0}' is an invalid gender selection.", currentGender));
                this.RefreshScreen();
            }

            return(this.selectedGender != null);
        }
예제 #12
0
        private void ProcessDone()
        {
            if (this.selectedSkills.Count() != 3)
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "Please select all your starting skills before proceeding to the next step.");
                return;
            }

            // Assign the skills to the PlayerBehavior's parent, which should be a Thing object.
            var playerBehavior = this.Session.Thing.Behaviors.FindFirst <PlayerBehavior>();

            foreach (var gameSkill in this.selectedSkills)
            {
                playerBehavior.Parent.Skills.Add(gameSkill.Name, gameSkill);
            }

            // Proceed to the next step.
            this.StateMachine.HandleNextStep(this, StepStatus.Success);
        }
예제 #13
0
        private void ViewSkillDescription(string skillName)
        {
            GameSkill foundSkill = GetSkill(skillName);

            if (foundSkill == null)
            {
                WrmChargenCommon.SendErrorMessage(Session, "That skill does not exist.");
                return;
            }

            var output = new OutputBuilder();

            output.AppendSeparator('=', "yellow", true);
            output.AppendLine($"Description for {foundSkill.Name}");
            output.AppendSeparator('-', "yellow");
            output.AppendLine($"<%b%><%white%>{foundSkill.Description}");
            output.AppendSeparator('=', "yellow", true);
            Session.Write(output);
        }
예제 #14
0
        private void SetTalent(string talentToSet)
        {
            CultureInfo cultureInfo = Thread.CurrentThread.CurrentCulture;
            TextInfo    textInfo    = cultureInfo.TextInfo;

            Talent currentSelection = (from r in this.talents
                                       where r.Name.ToLower() == talentToSet.ToLower()
                                       select r).FirstOrDefault();

            if (currentSelection != null)
            {
                this.selectedTalent = textInfo.ToTitleCase(talentToSet);
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That talent does not exist.");
            }

            this.RefreshScreen();
        }
예제 #15
0
        private void ViewSkillDescription(string skillName)
        {
            GameSkill foundSkill = GetSkill(skillName);

            if (foundSkill == null)
            {
                WrmChargenCommon.SendErrorMessage(Session, "That skill does not exist.");
                return;
            }

            var sb = new StringBuilder();

            sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=" + Environment.NewLine);
            sb.AppendFormat("Description for {0}" + Environment.NewLine, foundSkill.Name);
            sb.Append("=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>" + Environment.NewLine);
            sb.Append("<%b%><%white%>" + foundSkill.Description + Environment.NewLine);
            sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>");

            Session.Write(sb.ToString());
        }
예제 #16
0
        private void ViewTalentDescription(string talent)
        {
            Talent foundTalent = GetTalent(talent);

            if (foundTalent != null)
            {
                var sb = new StringBuilder();
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=" + Environment.NewLine);
                sb.AppendFormat("Description for {0}" + Environment.NewLine, foundTalent.Name);
                sb.Append("=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>" + Environment.NewLine);
                sb.Append("<%b%><%white%>" + foundTalent.Description + Environment.NewLine);
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>");

                Session.Write(sb.ToString());
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(Session, "That talent does not exist.");
            }
        }
예제 #17
0
        private void ViewTalentDescription(string talent)
        {
            var foundTalent = GetTalent(talent);

            if (foundTalent != null)
            {
                var output = new OutputBuilder();
                output.AppendSeparator('=', "yellow", true);
                output.AppendLine($"Description for {foundTalent.Name}");
                output.AppendSeparator('-', "yellow");
                output.AppendLine($"<%b%><%white%>{foundTalent.Description}");
                output.AppendSeparator('=', "yellow", true);

                Session.Write(output);
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(Session, "That talent does not exist.");
            }
        }
예제 #18
0
        private void SetAttributeTarget(ref int targetPoints, int newValue)
        {
            int netChange = newValue - targetPoints;

            if (newValue > 6)
            {
                WrmChargenCommon.SendErrorMessage(Session, "No attribute can be greater than 6.");
            }
            else if (newValue < 0)
            {
                WrmChargenCommon.SendErrorMessage(Session, "No attribute can be less than 0.");
            }
            else if (SpentPoints + netChange > MaxPoints)
            {
                WrmChargenCommon.SendErrorMessage(Session, "You do not have enough points to spend.");
            }
            else
            {
                targetPoints = newValue;
            }
        }
예제 #19
0
        /// <summary>Processes the text that the player sends while in this state.</summary>
        /// <param name="s">The command that the player just sent.</param>
        public override void ProcessInput(string s)
        {
            var command = FindTargetCommand(s);

            switch (command)
            {
            case SetAttributeCommand.Warrior:
                ProcessAttributeCommand(command, s, ref warriorPoints);
                break;

            case SetAttributeCommand.Rogue:
                ProcessAttributeCommand(command, s, ref roguePoints);
                break;

            case SetAttributeCommand.Mage:
                ProcessAttributeCommand(command, s, ref magePoints);
                break;

            case SetAttributeCommand.Done:
                if (SpentPoints != MaxPoints)
                {
                    WrmChargenCommon.SendErrorMessage(Session, "You have not spent all your points.");
                }
                else
                {
                    // Proceed to the next step.
                    SetPlayerBehaviorAttributes();
                    StateMachine.HandleNextStep(this, StepStatus.Success);
                    return;
                }

                break;

            default:
                WrmChargenCommon.SendErrorMessage(Session, "Unknown command. Please use warrior, rogue, mage, or done.");
                break;
            }

            RefreshScreen();
        }
예제 #20
0
        private void ViewTalentDescription(string talent)
        {
            string talentToView = talent.Replace("view ", string.Empty);

            Talent foundTalent = this.talents.Find(s => s.Name.Equals(talentToView, StringComparison.CurrentCultureIgnoreCase));

            if (foundTalent != null)
            {
                var sb = new StringBuilder();
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=" + Environment.NewLine);
                sb.AppendFormat("Description for {0}" + Environment.NewLine, foundTalent.Name);
                sb.Append("=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>" + Environment.NewLine);
                sb.Append("<%b%><%white%>" + foundTalent.Description + Environment.NewLine);
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>");

                this.Session.Write(sb.ToString());
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That talent does not exist.");
            }
        }
예제 #21
0
        private void ViewSkillDescription(string skillName)
        {
            GameSkill foundSkill = (from s in this.gameSkills
                                    where s.Name.Equals(skillName, StringComparison.OrdinalIgnoreCase)
                                    select s).FirstOrDefault();

            if (foundSkill == null)
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That skill does not exist.");
                return;
            }

            var sb = new StringBuilder();

            sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=" + Environment.NewLine);
            sb.AppendFormat("Description for {0}" + Environment.NewLine, foundSkill.Name);
            sb.Append("=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>" + Environment.NewLine);
            sb.Append("<%b%><%white%>" + foundSkill.Description + Environment.NewLine);
            sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>");

            this.Session.Write(sb.ToString());
        }
예제 #22
0
        private void SetRace(string raceToSelect)
        {
            CultureInfo cultureInfo = Thread.CurrentThread.CurrentCulture;
            TextInfo    textInfo    = cultureInfo.TextInfo;

            string currentRace = textInfo.ToTitleCase(raceToSelect);

            GameRace currSelection = (from r in this.gameRaces
                                      where r.Name == currentRace
                                      select r).FirstOrDefault();

            if (currSelection != null)
            {
                this.selectedRace = currSelection;
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That race does not exist.");
            }

            this.RefreshScreen();
        }
예제 #23
0
        /// <summary>ProcessInput is used to receive the user input during this state.</summary>
        /// <param name="command">The command text to be processed.</param>
        public override void ProcessInput(string command)
        {
            var commandParts   = command.Split(' ');
            var currentCommand = commandParts[0];

            switch (currentCommand)
            {
            case "view":
                if (commandParts.Length > 1)
                {
                    string talentName = string.Join(" ", commandParts, 1, commandParts.Length - 1);
                    ViewTalentDescription(talentName);
                }
                else
                {
                    WrmChargenCommon.SendErrorMessage(Session, "Please select which talent you would like to view details for, like 'view sailor'.");
                }
                break;

            case "list":
                RefreshScreen();
                break;

            default:
                var talent = GetTalent(currentCommand);
                if (talent != null)
                {
                    // TODO: Save talent to a WRM-specific Behavior?
                    StateMachine.HandleNextStep(this, StepStatus.Success);
                }
                else
                {
                    WrmChargenCommon.SendErrorMessage(Session, "Invalid talent. Try again, or use 'view [talent]' or 'list'.");
                }
                break;
            }
        }
예제 #24
0
        /// <summary>ProcessInput is used to receive the user input during this state.</summary>
        /// <param name="command">The command text to be processed.</param>
        public override void ProcessInput(string command)
        {
            string currentCommand = command.ToLower().Trim();

            switch (currentCommand)
            {
            case "clear":
                this.ClearRace();
                break;

            case "view":
                this.ViewRaceDescription(currentCommand);
                break;

            case "done":
                this.ProcessDone();
                break;

            case "list":
                this.RefreshScreen();
                break;

            default:
                string tentativeRaceName = this.GetCommardPart(currentCommand);

                if (tentativeRaceName == string.Empty)
                {
                    this.SetRace(currentCommand);
                }
                else
                {
                    WrmChargenCommon.SendErrorMessage(this.Session, "Invalid command. Please use clear, view, list, or done.");
                }

                break;
            }
        }
예제 #25
0
        private void SetSkill(string skillToSet)
        {
            CultureInfo cultureInfo = Thread.CurrentThread.CurrentCulture;
            TextInfo    textInfo    = cultureInfo.TextInfo;

            string currentSkill = textInfo.ToTitleCase(skillToSet);

            GameSkill currentSelection = (from r in this.gameSkills
                                          where r.Name == currentSkill
                                          select r).FirstOrDefault();

            if (currentSelection != null)
            {
                if (string.IsNullOrEmpty(this.skillOne))
                {
                    this.skillOne   = currentSkill;
                    this.skillCount = 1;
                }
                else if (string.IsNullOrEmpty(this.skillTwo))
                {
                    this.skillTwo   = currentSkill;
                    this.skillCount = 2;
                }
                else if (string.IsNullOrEmpty(this.skillThree))
                {
                    this.skillThree = currentSkill;
                    this.skillCount = 3;
                }
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That skill does not exist.");
            }

            this.RefreshScreen();
            this.Session.WritePrompt();
        }
예제 #26
0
        private void ViewSkillDescription(string skill)
        {
            string skillToView = skill.Replace("view ", string.Empty);

            var game = GameSystemController.Instance;

            GameSkill foundSkill = game.GameSkills.Find(s => s.Name.ToLower() == skillToView);

            if (foundSkill != null)
            {
                var sb = new StringBuilder();
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=" + Environment.NewLine);
                sb.AppendFormat("Description for {0}" + Environment.NewLine, foundSkill.Name);
                sb.Append("=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>" + Environment.NewLine);
                sb.Append("<%b%><%white%>" + foundSkill.Description + Environment.NewLine);
                sb.Append("<%b%><%yellow%>=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=<%n%>");

                this.Session.Write(sb.ToString());
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "That skill does not exist.");
            }
        }
예제 #27
0
        private void ProcessDone()
        {
            int doneSkillCount = 0;
            var newSkills      = new List <GameSkill>();

            // Process the first skill
            if (!string.IsNullOrEmpty(this.skillOne))
            {
                var firstSkill = this.gameSkills.Find(s => s.Name.ToLower() == this.skillOne.ToLower());

                if (firstSkill != null)
                {
                    newSkills.Add(firstSkill);
                    doneSkillCount++;
                }
            }

            // Process the second skill
            if (!string.IsNullOrEmpty(this.skillTwo))
            {
                var secondtSkill = this.gameSkills.Find(s => s.Name.ToLower() == this.skillTwo.ToLower());

                if (secondtSkill != null)
                {
                    newSkills.Add(secondtSkill);
                    doneSkillCount++;
                }
            }

            // Process the third skill
            if (!string.IsNullOrEmpty(this.skillThree))
            {
                var thirdtSkill = this.gameSkills.Find(s => s.Name.ToLower() == this.skillThree.ToLower());

                if (thirdtSkill != null)
                {
                    newSkills.Add(thirdtSkill);
                    doneSkillCount++;
                }
            }

            if (doneSkillCount == 3)
            {
                var playerBehavior = this.StateMachine.NewCharacter.Behaviors.FindFirst <PlayerBehavior>();

                // Assign the skills to the PlayerBehavior's parent, which should be a Thing object.
                foreach (var gameSkill in newSkills)
                {
                    playerBehavior.Parent.Skills.Add(gameSkill.Name, gameSkill);
                }

                // Proceed to the next step.
                this.StateMachine.HandleNextStep(this, StepStatus.Success);
                return;
            }
            else
            {
                WrmChargenCommon.SendErrorMessage(this.Session, "Please fill all of the skill slots before proceeding to the next step.");
            }

            this.RefreshScreen();
        }