4,687
edits
(Updated all functions on the page; Bumped version to 1.3; All Relics function will now add relics for all realms instead of just Melvor) |
m (→Examples: Swapped one of the examples to abyssal realm) |
||
Line 227: | Line 227: | ||
<syntaxhighlight lang="js"> | <syntaxhighlight lang="js"> | ||
game.woodcutting.addMasteryPoolXP(game.realms.getObjectByID('melvorD:Melvor'), 600); | game.woodcutting.addMasteryPoolXP(game.realms.getObjectByID('melvorD:Melvor'), 600); | ||
game.woodcutting.addMasteryPoolXP(game.realms.getObjectByID(' | game.woodcutting.addMasteryPoolXP(game.realms.getObjectByID('melvorItA:Abyssal'), -400); | ||
</syntaxhighlight> | </syntaxhighlight> | ||
The first line will result in 600 [[Mastery#The_Mastery_Pool|Mastery Pool]] XP being added to {{Skill|Woodcutting}} in the Melvor Realm whereas the second line will remove 400 mastery pool xp from Woodcutting. | The first line will result in 600 [[Mastery#The_Mastery_Pool|Mastery Pool]] XP being added to {{Skill|Woodcutting}} in the Melvor Realm whereas the second line will remove 400 mastery pool xp from Woodcutting in the abyssal realm. | ||
<syntaxhighlight lang="js">game.realms.forEach(realm => game.masterySkills.forEach(skill => skill.addMasteryPoolXP(realm, 1000)));</syntaxhighlight> | <syntaxhighlight lang="js">game.realms.forEach(realm => game.masterySkills.forEach(skill => skill.addMasteryPoolXP(realm, 1000)));</syntaxhighlight> |