Chat: small changes in comments

This commit is contained in:
bi 2018-06-06 17:33:33 +03:00
parent f16130838c
commit 7205b4eb13

View file

@ -1,6 +1,6 @@
local vmf = get_mod("VMF")
-- Constants, used as parameters in some 'chat_manager's functions
-- Constants used as parameters in some 'chat_manager's functions
local CHANNEL_ID = 1
local MESSAGE_SENDER = ""
local LOCALIZATION_PARAM = ""
@ -8,21 +8,21 @@ local IS_SYSTEM_MESSAGE = false
local POP_CHAT = true
local IS_DEV = true
-- ####################################################################################################################
-- ##### Local functions ##############################################################################################
-- ####################################################################################################################
-- #####################################################################################################################
-- ##### Local functions ###############################################################################################
-- #####################################################################################################################
local function send_system_message(peer_id, message)
RPC.rpc_chat_message(peer_id, CHANNEL_ID, MESSAGE_SENDER, message, LOCALIZATION_PARAM, IS_SYSTEM_MESSAGE, POP_CHAT,
IS_DEV)
end
-- ####################################################################################################################
-- ##### VMFMod #######################################################################################################
-- ####################################################################################################################
-- #####################################################################################################################
-- ##### VMFMod ########################################################################################################
-- #####################################################################################################################
--[[
Broadcasts the message to all players in the lobby.
Broadcasts the message to all players in a lobby.
* message [string]: message to broadcast
--]]
function VMFMod:chat_broadcast(message)
@ -47,8 +47,7 @@ function VMFMod:chat_broadcast(message)
end
--[[
Sends message only to 1 player. Only host can use this method. Because if message will be sent to host, it will be
broadcasted to all other players. That's how Fathshark's system works and there's no workaround for that.
Sends the message to a selected player. Only the host can use this method.
* peer_id [peer_id]: peer_id of the player who will recieve the message (can't be host's peer_id)
* message [string] : message to send
--]]