From 695ff715779bf490220bd1825140d13314428ab9 Mon Sep 17 00:00:00 2001 From: Dan Date: Fri, 26 Feb 2021 20:07:50 +0000 Subject: [PATCH] docs: sv/cl_sync.lua headers --- cl_sync.lua | 8 +++++++- sv_sync.lua | 3 +++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/cl_sync.lua b/cl_sync.lua index 4bd1bf1..833e799 100644 --- a/cl_sync.lua +++ b/cl_sync.lua @@ -32,6 +32,10 @@ SYNC = {} + +--[[---------------------------------------------------------------------------------- + Sync functions +----------------------------------------------------------------------------------]]-- function SYNC:SendPowerState( state ) local otherPed = PLY:GetOtherPed() @@ -43,7 +47,9 @@ function SYNC:SendPowerState( state ) end - +--[[---------------------------------------------------------------------------------- + Sync client events +----------------------------------------------------------------------------------]]-- RegisterNetEvent( "wk_wars2x_sync:receivePowerState" ) AddEventHandler( "wk_wars2x_sync:receivePowerState", function( state ) local power = RADAR:IsPowerOn() diff --git a/sv_sync.lua b/sv_sync.lua index ca0586f..0b672d2 100644 --- a/sv_sync.lua +++ b/sv_sync.lua @@ -30,6 +30,9 @@ ---------------------------------------------------------------------------------------]]-- +--[[---------------------------------------------------------------------------------- + Sync server events +----------------------------------------------------------------------------------]]-- RegisterNetEvent( "wk_wars2x_sync:sendPowerState" ) AddEventHandler( "wk_wars2x_sync:sendPowerState", function( target, state ) TriggerClientEvent( "wk_wars2x_sync:receivePowerState", target, state )