mirror of
https://github.com/CommunityOx/ox_lib.git
synced 2026-08-17 06:56:03 +01:00
feat(package): interface definitions
This commit is contained in:
54
package/client/resource/interface/progress.ts
Normal file
54
package/client/resource/interface/progress.ts
Normal file
@@ -0,0 +1,54 @@
|
||||
type Position = {
|
||||
x: number;
|
||||
y: number;
|
||||
z: number;
|
||||
};
|
||||
|
||||
interface PropProps {
|
||||
model: string;
|
||||
bone?: number;
|
||||
pos: Position;
|
||||
rot: Position;
|
||||
}
|
||||
|
||||
interface ProgressProps {
|
||||
duration: number;
|
||||
useWhileDead?: boolean;
|
||||
allowRagdoll?: boolean;
|
||||
allowCuffed?: boolean;
|
||||
allowFalling?: boolean;
|
||||
canCancel?: boolean;
|
||||
anim?: {
|
||||
dict?: string;
|
||||
clip: string;
|
||||
flag?: number;
|
||||
blendIn?: number;
|
||||
blendOut?: number;
|
||||
duration?: number;
|
||||
playbackRate?: number;
|
||||
lockX?: boolean;
|
||||
lockY?: boolean;
|
||||
lockZ?: boolean;
|
||||
scenario?: string;
|
||||
playEnter?: boolean;
|
||||
};
|
||||
prop?: PropProps | PropProps[];
|
||||
disable?: {
|
||||
move?: boolean;
|
||||
car?: boolean;
|
||||
combat?: boolean;
|
||||
mouse?: boolean;
|
||||
};
|
||||
}
|
||||
|
||||
interface ProgressbarProps extends ProgressProps {
|
||||
label: string;
|
||||
}
|
||||
|
||||
export const progressBar = async (data: ProgressbarProps): Promise<boolean> => exports.ox_lib.progressBar(data);
|
||||
|
||||
export const progressCircle = async (data: ProgressProps): Promise<boolean> => exports.ox_lib.progressCircle(data);
|
||||
|
||||
export const progressActive = (): boolean => exports.ox_lib.progressActive();
|
||||
|
||||
export const cancelProgress = (): void => exports.ox_lib.cancelProgress();
|
||||
Reference in New Issue
Block a user