Skip to content

Installation

安装

依赖项

在安装之前,请确保服务器上已存在并启动了 ox_lib。这是一个强依赖项。

步骤

  1. bupa-animpos 文件夹放入你的 resources 目录中(例如 resources/[bupa]/bupa-animpos)。
  2. server.cfg 中确保该资源在 ox_lib 之后启动。
  3. 根据你的服务器在 config.lua 中设置 Config.Framework
  4. (可选)如果你使用 Config.Permission.Type = 'ace',请配置 ACE 权限。
  5. 使用 ox:locale convar 设置你的语言。
  6. 重启服务器。

server.cfg — 启动顺序

ox_lib 必须在 BUPA AnimPos 之前启动。

server.cfg
ensure ox_lib
ensure bupa-animpos

框架

打开 config.lua 并设置框架值。这决定了加载哪个核心资源以及应用哪些元数据限制。

config.lua
Config.Framework = 'qbox'   -- qbox / qbcore / esx / standalone

standaloneesx 下,框架元数据限制(死亡 / 垂死挣扎 / 手铐)将被跳过 —— 仅应用原生检查(载具 / 坠落 / 游泳)。

ACE 权限(仅当 Type = 'ace' 时)

如果你通过 Type = 'ace' 启用了权限,请将 Config.Permission.Ace 中定义的 ACE 对象(默认值为 animpos.use)授予应具有权限的主体。将该行添加到你的 server.cfg 或权限配置文件中。

server.cfg
# 允许整个用户组
add_ace group.admin animpos.use allow

# 或者允许特定的主体
add_ace identifier.license:xxxxxxxxxxxxxxxx animpos.use allow

语言

通过 ox:locale convar 全局设置活动语言。它必须是一个 setr(可同步)convar,以便客户端可以读取它。

server.cfg
setr ox:locale "tr"

可用代码:en, tr, de, fr, es, pt, ru。详见本地化页面。