Restored OnTocClientCommands

This commit is contained in:
Pao
2023-01-13 03:37:17 +01:00
parent 11df9ef637
commit 5750b3a396
7 changed files with 122 additions and 152 deletions

View File

@@ -0,0 +1,22 @@
function ResetEverything()
local player = getPlayer()
local mod_data = player:getModData() -- TODO we need to send data...
mod_data.TOC = nil
TheOnlyCure.InitTheOnlyCure(_, player)
-- Destroy the amputation model
for _,v in ipairs(GetBodyParts()) do
local cloth = player:getInventory():FindAndReturn(find_clothName2_TOC(v))
if cloth ~= nil then
player:removeWornItem(cloth)
player:getInventory():Remove(cloth:getName())
end
end
player:transmitModData()
end