@highlite/core
Version:
HighLite Client Core
55 lines (49 loc) • 2.66 kB
TypeScript
/*!
Copyright (C) 2025 HighLite
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { ActionState } from '../../interfaces/game/ActionStates.enum';
import { ContextMenuTypes } from '../../interfaces/game/ContextMenuTypes.enum';
export declare enum EntityType {
Any = -1,
WorldObject = 0,
GroundItem = 1,
NPC = 2,
Player = 3
}
export declare class ContextMenuManager {
private static instance;
defaultActions: {};
inventoryActions: {};
gameWorldActions: {};
gameWorldActionsSorting: {};
inventoryActionsSorting: {};
spellActions: {};
constructor();
AddDefaultMenuAction(actionName: string): number;
AddInventoryItemMenuAction(actionName: string, handleFunction: Function, actionState: ActionState | undefined, contextMenuType: ContextMenuTypes): number;
AddGameWorldMenuAction(actionName: string, handleFunction: Function, entityType?: EntityType): number;
RemoveGameWorldMenuAction(actionName: string, handleFunction: Function, entityType?: EntityType): boolean;
RemoveInventoryItemMenuAction(actionName: string, handleFunction: Function, actionState: ActionState | undefined, contextMenuType: ContextMenuTypes): boolean;
AddSpellMenuAction(actionName: string): number;
inventoryContextHook(inputArguments: any, actions: any, aG: any): any;
gameWorldContextHook(e: any, i: any, vG: any): any;
inventoryActionHandler(contextType: any, actionState: any, e: any, i: any): void;
worldObjectActionHandler(entityType: any, e: any, i: any): void;
SetGameWorldActionMenuPosition(actionName: string, position: number): void;
RemoveGameWorldActionMenuPosition(actionName: string): void;
SetInventoryActionMenuPosition(actionName: string, position: number): void;
RemoveInventoryActionMenuPosition(actionName: string): void;
registerContextHook(sourceClass: string, fnName: string, hookFn: Function): boolean;
registerStaticContextHook(sourceClass: string, fnName: string, hookFn?: FunctionConstructor): boolean;
ActionSorting(e: any, t: any, i: any, j: any, dG: any): void;
}