osrs-tools 0.1.1 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (76) hide show
  1. package/README.md +106 -30
  2. package/package.json +90 -75
  3. package/src/index.ts +6 -433
  4. package/src/model/Requirement.ts +173 -0
  5. package/src/model/account/OsrsAccount.ts +82 -0
  6. package/src/model/quest/Quest.ts +44 -0
  7. package/src/model/quest/QuestTool.ts +96 -0
  8. package/src/model/slayer/Assignment.ts +40 -0
  9. package/src/model/slayer/SlayerMaster.ts +137 -0
  10. package/src/model/slayer/SlayerReward.ts +39 -0
  11. package/src/model/slayer/Task.ts +168 -0
  12. package/src/resources/QuestData.json +754 -0
  13. package/src/{data/Diaries → resources/quest}/diaries.json +3 -3
  14. package/src/{data/quest/questData.ts → resources/quest/questData.js} +169 -223
  15. package/src/{data/quest/questDataArray.json → resources/quest/questData.json} +950 -1833
  16. package/src/resources/quest/questDataArray.js +5489 -0
  17. package/src/{data/quest/questData.json → resources/quest/questDataArray.json} +642 -643
  18. package/src/{data/quest/miniquestQuestArray.json → resources/quest/subquestArray.js} +2 -2
  19. package/src/{data/quest/subQuestArray.json → resources/quest/subquestArray.json} +1 -1
  20. package/src/{data → resources}/quest/testObj.json +148 -148
  21. package/src/{data → resources}/quest/testarray.json +149 -149
  22. package/src/resources/quests/CooksAssistant.json +34 -0
  23. package/src/resources/slayer/Masters.ts +180 -0
  24. package/src/resources/slayer/SlayerData.ts +45 -0
  25. package/src/resources/slayer/SlayerExtends.ts +218 -0
  26. package/src/resources/slayer/SlayerUnlock.ts +194 -0
  27. package/src/resources/slayer/slayer.json +3581 -0
  28. package/src/resources/slayer/slayerBuys.ts +38 -0
  29. package/src/resources/slayer/slayerData.json +4431 -0
  30. package/src/resources/slayer/tasks/ChaelderTasks.ts +235 -0
  31. package/src/resources/slayer/tasks/DuradelTasks.ts +75 -0
  32. package/src/resources/slayer/tasks/KonarTasks.ts +6 -0
  33. package/src/resources/slayer/tasks/MazchnaTasks.ts +5 -0
  34. package/src/resources/slayer/tasks/NieveTasks.ts +235 -0
  35. package/src/resources/slayer/tasks/ReadTasks.ts +55 -0
  36. package/src/resources/slayer/tasks/SpriaTasks.ts +344 -0
  37. package/src/resources/slayer/tasks/Tureal.ts +436 -0
  38. package/src/resources/slayer/tasks/VannakaTasks.ts +236 -0
  39. package/src/resources/slayer/tasks/json/Chaeldar.json +348 -0
  40. package/src/resources/slayer/tasks/json/Duradel.json +541 -0
  41. package/src/resources/slayer/tasks/json/Krystilia.json +2 -0
  42. package/src/resources/slayer/tasks/json/Mazchna.json +379 -0
  43. package/src/resources/slayer/tasks/json/Neive.json +320 -0
  44. package/src/resources/slayer/tasks/json/Spria.json +345 -0
  45. package/src/resources/slayer/tasks/json/Tureal.json +341 -0
  46. package/src/resources/slayer/tasks/json/Vannaka.json +547 -0
  47. package/src/cli.js +0 -9
  48. package/src/data/farming/fruitTrees.json +0 -165
  49. package/src/data/farming/locations.json +0 -78
  50. package/src/data/farming/patches.json +0 -102
  51. package/src/data/farming/seeds.json +0 -170
  52. package/src/data/farming/teleports.json +0 -301
  53. package/src/data/farming/treePatches.json +0 -3
  54. package/src/data/farming/trees.json +0 -103
  55. package/src/data/quest/miniquestQuestArray.ts +0 -8
  56. package/src/data/quest/questDataArray.ts +0 -4134
  57. package/src/data/quest/subQuestArray.ts +0 -60
  58. package/src/tests/QuestTest.js +0 -71
  59. package/src/tests/getAllQuestSeries.ts +0 -6
  60. package/src/tests/test Quest Array.ts +0 -9
  61. package/src/tests/test Requirements.ts +0 -56
  62. package/src/tests/test.ts +0 -402
  63. package/src/tests/test3.js +0 -370
  64. package/src/tests/testQuestCompletion.js +0 -367
  65. package/src/tests/testSeed.js +0 -8
  66. package/src/utils/AchievementDiary.ts +0 -18
  67. package/src/utils/Farming/FarmingTool.ts +0 -110
  68. package/src/utils/Farming/Seed.js +0 -42
  69. package/src/utils/Farming/TreeSeed.js +0 -21
  70. package/src/utils/OsrsAccount.ts +0 -280
  71. package/src/utils/Quest.ts +0 -99
  72. package/src/utils/QuestTool.ts +0 -437
  73. package/src/utils/Requirement.ts +0 -63
  74. package/src/utils/Skill.ts +0 -11
  75. /package/src/{data/Diaries → resources/quest}/diariesArray.json +0 -0
  76. /package/src/{data → resources/quest}/exp.json +0 -0
@@ -0,0 +1,44 @@
1
+
2
+
3
+ // SkillRequirement interface
4
+ interface SkillRequirement {
5
+ level: number; // Required skill level
6
+ isBoostable: boolean; // Flag to indicate if the skill is boostable
7
+ }
8
+
9
+
10
+ // Quest interface
11
+ interface Quest {
12
+ id: number; // Unique identifier
13
+ name: string; // Quest name
14
+ difficulty: string; // Difficulty level
15
+ skillRequirements: { [skill: string]: SkillRequirement }; // Skill level requirements with boostable flag
16
+ status: 'Not Started' | 'In Progress' | 'Completed'; // Quest status
17
+ miniquest: boolean; // Is this a miniquest?
18
+ shortName: string; // Short name for the quest
19
+ url: string; // URL to the quest guide
20
+ series: string; // Series of the quest (e.g. 'Elf', 'Mahjarrat')
21
+ members: boolean; // Is this a members-only quest?
22
+ questPoints: number; // Quest points rewarded
23
+ length: string; // Length of the quest
24
+ age: string; // Age of the quest
25
+ startLocation: string; // Starting location
26
+ difficultyLevel: string; // Difficulty level
27
+ officialDifficulty: string; // Official difficulty level
28
+ officialLength: string; // Official length
29
+ officialAge: string; // Official age
30
+ itemRequirements: string[]; // Item requirements
31
+ recommendedItems: string[]; // Recommended items
32
+ recommendedSkills: { [skill: string]: number }; // Recommended skills
33
+ recommendedPrayers: string[]; // Recommended prayers
34
+ questRequirements: string[]; // Names of quests that need to be completed before
35
+ rewards: {
36
+ experience?: { [skill: string]: number }; // Experience rewards per skill
37
+ items?: string[]; // List of items rewarded
38
+ areas?: string[]; // List of items rewarded
39
+ };
40
+ }
41
+
42
+
43
+
44
+ export { Quest };
@@ -0,0 +1,96 @@
1
+ import { OsrsAccount } from '../account/OsrsAccount';
2
+ import { Quest } from './Quest';
3
+
4
+ class QuestTool {
5
+ private questObject: any;
6
+ private questArray: any;
7
+ private subQuestArray: any;
8
+ private osrsAccount: OsrsAccount | undefined;
9
+
10
+ constructor() {
11
+ // todo need to import these data from a typescript file where its defined/stored
12
+ this.questObject = [];
13
+ this.questArray = [];
14
+ this.subQuestArray = [];
15
+ }
16
+
17
+ /**
18
+ * to string func
19
+ * @todo Implement this function
20
+ * @return {String} The string representation of the class object.
21
+ */
22
+ toString(): string {
23
+ return 'QuestTool :) WIP';
24
+ }
25
+
26
+ /**
27
+ * Get the data for a quest
28
+ * @param {String} questName The name of the quest
29
+ * @return {Object} The data for the input quest in a JSON object.
30
+ * */
31
+ getQuest(questName: string): Quest | undefined {
32
+ if (typeof questName === 'string' && this.questObject[questName]) {
33
+ // return new Quest(this.questObject[questName]); TODO
34
+ }
35
+ return undefined;
36
+ }
37
+
38
+ /**
39
+ * Get the data for a quest
40
+ * @param {String} questName The name of the quest
41
+ * @return {Object} The data for the input quest in a JSON object.
42
+ * */
43
+ getQuestByName(questName: string): Quest | undefined {
44
+ return this.getQuest(questName);
45
+ }
46
+
47
+ /**
48
+ * Get the data for a quest
49
+ * @param {String} subQuestName The name of the subquest
50
+ * @return {Object} The data for the input subquest in a JSON object.
51
+ * */
52
+ getSubQuest(subQuestName: string): any | undefined {
53
+ return this.subQuestArray.find((x: any) => x.name === subQuestName);
54
+ }
55
+
56
+ // Define highestBoost method, switch case omitted for brevity
57
+
58
+ /**
59
+ * Add two numbers together
60
+ * @todo Need to implement Recipe for disaster functionality
61
+ * @param {String} quest The either string or quest object of the quest to be determined completeable or not.
62
+ * @return {Boolean} If the account currently tied to the tool can complete the quest.
63
+ * */
64
+ canCompleteQuest(quest: string | Quest | undefined): boolean {
65
+ // Implementation omitted for brevity
66
+ return true; // Placeholder return value
67
+ }
68
+
69
+ // Define completableQuests method, implementation omitted for brevity
70
+
71
+ /**
72
+ * Set the account to be used in this quest tool
73
+ * @param {OsrsAccount} acc1 The osrs Account to be associated with this class object.
74
+ * */
75
+ setOsrsAccount(acc1: OsrsAccount): boolean {
76
+ if (acc1) {
77
+ // this.osrsAccount = new OsrsAccount(acc1); TODO
78
+ return true;
79
+ }
80
+ return false;
81
+ }
82
+
83
+ // Define other methods, implementation omitted for brevity
84
+
85
+ /**
86
+ * Get the osrs account associated with this quest tool
87
+ * @return {OsrsAccount | undefined} The osrs Account associated with this class object.
88
+ * */
89
+ getOsrsAccount(): OsrsAccount | undefined {
90
+ return this.osrsAccount;
91
+ }
92
+
93
+ // Define other getters, implementation omitted for brevity
94
+ }
95
+
96
+ export { QuestTool };
@@ -0,0 +1,40 @@
1
+ import { Requirement } from '../Requirement';
2
+ import { Task } from './Task';
3
+
4
+ // A Class that represents an assignment of a task to a player.
5
+ // An assignment is a specific instance of a task, with a specific quantity and requirements.
6
+ // The assignment is the actual task given to a player, which is based on the Task.
7
+ export class Assignment {
8
+ name: string;
9
+ quantity: number;
10
+ requirements: Requirement[];
11
+ extendedAmountMin?: number | null;
12
+ extendedAmountMax?: number | null;
13
+
14
+ constructor(
15
+ name: string,
16
+ quantity: number,
17
+ requirements: Requirement[],
18
+ extendedAmountMin?: number | null,
19
+ extendedAmountMax?: number | null
20
+ ) {
21
+ this.name = name;
22
+ this.quantity = quantity;
23
+ this.requirements = requirements;
24
+ this.extendedAmountMin = extendedAmountMin ?? null;
25
+ this.extendedAmountMax = extendedAmountMax ?? null;
26
+ }
27
+ /**
28
+ * Get the task name
29
+ */
30
+ getName(): string {
31
+ return this.name;
32
+ }
33
+
34
+ /**
35
+ * Get the quantity of the task
36
+ */
37
+ getQuantity(): number {
38
+ return this.quantity;
39
+ }
40
+ }
@@ -0,0 +1,137 @@
1
+ import { Assignment } from './Assignment';
2
+ import { Task } from './Task';
3
+
4
+ /**
5
+ * SlayerMaster class represents a Slayer Master in the game.
6
+ * It encapsulates the properties and methods related to a Slayer Master,
7
+ * including the tasks they assign, their location, level requirements,
8
+ * and the ability to generate random assignments.
9
+ * Reference: https://oldschool.runescape.wiki/w/Duradel
10
+ *
11
+ */
12
+ class SlayerMaster {
13
+ name: string; // Name of the Slayer Master
14
+ totalWeight: number; // Total weight of the tasks assigned to this Slayer Master. This is used to determine the likelihood of each task being assigned.
15
+ location: string = ''; // Location of the Slayer Master (optional, can be set later if needed)
16
+ minimumCombatLevel: number = 0; // Level requirement to access this Slayer Master (optional, can be set later if needed)
17
+ tasks: Task[]; // Array of tasks assigned to this Slayer Master. This holds the actual tasks that players can be assigned to kill.
18
+ wikiUrl: string = ''; // URL for the Slayer Master (optional, can be set later if needed)
19
+ taskPoints: Record<number, number>; // Mapping of task intervals to points
20
+ eliteDiaryTaskPoints?: Record<number, number>; // Mapping of task intervals to points
21
+
22
+ // Constructor for the SlayerMaster class
23
+ constructor(
24
+ name: string,
25
+ tasks: Task[],
26
+ location: string,
27
+ levelRequirement: number,
28
+ url: string,
29
+ taskPoints: Record<number, number>, // Pass the task points mapping in the constructor
30
+ eliteDiaryTaskPoints?: Record<number, number> // Optional mapping for elite diary task points
31
+ ) {
32
+ this.name = name;
33
+ this.tasks = tasks; // Array of tasks assigned to this Slayer Master
34
+ this.tasks.forEach((task) => {
35
+ task.weight = task.weight || 0; // Default weight to 0 if not provided
36
+ }); // Initialize the tasks array
37
+ this.totalWeight = this.calculateTotalWeight(); // Calculate the total weight of the tasks
38
+ this.location = location; // Default to an empty string if not provided
39
+ this.minimumCombatLevel = levelRequirement; // Default to 0 if not provided
40
+ this.wikiUrl = url; // Default to an empty string if not provided
41
+ this.taskPoints = taskPoints; // Initialize the task points mapping
42
+ this.eliteDiaryTaskPoints = eliteDiaryTaskPoints; // Optional mapping for elite diary task points
43
+ }
44
+
45
+ /**
46
+ * Calculate the total weight of all tasks assigned to this Slayer Master.
47
+ * @returns {number} The total weight of all tasks assigned to this Slayer Master.
48
+ */
49
+ calculateTotalWeight(): number {
50
+ if (this.tasks.length === 0) return 0; // Return 0 if there are no tasks
51
+ return this.tasks.reduce((total, task) => {
52
+ return total + (task.weight || 0); // Sum up the weights of all tasks
53
+ }, 0);
54
+ throw new Error('Method not implemented.');
55
+ }
56
+
57
+ /**
58
+ * Get the points awarded for completing a task based on the interval.
59
+ * @param {number} taskInterval - The interval of the task (e.g., 1 for every task, 10 for every 10th task, etc.).
60
+ * @returns {number} The points awarded for the given task interval.
61
+ */
62
+ getPointsForTaskInterval(taskInterval: number): number {
63
+ return this.taskPoints[taskInterval] || 0; // Return the points for the interval or 0 if not defined
64
+ }
65
+
66
+ /**
67
+ * Get the location of the Slayer Master
68
+ */
69
+ getLocation(): string {
70
+ return this.location;
71
+ }
72
+
73
+ /**
74
+ * Get the minimum combat level of the Slayer Master
75
+ */
76
+ getMinimumCombatLevel(): number {
77
+ return this.minimumCombatLevel;
78
+ }
79
+
80
+ /**
81
+ * Get the wiki URL of the Slayer Master
82
+ */
83
+ getWikiUrl(): string {
84
+ return this.wikiUrl;
85
+ }
86
+
87
+ /**
88
+ * Get a random task based on the weighting system of the tasks.
89
+ * Tasks with higher weights have a higher chance of being selected.
90
+ * @returns {Task | null} A randomly selected task or null if no tasks are available.
91
+ */
92
+ getRandomTask(): Task | null {
93
+ if (this.tasks.length === 0) return null; // Return null if there are no tasks
94
+
95
+ const randomWeight = Math.random() * this.totalWeight; // Generate a random number between 0 and totalWeight
96
+ let cumulativeWeight = 0;
97
+
98
+ for (const task of this.tasks) {
99
+ cumulativeWeight += task.weight || 0; // Add the task's weight to the cumulative weight
100
+ if (randomWeight <= cumulativeWeight) {
101
+ return task; // Return the task if the random weight falls within its range
102
+ }
103
+ }
104
+
105
+ return null; // Fallback in case no task is selected (shouldn't happen if weights are correct)
106
+ }
107
+
108
+ /**
109
+ * Get the total weight of tasks
110
+ */
111
+ getTotalWeight(): number {
112
+ return this.totalWeight;
113
+ }
114
+
115
+ /**
116
+ * Get Name of Slayer Master
117
+ */
118
+ getName(): string {
119
+ return this.name;
120
+ }
121
+
122
+ /**
123
+ * Get Tasks
124
+ */
125
+ getTasks(): Task[] {
126
+ return this.tasks;
127
+ }
128
+
129
+ /**
130
+ * toString function
131
+ */
132
+ toString(): string {
133
+ return `SlayerMaster :) WIP SlayerMaster:{\nname: ${this.name}\n}`;
134
+ }
135
+ }
136
+
137
+ export { SlayerMaster };
@@ -0,0 +1,39 @@
1
+ class SlayerUnlock {
2
+ name: string;
3
+ cost: number;
4
+ description: string;
5
+
6
+ constructor({ name, cost, description }: { name: string; cost: number; description: string }) {
7
+ this.name = name;
8
+ this.cost = cost;
9
+ this.description = description;
10
+ }
11
+ }
12
+
13
+ class SlayerExtend {
14
+ name: string;
15
+ cost: number;
16
+ notes: string;
17
+
18
+ constructor({ name, cost, notes }: { name: string; cost: number; notes: string }) {
19
+ this.name = name;
20
+ this.cost = cost;
21
+ this.notes = notes;
22
+ }
23
+ }
24
+
25
+ class SlayerBuy {
26
+ item: string;
27
+ priceSoldAt: number;
28
+ notes: string;
29
+
30
+ constructor({ item, priceSoldAt, notes }: { item: string; priceSoldAt: number; notes: string }) {
31
+ this.item = item;
32
+ this.priceSoldAt = priceSoldAt;
33
+ this.notes = notes;
34
+ }
35
+ }
36
+
37
+ class SlayerReward { }
38
+
39
+ export { SlayerUnlock, SlayerReward, SlayerExtend, SlayerBuy };
@@ -0,0 +1,168 @@
1
+ import { Requirement } from '../Requirement';
2
+
3
+ /**
4
+ * Represents a Slayer task in the game. This class encapsulates all the properties and methods related to a Slayer task.
5
+ * A Slayer task defines the monsters that players can be assigned to kill, the amount of those monsters, and various other attributes.
6
+ * A Task is not an assignment, but rather a template for an assignment.
7
+ * The assignment is the actual task given to a player, which is based on the Task.
8
+ */
9
+ class Task {
10
+ name: string; // Name of the task
11
+ weight: number; // Weight of the task, used to determine the likelihood of being assigned this task
12
+ amountMin: number; // Minimum amount of monsters to kill for this task
13
+ amountMax: number; // Maximum amount of monsters to kill for this task
14
+ requirements: Requirement[]; // Array of requirements for this task
15
+ extendedAmountMin?: number | null; // Minimum amount for extended tasks (optional)
16
+ extendedAmountMax?: number | null; // Maximum amount for extended tasks (optional)
17
+ alternatives?: any[] | null; // Array of alternatives for this task (optional)
18
+ CombatLevels: number[]; // Array of combat levels for this task
19
+ SlayerExp: number; // Slayer experience gained from this task
20
+ locations: string[]; // Array of locations where this task can be found
21
+ WildernessLevels: number[]; // Array of wilderness levels for this task
22
+ bosses: string[]; // Array of bosses for this task
23
+
24
+ /**
25
+ * Constructor for the Task class.
26
+ * @param name - Name of the task
27
+ * @param amountMin - Minimum amount of monsters to kill for this task
28
+ * @param amountMax - Maximum amount of monsters to kill for this task
29
+ * @param requirements - Array of requirements for this task
30
+ * @param extendedAmountMin - Minimum amount for extended tasks (optional)
31
+ * @param extendedAmountMax - Maximum amount for extended tasks (optional)
32
+ * @param weight - Weight of the task (default is 1)
33
+ * @param alternatives - Array of alternatives for this task (optional)
34
+ * @param CombatLevels - Array of combat levels for this task
35
+ * @param SlayerExp - Slayer experience gained from this task
36
+ * @param locations - Array of locations where this task can be found
37
+ * @param WildernessLevels - Array of wilderness levels for this task
38
+ * @param bosses - Array of bosses for this task
39
+ */
40
+ constructor(
41
+ name: string,
42
+ amountMin: number,
43
+ amountMax: number,
44
+ requirements: Requirement[],
45
+ extendedAmountMin?: number | null,
46
+ extendedAmountMax?: number | null,
47
+ alternatives: string[] = [],
48
+ weight: number = 1,
49
+ CombatLevels: number[] = [],
50
+ SlayerExp: number = 0,
51
+ locations: string[] = [],
52
+ WildernessLevels: number[] = [],
53
+ bosses: string[] = []
54
+ ) {
55
+ this.name = name;
56
+ this.weight = weight;
57
+ this.amountMin = amountMin;
58
+ this.amountMax = amountMax;
59
+ this.requirements = requirements;
60
+ this.extendedAmountMin = extendedAmountMin ?? null;
61
+ this.extendedAmountMax = extendedAmountMax ?? null;
62
+ this.alternatives = alternatives ?? [];
63
+ this.CombatLevels = CombatLevels;
64
+ this.SlayerExp = SlayerExp;
65
+ this.locations = locations;
66
+ this.WildernessLevels = WildernessLevels;
67
+ this.bosses = bosses;
68
+ }
69
+
70
+ static fromJSON(json: any): Task {
71
+ return new Task(
72
+ json.name,
73
+ json.amountMin,
74
+ json.amountMax,
75
+ json.extendedAmountMin,
76
+ json.extendedAmountMax,
77
+ json.requirements,
78
+ json.alternatives,
79
+ json.weight,
80
+ json.CombatLevels,
81
+ json.SlayerExp,
82
+ json.locations,
83
+ json.WildernessLevels,
84
+ json.bosses
85
+ );
86
+ }
87
+
88
+ /**
89
+ * Get the name of the task.
90
+ * @example
91
+ * const task = new Task("Goblin", 10, 20, [], 0, null, [], 1);
92
+ * console.log(task.getName()); // "Goblin"
93
+ * @returns
94
+ */
95
+ getName(): string {
96
+ return this.name;
97
+ }
98
+
99
+ /**
100
+ * Get the weight of the task. The weight is used to determine the likelihood of being assigned this task compared to others.
101
+ * @returns {number} The weight of the task, which can be used to determine the likelihood of being assigned this task compared to others.
102
+ */
103
+ getWeight(): number {
104
+ return this.weight;
105
+ }
106
+
107
+ /**
108
+ * Get the minimum and maximum amount of monsters to kill for this task.
109
+ * The amountMin and amountMax properties define the range of monsters that can be assigned for this task.
110
+ * @returns {number} The minimum amount of monsters to kill for this task.
111
+ */
112
+ getAmountMin(): number {
113
+ return this.amountMin;
114
+ }
115
+
116
+ /**
117
+ * Get the maximum amount of monsters to kill for this task.
118
+ * @returns {number} The maximum amount of monsters to kill for this task.
119
+ */
120
+ getAmountMax(): number {
121
+ return this.amountMax;
122
+ }
123
+
124
+ /**
125
+ *
126
+ */
127
+ getRequirements(): Requirement[] {
128
+ return this.requirements;
129
+ }
130
+
131
+ /**
132
+ *
133
+ * @returns {any[]} An array of alternatives for this task. If alternatives are defined as an object, it flattens the values into a single array.
134
+ */
135
+ getAlternatives(): any[] {
136
+ return this.alternatives
137
+ ? Array.isArray(this.alternatives)
138
+ ? this.alternatives
139
+ : Object.values(this.alternatives).flat()
140
+ : [];
141
+ }
142
+
143
+ /**
144
+ *
145
+ * @returns
146
+ */
147
+ toJSON(): any {
148
+ return {
149
+ name: this.name,
150
+ weight: this.weight,
151
+ amountMin: this.amountMin,
152
+ amountMax: this.amountMax,
153
+ unlockRequirements: this.requirements,
154
+ alternatives: this.alternatives,
155
+ };
156
+ }
157
+
158
+ /**
159
+ * Returns a string representation of the Task object.
160
+ * This method is useful for debugging and logging purposes, providing a quick overview of the task's name and other properties.
161
+ * @returns {string} A string representation of the Task object, useful for debugging and logging purposes.
162
+ */
163
+ toString(): string {
164
+ return `Task{ name: ${this.name} }`;
165
+ }
166
+ }
167
+
168
+ export { Task };