Working MP :)
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
require ("TOC/Debug")
|
||||
local CommandsData = require("TOC/CommandsData")
|
||||
--------------------------------------------
|
||||
|
||||
@@ -9,11 +10,11 @@ local ServerRelayCommands = {}
|
||||
---@param surgeonPl IsoPlayer
|
||||
---@param args relayDamageDuringAmputationParams
|
||||
function ServerRelayCommands.RelayDamageDuringAmputation(surgeonPl, args)
|
||||
local patientPl = getSpecificPlayer(args.patientNum)
|
||||
local patientPl = getPlayerByOnlineID(args.patientNum)
|
||||
local surgeonNum = surgeonPl:getOnlineID()
|
||||
|
||||
---@type receiveDamageDuringAmputationParams
|
||||
local params = {surgeonNum = surgeonNum, args.limbName}
|
||||
local params = {surgeonNum = surgeonNum, limbName = args.limbName}
|
||||
sendServerCommand(patientPl, CommandsData.modules.TOC_RELAY, CommandsData.client.Relay.ReceiveDamageDuringAmputation, params)
|
||||
end
|
||||
|
||||
@@ -21,11 +22,11 @@ end
|
||||
---@param surgeonPl IsoPlayer
|
||||
---@param args relayExecuteAmputationActionParams
|
||||
function ServerRelayCommands.RelayExecuteAmputationAction(surgeonPl, args)
|
||||
local patientPl = getSpecificPlayer(args.patientNum)
|
||||
local patientPl = getPlayerByOnlineID(args.patientNum)
|
||||
local surgeonNum = surgeonPl:getOnlineID()
|
||||
|
||||
---@type receiveDamageDuringAmputationParams
|
||||
local params = {surgeonNum = surgeonNum, args.limbName}
|
||||
local params = {surgeonNum = surgeonNum, limbName = args.limbName}
|
||||
sendServerCommand(patientPl, CommandsData.modules.TOC_RELAY, CommandsData.client.Relay.ReceiveExecuteAmputationAction, params)
|
||||
end
|
||||
|
||||
@@ -34,7 +35,7 @@ end
|
||||
-------------------------
|
||||
|
||||
local function OnClientRelayCommand(module, command, playerObj, args)
|
||||
if module == CommandsData.modules.TOC_ACTION and ServerRelayCommands[command] then
|
||||
if module == CommandsData.modules.TOC_RELAY and ServerRelayCommands[command] then
|
||||
ServerRelayCommands[command](playerObj, args)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user