Inheritance: ActionLibrary.DTOs.ActionDefinitionDTO
コード例 #1
0
        public void AddSocialMove(SocialExchangeDTO newSocialExchange)
        {
            if (_cifAsset.m_SocialExchanges.Find(x=>x.ActionName.ToString() == newSocialExchange.Action) != null)
                _cifAsset.UpdateSocialExchange(newSocialExchange);
            else _cifAsset.AddExchange(newSocialExchange);

              //      SocialExchanges.DataSource = _cifAsset.m_SocialExchanges.ToList();
            //    SocialExchanges.Refresh();
            _mainForm.SetModified();
        }
コード例 #2
0
        public SocialExchange(SocialExchangeDTO s)
            : base(s)
        {
            InfluenceRules = new List<InfluenceRuleDTO>();
            //      Name = s.SocialExchangeName;
            foreach (var inf in s.InfluenceRules)
            {
                InfluenceRules.Add(inf);
            }

            Intent = s.Intent;
            Instantiation = s.Instantiation;
        }
コード例 #3
0
        static void Main(string[] args)
        {
            AssetManager.Instance.Bridge = new BasicIOBridge();

            var flirt = new SocialExchangeDTO {Action = "Flirt", Instantiation = "You are so beautiful"};
            var compliment = new SocialExchangeDTO { Action = "Compliment", Instantiation = "You are pretty cool" };

            CommeillFautAsset n = new CommeillFautAsset();
            n.AddExchange(flirt);
            n.AddExchange(compliment);

            RolePlayCharacterAsset npc = RolePlayCharacterAsset.LoadFromFile("../../../Examples/john.rpc");
            Console.WriteLine(npc.CharacterName);

               //     CommeillFautAsset cif;
               //     var flirt_id = cif.AddSocialExchange(flirt);
            //   var compliment_id = cif.AddSocialExchange(compliment);

             //   cif.GetSocialMove(Name.BuildName("Player"));
            Console.ReadLine();
        }
コード例 #4
0
        public void SetData(SocialExchangeDTO dto)
        {
            Intent = dto.Intent;
            Instantiation = dto.Instantiation;

            foreach (var go in dto.InfluenceRules)
            {
                InfluenceRules.Add(go);
            }

            SetFromDTO(dto);
        }