コード例 #1
0
        public string GetDescription(string id, DescriptionCategory category)
        {
            switch (category)
            {
            case DescriptionCategory.Creature:
                return(Creature.Loader.Get(id).EnglishDescription);
            }

            return("");
        }
コード例 #2
0
ファイル: GameHub.cs プロジェクト: attackgithub/UnicornHack
 public List <object> QueryStaticDescription(string topicId, DescriptionCategory category)
 => new List <object>(2)
 {
     GameQueryType.StaticDescription,
     _gameServices.Language.GetDescription(topicId, category)
 };
コード例 #3
0
ファイル: GameHub.cs プロジェクト: attackgithub/UnicornHack
 public Task ShowStaticDescriptionDialog(string playerName, string topicId, DescriptionCategory category)
 {
     // TODO: only send to clients watching this player
     return(Clients.All.SendAsync("ReceiveUIRequest", QueryStaticDescription(topicId, category)));
 }