Skip to content

Commit

Permalink
🏷️ Update types to be updated with what's in JavaScript (#3287)
Browse files Browse the repository at this point in the history
  • Loading branch information
fantomitechno committed Jan 25, 2024
1 parent ba53a95 commit 210785e
Showing 1 changed file with 22 additions and 19 deletions.
41 changes: 22 additions & 19 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -779,7 +779,7 @@ export class ScoreBoard {

setTitle (title: string): void;

add (name: string, value: number, displayName: ChatMessage): ScoreBoardItem;
add(name: string, value: number): ScoreBoardItem;

remove (name: string): ScoreBoardItem;
}
Expand All @@ -791,15 +791,18 @@ export interface ScoreBoardItem {
}

export class Team {
team: string
name: ChatMessage
friendlyFire: number
nameTagVisibility: string
collisionRule: string
color: string
prefix: ChatMessage
suffix: ChatMessage
memberMap: { [name: string]: '' }
members: string[]

constructor (packet: object);
constructor(team: string, name: string, friendlyFire: boolean, nameTagVisibility: string, collisionRule: string, formatting: number, prefix: string, suffix: string);

parseMessage (value: string): ChatMessage;

Expand Down Expand Up @@ -841,6 +844,7 @@ export class BossBar {
color: 'pink' | 'blue' | 'red' | 'green' | 'yellow' | 'purple' | 'white'
shouldDarkenSky: boolean
isDragonBar: boolean
createFog: boolean
shouldCreateFog: boolean

constructor (
Expand All @@ -854,23 +858,22 @@ export class BossBar {
}

export class Particle {
id: number
name: string
position: Vec3
offset: Vec3
count: number
movementSpeed: number
longDistanceRender: boolean
static fromNetwork(packet: Object): Particle

constructor (
id: number,
position: Vec3,
offset: Vec3,
count?: number,
movementSpeed?: number,
longDistanceRender?: boolean
);
id: number
position: Vec3
offset: Vec3
count: number
movementSpeed: number
longDistanceRender: boolean
static fromNetwork(packet: Object): Particle

constructor(
id: number,
position: Vec3,
offset: Vec3,
count?: number,
movementSpeed?: number,
longDistanceRender?: boolean
);
}

export let testedVersions: string[]
Expand Down

0 comments on commit 210785e

Please sign in to comment.