Custom framework
Connect a custom framework by implementing the required server-side exports inside the resource.
Integration notes
Custom framework mode
Add the export functions below when Aquiver.Config.Framework is set to CUSTOM.
Developer setup
This integration is intended for developers who are familiar with their custom framework.
Exports
Configuration
Required server-side exports
Implement these functions through the custom framework integration.
Server-side export functions
globalThis.exports[GetCurrentResourceName()].addItem(this.source, item, amount);
globalThis.exports[GetCurrentResourceName()].removeItem(this.source, item, amount);
return globalThis.exports[GetCurrentResourceName()].getItemAmount(this.source, item) ?? 0;
return globalThis.exports[GetCurrentResourceName()].getItem(this.source, item);
return globalThis.exports[GetCurrentResourceName()].getAccountMoney(this.source, accountType) ?? 0;
globalThis.exports[GetCurrentResourceName()].addAccountMoney(this.source, accountType, amount);
globalThis.exports[GetCurrentResourceName()].setAccountMoney(this.source, accountType, amount);
return globalThis.exports[GetCurrentResourceName()].getRoleplayName(this.source) ?? 'UNDEFINED_NAME';
return globalThis.exports[GetCurrentResourceName()].getIdentifier(this.source) ?? '';
return globalThis.exports[GetCurrentResourceName()].hasPermission(this.source) ?? false;
globalThis.exports[GetCurrentResourceName()].notification(this.source, message);
Export setup example
Integration notes
Resource location
Define the exports inside the resource that contains the Aquiver Module because they are called through GetCurrentResourceName().
Example only
The functions below demonstrate the setup pattern and are not ready-to-use implementations.
Configuration
Lua export example
Expose a custom framework permission check through the current resource.
Lua export example
exports('hasPermission', function(source, permissionGroup)
local Player = Myframework.getter.player(source)
return Player.hasGroup(permissionGroup)
end)