Skip to content

Commit

Permalink
fix a few issues
Browse files Browse the repository at this point in the history
  • Loading branch information
nwjgit committed Mar 2, 2024
1 parent 40334c2 commit ade3c22
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 12 deletions.
9 changes: 1 addition & 8 deletions src/mahoji/commands/chop.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,6 @@ export const chopCommand: OSBMahojiCommand = {
name: 'twitchers_gloves',
description: "Change the settings of your Twitcher's gloves. (default egg nests)",
required: false,
// choices: ['egg', 'ring', 'seed', 'clue'].map(i => ({ name: i, value: i }))
choices: [
{ name: 'Egg nest (Default)', value: 'egg' },
{ name: 'Ring nest', value: 'ring' },
Expand Down Expand Up @@ -141,12 +140,6 @@ export const chopCommand: OSBMahojiCommand = {
return `${user.minionName} needs ${log.qpRequired} QP to cut ${log.name}.`;
}

if (user.hasEquipped("twitcher's gloves") && twitchers_gloves === undefined) {
twitchers_gloves = 'egg';
} else if (!user.hasEquipped("twitcher's gloves")) {
twitchers_gloves = undefined;
}

const boosts = [];

let wcLvl = skills.woodcutting;
Expand Down Expand Up @@ -217,7 +210,7 @@ export const chopCommand: OSBMahojiCommand = {
quantity: newQuantity,
iQty: options.quantity ? options.quantity : undefined,
powerchopping: powerchop,
twitchers: twitchers_gloves!,
twitchers: twitchers_gloves || 'egg',
duration,
fakeDurationMin,
fakeDurationMax,
Expand Down
9 changes: 5 additions & 4 deletions src/tasks/minions/woodcuttingActivity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ import resolveItems from '../../lib/util/resolveItems';
async function handleForestry({ user, log, duration, loot }: { user: MUser; log: Log; duration: number; loot: Bank }) {
if (resolveItems(['Redwood logs', 'Logs']).includes(log.id)) return '';

let [case1, case2, case3, case4, case5, case6, case7, case8, case9, totalEvents, eggsDelivered] = [
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
let [case1, case2, case3, case4, case5, case6, case7, case8, case9, totalEvents, eggsDelivered, totalEggs] = [
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
];
let strForestry = '';
let defaultAmount = randInt(400, 600);
Expand Down Expand Up @@ -84,6 +84,7 @@ async function handleForestry({ user, log, duration, loot }: { user: MUser; log:
loot.add('Golden pheasant egg', 1);
}
i++;
totalEggs++;
}
break;
}
Expand All @@ -104,7 +105,7 @@ async function handleForestry({ user, log, duration, loot }: { user: MUser; log:
event: 'Pheasant Control',
value: case9,
uniqueXP: SkillsEnum.Thieving,
amount: eggsDelivered * 100
amount: totalEggs * 100
}
];
events.forEach(eventObj => (totalEvents += eventObj.value));
Expand Down Expand Up @@ -231,7 +232,7 @@ export const woodcuttingTask: MinionTask = {
}
}

// Add clue scrolls
// Add clue scrolls & nests
if (log.clueScrollChance) {
addSkillingClueToLoot(
user,
Expand Down

0 comments on commit ade3c22

Please sign in to comment.