/// <summary>GameParams constructor. Warning: set the ZeroBasedScale parameter corectly!</summary> /// <param name="zeroBasedScale">Set as true if the scale for complexity, activity, /// planning is 0-based [0..4], otherwise [1..5]</param> public GameParams(bool zeroBasedScale) { ZeroBasedScale = zeroBasedScale; // Other parameters are set by default Title = ""; DesShortText = ""; DesLongText = ""; Tags = new List <string>(1); TagLinks = new List <string>(1); Complexity = ZeroBasedScale ? 0 : 1; Activity = ZeroBasedScale ? 0 : 1; Planning = ZeroBasedScale ? 0 : 1; Timing = new TimeRange(TimeRangeTag.undef); Age = new AgeRange(AgeRangeTag.undef); Players = new PlayersRange(); ManufacturerID = -1; ManufacturerName = ""; YearOfIssue = 0; Author = ""; WebPage = ""; Series = new List <string>(0); //new GameSeries(-1, ""); Categories = new List <string>(0); //new GameSeries(-1, ""); Thematic = new List <string>(0); OptionalTags = new List <string>(0); Absent = false; AbsentButAnnounced = false; }
/// <summary>GameParams constructor. Warning: set the ZeroBasedScale parameter corectly!</summary> /// <param name="zeroBasedScale">Set as true if the scale for complexity, activity, /// planning is 0-based [0..4], otherwise [1..5]</param> /// <param name="title">Game title</param> /// <param name="desShortText">Game short description (most often a slogan)</param> /// <param name="desLongText">Game long description (plain text)</param> /// <param name="complexity">complexity(easy|hard), scale: ZeroBasedScale ? [0..4] : [1..5]</param> /// <param name="activity">activity(move|think), scale: zeroBasedScale ? [0..4] : [1..5]</param> /// <param name="planning">planning(chance|tactics), scale: zeroBasedScale ? [0..4] : [1..5]</param> /// <param name="gamersNumber">number of gamers (0 by default), scale: zeroBasedScale ? [0..4] : [1..5]</param> /// <param name="timing">Game time range</param> /// <param name="age">Game age range</param> /// <param name="players">Game players range</param> /// <param name="series">Game series (e.g., Carcassonne)</param> /// <param name="categories">Game categories (e.g., Adventure games, Logic games, etc.)</param> /// <param name="thematic">Game thematic (e.g., Pirates, Knights, etc.)</param> /// <param name="optionalTags">Game options (e.g., EN, Games for the road, Games for pairs, etc.)</param> /// <param name="manufacturerID">Manufacturer ID</param> /// <param name="manufacturerName">Manufacturer name</param> /// <param name="yearOfIssue">Year of issue</param> /// <param name="author">Game author</param> /// <param name="webPage">Webpage</param> /// <param name="absent">Whether the site has this game absent or present</param> public GameParams(bool zeroBasedScale, string title, string desShortText, string desLongText, int complexity, int activity, int planning, TimeRange timing, AgeRange age, PlayersRange players, List <string> series, List <string> categories, List <string> thematic, List <string> optionalTags, int manufacturerID, string manufacturerName, int yearOfIssue, string author, string webPage, bool absent, bool absentButAnnounced) { ZeroBasedScale = zeroBasedScale; Title = title; DesShortText = desShortText; DesLongText = desLongText; Tags = new List <string>(1); TagLinks = new List <string>(1); Complexity = complexity; // via accessor Activity = activity; // via accessor Planning = planning; // via accessor Timing = timing; Age = age; Players = players; ManufacturerID = manufacturerID; ManufacturerName = manufacturerName; WebPage = webPage; YearOfIssue = yearOfIssue; Author = author; Series = series; Categories = categories; Thematic = thematic; OptionalTags = optionalTags; Absent = absent; AbsentButAnnounced = absentButAnnounced; }