Skip to content

Commit

Permalink
fix: remove any from TS designations
Browse files Browse the repository at this point in the history
  • Loading branch information
marvin9257 committed Nov 7, 2024
1 parent 0ddfe1a commit a9b0920
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/module/entities/TwodsixItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -357,10 +357,10 @@ export default class TwodsixItem extends Item {
* A method to get the weapon fire mode parameters.
* @param {number} rateOfFireCE The rate of fire used
* @param {string} attackType The type of attack (e.g. burst, double-tap, etc.)
* @param {any} tmpSettings the temporary settings object for the roll
* @returns {any} { weaponType, isAutoFull, usedAmmo, numberOfAttacks }
* @param {object} tmpSettings the temporary settings object for the roll
* @returns {object} { weaponType, isAutoFull, usedAmmo, numberOfAttacks }
*/
private getFireModeParams( rateOfFireCE: number, attackType: string, tmpSettings: any): any {
private getFireModeParams( rateOfFireCE: number, attackType: string, tmpSettings: object): object {
const ruleSet = game.settings.get('twodsix', 'ruleset');
const weapon:Weapon = <Weapon>this.system;
let numberOfAttacks = 1;
Expand Down Expand Up @@ -430,9 +430,9 @@ export default class TwodsixItem extends Item {
* Valid for Classic Traveller and Cepheus Engine band types as well as other rule sets with range values.
* @param {number} range The measured distance to the target
* @param {string} weaponBand The type of weapon used - as key string
* @returns {any} {rangeModifier: rangeModifier, rollType: rollType}
* @returns {object} {rangeModifier: rangeModifier, rollType: rollType}
*/
public getRangeModifier(range:number, weaponBand: string, isAutoFull:boolean): any {
public getRangeModifier(range:number, weaponBand: string, isAutoFull:boolean): object {
let rangeModifier = 0;
let rollType = 'Normal';
const rangeModifierType = game.settings.get('twodsix', 'rangeModifierType');
Expand Down Expand Up @@ -497,7 +497,7 @@ export default class TwodsixItem extends Item {
/**
* A method to return ammo range modifier.
* @param {string} rangeModifierType The type of range modifier (setting)
* @returns {any} {dodgeParry: dodgeParryModifier, dodgeParryLabel: skillName}
* @returns {number} range modifier DM
*/
public getAmmoRangeModifier(rangeModifierType:string):number {
let returnValue = 1;
Expand All @@ -517,7 +517,7 @@ export default class TwodsixItem extends Item {
/**
* A method to get the dodge / parry modifer based on the target's corresponding skill used for attack.
* @param {Token} target The target token
* @returns {any} {dodgeParry: dodgeParryModifier, dodgeParryLabel: skillName}
* @returns {object} {dodgeParry: dodgeParryModifier, dodgeParryLabel: skillName}
*/
public getDodgeParryValues(target: Token): object {
let dodgeParryModifier = 0;
Expand Down Expand Up @@ -791,7 +791,7 @@ export default class TwodsixItem extends Item {
}
}

public async rollDamage(rollMode:DICE_ROLL_MODES, bonusDamage = "", showInChat = true, confirmFormula = false):Promise<any | void> {
public async rollDamage(rollMode:DICE_ROLL_MODES, bonusDamage = "", showInChat = true, confirmFormula = false):Promise<object | void> {
const weapon = <Weapon | Component>this.system;
const consumableDamage = this.getConsumableBonusDamage();
if (!weapon.damage && !consumableDamage) {
Expand Down Expand Up @@ -1173,7 +1173,7 @@ export default class TwodsixItem extends Item {
* @param {boolean} isAuto Is full automatic fire
* @returns {object} Object of range modifiers versus different range bands
*/
private getCustomRangeMod(isAuto:boolean):any {
private getCustomRangeMod(isAuto:boolean):object {
return {
close: parseCustomCTValue(this.system.customCT.range.close, isAuto),
short: parseCustomCTValue(this.system.customCT.range.short, isAuto),
Expand Down Expand Up @@ -1259,7 +1259,7 @@ export async function onRollDamage(event:Event):Promise<void> {
* @returns {object[]} The resulting simplified dice terms.
*/
export function getDiceResults(inputRoll:Roll) {
const returnValue:any[] = [];
const returnValue:object[] = [];
for (const die of inputRoll.dice) {
returnValue.push(die.results);
}
Expand Down

0 comments on commit a9b0920

Please sign in to comment.