Winston
WadTool Slot Number: 298
				
					TEN.Objects.ObjID.WINSTON
				
			

Setup Instructions

The ever-faithful Winston: Lara Croft’s long time, multi-generational butler is back.

  • OCB 0: Butler mode. Will continually follow Lara in an attempt to server her with tea.
  • OCB 1: Target practice mode. Lara will use Winston for target practice.
    • In order to swap between the two versions: you must use MESHSWAP_ARMY_WINSTON_OUTFIT and swap the meshes if the OCB is 1.  Use the code below to do this in-game:

The animations from the TR2 and TR3 version of Winston have been combined.

 

Additional Lua

				
					-- Function to swap Winston to Army meshes
local function WinstonToArmyMeshswap(winstonNormal, winstonNormalOCB)
    local numMeshes = 26 -- Total number of meshes to swap
    local winstonArmyID = 1120 -- Object ID number
    
    if winstonNormalOCB == 1 then 
        for i = 0, numMeshes - 1 do
            winstonNormal:SwapMesh(i, winstonArmyID, i)
        end
    end
end

-- Function to swap Army to Winston meshes
local function ArmyToWinston(winstonNormal, winstonNormalOCB)
    local numMeshes = 26 -- Total number of meshes to swap
    local winstonNormalID = 298 -- Object ID number
    
    if winstonNormalOCB == 0 then 
        for i = 0, numMeshes - 1 do
            winstonNormal:SwapMesh(i, winstonNormalID, i)
        end
    end
end

LevelFuncs.OnLoop = function()
    local winstonNormal = GetMoveableByName("WINSTON") 
    local winstonNormalOCB = winstonNormal:GetOCB()  
    
    if winstonNormalOCB == 1 then 
        WinstonToArmyMeshswap(winstonNormal, winstonNormalOCB)
    elseif winstonNormalOCB == 0 then 
        ArmyToWinston(winstonNormal, winstonNormalOCB)
    end
end

--code: Stranger1992, 23/03/24