RSG如何使用内置提示?

显示提示

在 RSG 中显示本机提示系统的函数

exports['rsg-core']:createPrompt(
    v.location,  -- The location identifier for the prompt
    v.coords,    -- The coordinates where the prompt will appear
    RSGCore.Shared.Keybinds[Config.KeyShop],  -- The keybind for interaction
    Lang:t('menu.open') .. v.name,  -- The message displayed to the player
    {
        type = 'client',  -- Type of the prompt
        event = 'SOME EVENT HERE',  -- Event triggered on interaction
        args = {},  -- Additional arguments for the event
    }
)

删除提示

  • createdEntries[i].handle:这将检索要从表中删除的特定提示的句柄,其中 是条目的索引。createdEntriesi
exports['rsg-core']:deletePrompt(createdEntries[i].handle)
温馨提示: 本文最后更新于2025-05-21 20:57:05,某些文章具有时效性,若有错误或已失效,请在下方留言或联系RedM新手社区
本站代码模板仅供学习交流使用请勿商业运营,严禁从事违法,侵权等任何非法活动,否则后果自负!
THE END
喜欢就支持一下吧
点赞11 分享
评论 共1条

请登录后发表评论