所以我买了这个脚本,但我似乎找不到任何支持...所以 Imma 需要一些帮助。作为参考,此脚本在某人键入时在他们头顶播放“打字”Gif
RegisterCommand("chatbox", function(source, args, rawCommand)
chatbox = tonumber(args[1])
if chatbox == 1 then
TriggerClientEvent('chatbox:ToggleDisplay', -1, source, 1, "chatbox")
elseif chatbox == 2 then
TriggerClientEvent('chatbox:ToggleDisplay', -1, source, 3, "chatbox")
elseif chatbox == 3 then
TriggerClientEvent('chatbox:ToggleDisplay', -1, source, 2, "chatbox")
end
end, false)
这是给我 ClientEvent 错误的代码。
if chatInputActivating then
if not IsControlPressed(0, 245) then
ExecuteCommand("chatbox 1") -- chatbox 1-3 which one you wanna use
SetNuiFocus(true)
chatInputActivating = false
end
end
这是在输入聊天时激活它的代码(放在 incl_chat.lua
中resources/gameplay/chat/
)