module Base
{

	model 86oshkoshP19Awindowfl
	{
		mesh = vehicles/Vehicles_86oshkoshP19A_Body|p19a_window_fl,
		shader = damn_vehicle_shader,
		static = FALSE,
		scale = 0.1,
        boneWeight = window_fl_bone 1.0,
	}

	model 86oshkoshP19Awindowfr
	{
		mesh = vehicles/Vehicles_86oshkoshP19A_Body|p19a_window_fr,
		shader = damn_vehicle_shader,
		static = FALSE,
		scale = 0.1,
        boneWeight = window_fr_bone 1.0,
	}

	template vehicle P19AWindows
	{
		part WindowFrontLeft
		{
			model windowFL463426
			{
				file = 86oshkoshP19Awindowfl,
			}

			anim ClosedToOpen
			{
				anim = window_fl_opening,
				animate = FALSE,
			}

			parent = DoorFrontLeft,
			area = SeatFrontLeft,
			itemType = Base.P19ASideWindow,
			table install
			{
				requireInstalled = DoorFrontLeft,
			}
			table uninstall
				{
				requireUninstalled = DAMNFrontLeftArmor,
				}
		}

		part WindowFrontRight
		{
			model windowFR68534563
			{
				file = 86oshkoshP19Awindowfr,
			}

			anim ClosedToOpen
			{
				anim = window_fr_opening,
				animate = FALSE,
			}

			parent = DoorFrontRight,
			area = SeatFrontRight,
			itemType = Base.P19ASideWindow,
			table install
			{
				requireInstalled = DoorFrontRight,
			}
			table uninstall
				{
				requireUninstalled = DAMNFrontRightArmor,
				}
		}

		part Window*
		{
			category = door,
			mechanicRequireKey = true,
            durability = 2,
			window
			{
				openable = true,
			}
			table install
			{
				items
				{
					1
					{
						tags = Screwdriver,
						count = 1,
						keep = true,
						equip = primary,
					}
				}
				time = 500,
				skills = Mechanics:3,
				recipes = Intermediate Mechanics,
				test = Vehicles.InstallTest.Default,
				complete = Vehicles.InstallComplete.Window,
			}
			table uninstall
			{
				items
				{
					1
					{
						tags = Screwdriver,
						count = 1,
						keep = true,
						equip = primary,
					}
				}
				time = 500,
				skills = Mechanics:3,
				recipes = Intermediate Mechanics,
				test = Vehicles.UninstallTest.Default,
				complete = Vehicles.UninstallComplete.Default,
			}
			lua
			{
				create = Vehicles.Create.Window,
				init = Vehicles.Init.Window,
			}
		}
	}
}

