-
Notifications
You must be signed in to change notification settings - Fork 133
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Since the removal of favour, users are unable to get the Shayzien armour that gives a boost to Lizardman Shamans. This pr copies how stronghold of security has been setup and adds the shayzien minigame to unlock the armour.
- Loading branch information
1 parent
4c58e31
commit 09f7191
Showing
8 changed files
with
100 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { Time } from 'e'; | ||
|
||
import type { ActivityTaskOptionsWithNoChanges } from '../../../lib/types/minions'; | ||
import { randomVariation } from '../../../lib/util'; | ||
import addSubTaskToActivityTask from '../../../lib/util/addSubTaskToActivityTask'; | ||
|
||
export async function combatRingCommand(user: MUser, channelID: string) { | ||
if (user.minionIsBusy) { | ||
return 'Your minion is busy.'; | ||
} | ||
|
||
await addSubTaskToActivityTask<ActivityTaskOptionsWithNoChanges>({ | ||
userID: user.id, | ||
channelID: channelID.toString(), | ||
duration: randomVariation(Time.Minute * 5, 5), | ||
type: 'CombatRing' | ||
}); | ||
|
||
return `${user.minionName} is now fighting in the Shayzien Combat Ring!`; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
import { Bank } from 'oldschooljs'; | ||
|
||
import { ActivityTaskOptionsWithNoChanges } from '../../lib/types/minions'; | ||
import { handleTripFinish } from '../../lib/util/handleTripFinish'; | ||
|
||
export const combatRingTask: MinionTask = { | ||
type: 'CombatRing', | ||
async run(data: ActivityTaskOptionsWithNoChanges) { | ||
const { channelID, userID } = data; | ||
const user = await mUserFetch(userID); | ||
|
||
const loot = new Bank({ | ||
'Shayzien boots (1)': 1, | ||
'Shayzien gloves (1)': 1, | ||
'Shayzien greaves (1)': 1, | ||
'Shayzien helm (1)': 1, | ||
'Shayzien platebody (1)': 1, | ||
'Shayzien boots (2)': 1, | ||
'Shayzien gloves (2)': 1, | ||
'Shayzien greaves (2)': 1, | ||
'Shayzien helm (2)': 1, | ||
'Shayzien platebody (2)': 1, | ||
'Shayzien boots (3)': 1, | ||
'Shayzien gloves (3)': 1, | ||
'Shayzien greaves (3)': 1, | ||
'Shayzien helm (3)': 1, | ||
'Shayzien platebody (3)': 1, | ||
'Shayzien boots (4)': 1, | ||
'Shayzien gloves (4)': 1, | ||
'Shayzien greaves (4)': 1, | ||
'Shayzien helm (4)': 1, | ||
'Shayzien platebody (4)': 1, | ||
'Shayzien boots (5)': 1, | ||
'Shayzien gloves (5)': 1, | ||
'Shayzien greaves (5)': 1, | ||
'Shayzien helm (5)': 1, | ||
'Shayzien body (5)': 1 | ||
}); | ||
|
||
await transactItems({ | ||
userID: user.id, | ||
collectionLog: true, | ||
itemsToAdd: loot | ||
}); | ||
|
||
handleTripFinish( | ||
user, | ||
channelID, | ||
`${user}, ${user.minionName} finished the Combat Ring, and received ${loot}.`, | ||
undefined, | ||
data, | ||
loot | ||
); | ||
} | ||
}; |