
#######################################################
#
# Begin Chinook (Aviation Mod 2.0 revised)
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 ChinookFuel
	Room				 ChinookFuelDepot
	Condition			 NotLoaded
	Properties			 HighPriority
	Distribution		 Random
END

#######################################################
#
# End Chinook (Aviation Mod 2.0 revised)
#
#######################################################




#######################################################
#
#  Begin Real-time Basketball
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 Basketball
	Container			 BasketballBasket
	Distribution		 Nearest
	MinSlotId			 0
	Properties			 HighPriority
	Condition			 EntityDead
	Worker				 Janitor
	Worker				 Workman
	Worker				 Cook
	Worker				 Gardener
	Worker				 Guard
END

#######################################################
#
#  End Real-time Basketball
#
#######################################################



#######################################################
#
#  Begin Border Changer
#
#######################################################



#######################################################
#
#  End Border Changer
#
#######################################################



#######################################################
#
#  Begin Branch Library
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 LibraryBookSorted
	Container			 LibraryBookshelf
	Room				 Library
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LibraryBookSorted
	Container			 LibraryBookshelf
	Room				 BranchLibrary
	Distribution		 Random
END

#######################################################
#
#  End Branch Library
#
#######################################################



#######################################################
#
#  Begin Cemetery
#
#######################################################

BEGIN ProductionRule
	Rule				 Entity
	Container			 GraveCoffin
	Room				 Morgue
	Distribution		 Nearest
	MaxSlotId			 0
	Condition			 EntityDead
	Properties			 HighPriority
	Worker				 GraveDigger
END

BEGIN ProductionRule
	Rule				 Entity
	Container			 MorgueSlab
	Room				 Morgue
	Distribution		 Nearest
	Condition			 EntityDead
	Properties			 HighPriority
	Worker				 GraveDigger
END

BEGIN ProductionRule
	Rule				 Entity
	Container			 Hearse
	Distribution		 Nearest
	MaxSlotId			 3
	Condition			 EntityDead
	Worker				 GraveDigger
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GraveCoffin
	Container			 SmallTableMorgue
	MinSlotId			 4
	MaxSlotId			 5
	Room				 Morgue
	Distribution		 Nearest
	Condition			 NotLoaded
    Worker				 GraveDigger
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GraveCoffin
	Room				 Exports
	Distribution		 Nearest
	Condition			 NotLoaded
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GraveCoffinParlour
	Container			 SmallTableFP
	MinSlotId			 4
	MaxSlotId			 5
	Room				 FuneralParlour
	Distribution		 Nearest
	Condition			 NotLoaded
    Worker				 GraveDigger
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GraveCoffinParlour
	Container			 ParlourAltar
	MinSlotId			 3
	MaxSlotId			 3
	Room				 FuneralParlour
	Distribution		 Nearest
	Condition			 NotLoaded
	Worker				 GraveDigger
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GraveCoffinLoaded
	Container			 GraveUnderConstruction1
	MinSlotId			 3
	MaxSlotId			 3
	Condition			 NotLoaded
	Distribution		 Random
    Worker				 GraveDigger
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GraveCoffinStaffLoaded
	Container			 GraveStaffUnderConstruction1
	MinSlotId			 3
	MaxSlotId			 3
	Condition			 NotLoaded
	Distribution		 Random
    Worker				 GraveDigger
	Properties			 HighPriority
END

BEGIN Processor
	Processor			 ParlourAltar
	Input				 None
	Output				 None
	OperatingTime		 0
    Worker				 GraveDigger
END

BEGIN Processor
	Processor			 GraveUnderConstruction1
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 GraveDigger
END

BEGIN Processor
	Processor			 GraveStaffUnderConstruction1
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 GraveDigger
END

BEGIN Processor
	Processor			 SmallTableMorgue
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 GraveDigger
END

BEGIN Processor
	Processor			 SmallTableFP
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 GraveDigger
	Worker				 SomeFriendParlour1
	Worker				 SomeFriendParlour2
	Worker				 SomeFriendParlour3
	Worker				 SomeFriendParlour4
	Worker				 SomeFriendParlour5
END

#######################################################
#
#  End Cemetery
#
#######################################################



#######################################################
#
#  Begin Controlled Demolition
#
#######################################################

BEGIN ProductionRule       
    Rule                 Storage
    Material             ExplosiveCharge666  
    Container            Table
    Room                 Armoury 
	Distribution		 Random
    Condition            NotLoadedIsStack
	MinSlotId			 0
    MaxSlotId			 3
    StackInRoom          Armoury
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             ExplosiveCharge666
    Distribution         Random
	Room                 Armoury
    Condition            NotLoadedIsStack  
    StackInRoom          Armoury
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             Detonator666  
    Container            Table
    Room                 Armoury 
	Distribution		 Random
    Condition            NotLoadedIsStack
	MinSlotId			 0
    MaxSlotId			 3
    StackInRoom          Armoury
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             Detonator666  
    Distribution         Random
	Room                 Armoury
    Condition            NotLoadedIsStack  
    StackInRoom          Armoury
END

#######################################################
#
#  End Controlled Demolition
#
#######################################################



#######################################################
#
#  Begin Limo Garage
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoRepairPapers
	Container			 LimoFilingCabinet
	MinSlotId			 0
	MaxSlotId			 0
	Distribution		 Nearest
	Worker				 Prisoner
    Worker				 Workman
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill1
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill2
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill3
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill4
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill5
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill6
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill7
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill8
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill9
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LimoBill10
	Room				 Exports
	StackInRoom			 Exports
	Distribution		 Random
END

BEGIN Processor
    Processor				 LimoFilingCabinet
	Object					 LimoFilingCabinet
    Input					 LimoRepairPapers
    Output					 LimoBill1
	AlternateOutput			 LimoBill2
	AlternateOutputChance	 0.5
    OperatingTime			 1.0
    Properties				 ShowDuringOperation
	Worker					 Prisoner
    Worker					 Workman
END

#######################################################
#
#  End Limo Garage
#
#######################################################



#######################################################
#
#  Begin Customizable Control Booths
#
#######################################################


# Slots 0, 1, 2 hold utility panels (left side of a display)
# Slots 3, 4, 5 hold pager panels (right side of a display)

BEGIN ProductionRule
	Rule				 Storage
	Material			 UtilityPanel
	Container			 UtilityBooth
	Distribution		 Nearest
	MinSlotId			 0
	MaxSlotId			 2
	Properties			 HighPriority
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Pager
	Container			 UtilityBooth
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 5
	Properties			 HighPriority
	Condition			 NotLoaded
END

# below are just eyecandy display panels

BEGIN ProductionRule
	Rule				 Storage
	Material			 DisplayPanelLeft
	Container			 UtilityBooth
	Distribution		 Nearest
	MinSlotId			 0
	MaxSlotId			 2
	Properties			 HighPriority
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 DisplayPanelRight
	Container			 UtilityBooth
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 5
	Properties			 HighPriority
	Condition			 NotLoaded
END


#######################################################
#
#  End Customizable Control Booths
#
#######################################################



#######################################################
#
#  Begin Explosive SmartPhone
#
#######################################################


BEGIN Processor
	Processor			 SortingTable
	Input				 MailUnsorted
	Output				 MailSorted
	OperatingTime		 5.0
	Worker				 Guard
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetAluminium
	Container			 PhonePress
	Room				 PhoneWorkshop
	Distribution		 NonCompeting
	Properties			 HighPriority
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetAluminium
	Container			 PhonePress
	Room				 PhoneWorkshop
	Distribution		 OutOfStock
	Properties			 HighPriority
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetAluminium
	Container			 AluminiumStorageRack
	Room				 PhoneWorkshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Properties			 HighPriority
	Condition			 NotLoaded
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetAluminium
	Room				 PhoneWorkshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PressedAluminium
	Container			 PhoneTable
	Distribution		 NonCompeting
	Properties			 HighPriority
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PressedAluminium
	Container			 PhoneTable
	Distribution		 OutOfStock
	Properties			 HighPriority
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PressedAluminium
	Container			 AluminiumStorageRack
	Room				 PhoneWorkshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Properties			 HighPriority
	Condition			 NotLoaded
	Worker				 SmartPhoneGenius
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SeizedSmartPhone
	Container			 SmallTablePhoneWorkshop
	MinSlotId			 1
	MaxSlotId			 6
	Room				 PhoneWorkshop
    StackInRoom          PhoneWorkshop
	Distribution		 NonCompeting
	Worker				 SmartPhoneGenius
    Worker				 Workman
    Worker				 Guard
    Worker				 Janitor
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SeizedSmartPhone
	Container			 SmallGardenTable
	MinSlotId			 4
	MaxSlotId			 6
	Room				 Recycling
	Distribution		 NonCompeting
	Worker				 SmartPhoneGenius
    Worker				 Workman
    Worker				 Guard
    Worker				 Janitor
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SeizedSmartPhone
	Room				 Exports
	Distribution		 Nearest
	Worker				 SmartPhoneGenius
    Worker				 Workman
    Worker				 Guard
    Worker				 Janitor
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 AssembledSmartPhone
	Container			 SmallTablePhoneWorkshop
	MinSlotId			 1
	MaxSlotId			 6
	Room				 PhoneWorkshop
    StackInRoom          PhoneWorkshop
	Distribution		 NonCompeting
	Properties			 HighPriority
	Worker				 SmartPhoneGenius
    Worker				 Prisoner
    Worker				 Workman
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 AssembledSmartPhone
	Room				 Exports
	Distribution		 Nearest
	Worker				 SmartPhoneGenius
	Worker				 Prisoner
	Worker				 Workman
END

BEGIN Processor
    Processor            PhonePress
    Input                SheetAluminium
    InputCount           1
    OutputCount          1
    Output               PressedAluminium
    OperatingTime        5.0
	Worker				 Prisoner
	Worker				 SmartPhoneGenius
END

BEGIN Processor
    Processor            PhoneTable
    Input                PressedAluminium
    Output               AssembledSmartPhone
    InputCount           1
    OutputCount          1
    OperatingTime        10.0
	Worker				 Prisoner
	Worker				 SmartPhoneGenius
    AlternateOutput      FaultySmartPhone
    AlternateOutputCount 1
    AlternateOutputChance 0.025
	Properties			 ShowDuringOperation
END

# define dummy processor so modded staff know they can put stuff in here and operate it when required

BEGIN Processor
    Processor            AluminiumStorageRack
    Input                SheetAluminium
    InputCount           3
    OutputCount          3
    Output               PressedAluminium
    OperatingTime        0
    Properties           ShowDuringOperation
	Worker				 SmartPhoneGenius
    Worker               Prisoner
END

BEGIN Processor
	Processor			 SmallTablePhoneWorkshop
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 SmartPhoneGenius
	Worker				 Prisoner
	Worker				 Workman
END

#######################################################
#
#  End Explosive SmartPhone
#
#######################################################



#######################################################
#
#  Begin High Efficiency Condensing Boiler
#
#######################################################



#######################################################
#
#  End High Efficiency Condensing Boiler
#
#######################################################



#######################################################
#
#  Begin Prison Fire Brigade
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 CashBack
	Room				 Exports
	Distribution		 Nearest
END

#######################################################
#
#  End Prison Fire Brigade
#
#######################################################



#######################################################
#
#  Begin Recycling
#
#######################################################

# preprocessed garbage

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedTrash
	Distribution		 Nearest
	Container			 TrashBin10
    Properties           HighPriority
	Condition			 NotLoaded
	Worker				 Workman
	Worker				 Cook
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 GraveDigger
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedTrash
	Distribution		 Nearest
	Container			 TrashBin20
    Properties           HighPriority
	Condition			 NotLoaded
	Worker				 Workman
	Worker				 Cook
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 GraveDigger
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedTrash
	Distribution		 Nearest
	Container			 TrashBin30
    Properties           HighPriority
	Condition			 NotLoaded
	Worker				 Workman
	Worker				 Cook
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 GraveDigger
	Worker				 Prisoner
END


# unsorted garbage coming from bin gets processed

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedGarbage
	Room				 Recycling
	Container			 RecycleDesk
	Distribution		 NonCompeting
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedGarbage
	Room				 Recycling
	Container			 RecycleDesk
    Distribution         OutOfStock
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedGarbage
	Container			 Table
	Room				 Recycling
	Distribution		 Nearest
	MinSlotId			 0
	MaxSlotId			 3
    Condition			 NotLoadedOnTable
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedGarbage
	Container			 SmallTable
	Room				 Recycling
	Distribution		 Nearest
	MinSlotId			 0
	MaxSlotId			 1
    Condition			 NotLoadedOnTable
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 UnsortedGarbage
	Container			 SmallGardenTable
	Room				 Recycling
	Distribution		 Nearest
	MinSlotId			 4
	MaxSlotId			 5
    Condition			 NotLoadedOnTable
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
END


# sorted garbage goes to compactor

BEGIN ProductionRule
	Rule				 Storage
	Material			 SortedGarbage
	Distribution		 NonCompeting
	Container			 TrashCompactor
	MinSlotId			 3
	MaxSlotId			 7
    Properties           HighPriority
	Worker				 Workman
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 CompactGarbage
	Distribution		 NonCompeting
	Container			 TrashCompactor
	MinSlotId			 3
	MaxSlotId			 7
    Properties           HighPriority
    Condition			 NotLoaded
	Worker				 Workman
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SortedGarbageExport
	Room				 Exports
	Distribution		 Random
    Properties           HighPriority
END


# green garbage goes to garden or greenhouse

BEGIN ProductionRule
	Rule				 Storage
	Material			 GreenGarbage
	Container			 RecycleBin
	Distribution		 NonCompeting
    Properties           HighPriority
	Condition			 NotLoaded
	Worker				 Workman
	Worker				 Janitor
	Worker				 GardenWorker
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GreenGarbage
	Container			 RecycleBin
    Distribution         OutOfStock
    Properties           HighPriority
	Condition			 NotLoaded
	Worker				 Workman
	Worker				 Janitor
	Worker				 GardenWorker
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GreenGarbage
	Room				 Exports
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Workman
	Worker				 Janitor
	Worker				 GardenWorker
	Worker				 Prisoner
END


# various garbage processors

BEGIN Processor
	Processor			 RecycleDesk
	Input				 UnsortedGarbage
	InputCount			 1
	Output				 SortedGarbage
	OutputCount			 1
    AlternateOutput      GreenGarbage
    AlternateOutputCount 1
    AlternateOutputChance 0.1
	Object				 RecycleDesk
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
	Qualification		 RecycleGarbage
	OperatingTime		 6.0
	Properties			 ShowDuringOperation
END

BEGIN Processor
	Processor			 TrashBin10
	Input				 UnsortedTrash
	InputCount			 10
	Output				 UnsortedGarbage
	OutputCount			 10
	Object				 TrashBin10
	Worker				 Workman
	Worker				 Cook
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 GraveDigger
	Worker				 Prisoner
	Qualification		 RecycleGarbage
	OperatingTime		 2.0
END

BEGIN Processor
	Processor			 TrashBin20
	Input				 UnsortedTrash
	InputCount			 20
	Output				 UnsortedGarbage
	OutputCount			 20
	Object				 TrashBin20
	Worker				 Workman
	Worker				 Cook
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 GraveDigger
	Worker				 Prisoner
	Qualification		 RecycleGarbage
	OperatingTime		 2.0
END

BEGIN Processor
	Processor			 TrashBin30
	Input				 UnsortedTrash
	InputCount			 30
	Output				 UnsortedGarbage
	OutputCount			 30
	Object				 TrashBin30
	Worker				 Workman
	Worker				 Cook
	Worker				 Janitor
	Worker				 Gardener
	Worker				 GardenWorker
	Worker				 PlantationWorker
	Worker				 GraveDigger
	Worker				 Prisoner
	Qualification		 RecycleGarbage
	OperatingTime		 2.0
END

BEGIN Processor
	Processor			 RecycleBin
	Input				 GreenGarbage
	InputCount			 10
	Output				 GardenFertilizer
	OutputCount			 10
	Object				 RecycleBin
	Worker				 Workman
	Worker				 Janitor
	Worker				 GardenWorker
	Worker				 Prisoner
	Qualification		 RecycleGarbage
	OperatingTime		 6.0
END

BEGIN Processor
	Processor			 TrashCompactor
	Input				 CompactGarbage
	InputCount			 60
	Output				 SortedGarbageExport
	OutputCount			 60
	Object				 TrashCompactor
	Worker				 Workman
	Worker				 Janitor
	Worker				 Prisoner
	Qualification		 RecycleGarbage
	OperatingTime		 13.0
END

#######################################################
#
#  Begin Simple Garden Mod by Elfylia
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenSeed
	Container			 SmallGardenTableFerti
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenSeed
	Container			 SmallGardenTableFerti
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenSeed
	Room				 Garden
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenSeed
	Room				 Greenhouse
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenCompost
	Container			 SmallGardenTableFerti
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 4
	MaxSlotId			 4
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenCompost
	Container			 SmallGardenTableFerti
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 4
	MaxSlotId			 4
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenFertilizer
	Container			 SmallGardenTableFerti
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 5
	MaxSlotId			 5
	Condition			 NotLoadedOnTable
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenFertilizer
	Container			 SmallGardenTableFerti
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 5
	MaxSlotId			 5
	Condition			 NotLoadedOnTable
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenFertilizer
	Room				 Garden
	Distribution		 Nearest
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenFertilizer
	Room				 Greenhouse
	Distribution		 Nearest
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenFertilizer
	Room				 Exports
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenDDT
	Container			 SmallGardenTableFerti
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 6
	MaxSlotId			 6
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenDDT
	Container			 SmallGardenTableFerti
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 6
	MaxSlotId			 6
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenTomato
	Container			 SmallGardenTable
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenTomato
	Room				 Exports
	Distribution		 Random
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenCucumber
	Container			 SmallGardenTable
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 4
	MaxSlotId			 4
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenCucumber
	Container			 SmallGardenTable
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 4
	MaxSlotId			 4
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenCucumber
	Room				 Exports
	Distribution		 Random
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenRose
	Container			 SmallGardenTable
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 5
	MaxSlotId			 5
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenRose
	Container			 SmallGardenTable
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 5
	MaxSlotId			 5
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenRose
	Room				 Exports
	Distribution		 Random
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenLily
	Container			 SmallGardenTable
	Room				 Garden
	Distribution		 Nearest
	MinSlotId			 6
	MaxSlotId			 6
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenLily
	Container			 SmallGardenTable
	Room				 Greenhouse
	Distribution		 Nearest
	MinSlotId			 6
	MaxSlotId			 6
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 GardenLily
	Room				 Exports
	Distribution		 Random
	Worker				 Prisoner
	Worker				 GardenWorker
END

BEGIN Processor
	Processor			 SmallGardenTable
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 GardenWorker
	Worker				 Gardener
	Worker				 Workman
	Worker				 Janitor
END

BEGIN Processor
	Processor			 SmallGardenTableFerti
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 GardenWorker
	Worker				 Gardener
	Worker				 Workman
	Worker				 Janitor
END

#######################################################
#
#  End Simple Garden Mod by Elfylia
#
#######################################################


#######################################################
#
#  End Recycling
#
#######################################################



#######################################################
#
#  Begin Road Sensors Compact Edition
#
#######################################################



#######################################################
#
#  End Road Sensors Compact Edition
#
#######################################################



#######################################################
#
#  Begin Sauna
#
#######################################################



#######################################################
#
#  End Sauna
#
#######################################################



#######################################################
#
#  Begin Small Road Gate
#
#######################################################



#######################################################
#
#  End Small Road Gate
#
#######################################################



#######################################################
#
#  Begin Solar Power Stations
#
#######################################################



#######################################################
#
#  End Solar Power Stations
#
#######################################################



#######################################################
#
#  Begin Tesla-Matic 2.0
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 DepletedTeslaBattery
	Room				 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 TeslaBattery2
	Room				 Storage
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 TeslaBattery2
	Room				 Storage
	Distribution		 Random
	Condition			 NotLoadedIsStack
END

#######################################################
#
#  End Tesla-Matic 2.0
#
#######################################################



#######################################################
#
#  Begin Money Laundering Mod (Easy Mode) by hoosdatGuy
#
#######################################################

BEGIN ProductionRule       
    Rule                 Storage
    Material             DirtyMoney  
    Container            MoneyTable
    Distribution         Random
	Worker               Prisoner
	Worker				 Workman
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             DirtyMoney
    Container            Table
	Room                 Accounting
    Distribution         Random
	MinSlotId			 0
    MaxSlotId            3
    Condition            NotLoaded
	Worker               Prisoner
	Worker				 Workman
END


BEGIN ProductionRule       
    Rule                 Storage
    Material             DirtyMoney
    Container            SmallTable
	Room                 Accounting
    Distribution         Random
	MinSlotId			 0
    MaxSlotId            1
    Condition            NotLoaded
	Worker               Prisoner
	Worker				 Workman
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             DirtyMoney  
    Room                 Accounting  
    Distribution         Random  
    Condition            NotLoaded
	Worker               Prisoner
	Worker				 Workman
END

BEGIN ProductionRule
	Rule                 Storage
	Material             CleanMoney
	Room                 Vault
	Container            MoneySafe
	Distribution         Random
	Worker               Prisoner
	Worker				 Workman
END

BEGIN ProductionRule
	Rule                 Storage
	Material             CleanMoney
	Room                 Exports
	Distribution         Random
	Worker               Prisoner
	Worker				 Workman
END

BEGIN Processor
    Processor            MoneyTable
    Input                DirtyMoney
    Output               CleanMoney
	Object               MoneyTable
	Worker               Prisoner
    OperatingTime        6.0
	Properties           ShowDuringOperation
END

#######################################################
#
#  End Money Laundering Mod (Easy Mode) by hoosdatGuy
#
#######################################################



#######################################################
#
#  Begin BarberMod by oskr13
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 BlondHairStrand
	Container			 BlondBarberPress
	Room				 WigProductionRoom
	Worker				 Prisoner
	Worker				 Barber
	Distribution		 Nearest
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 BrownHairStrand
	Container			 BrownBarberPress
	Room				 WigProductionRoom
	Worker				 Prisoner
	Worker				 Barber
	Distribution		 Nearest
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RedHairStrand
	Container			 RedBarberPress
	Room				 WigProductionRoom
	Worker				 Prisoner
	Worker				 Barber
	Distribution		 Nearest
END

BEGIN Processor
	Processor			 BlondBarberPress
	Input				 BlondHairStrand
	InputCount			 6
	Output				 WigBox
	OperatingTime		 15.0
	Object				 BlondBarberPress
	Worker				 Prisoner
	Worker				 Barber
END

BEGIN Processor
	Processor			 BrownBarberPress
	Input				 BrownHairStrand
	InputCount			 6
	Output				 WigBox
	OperatingTime		 15.0
	Object				 BrownBarberPress
	Worker				 Prisoner
	Worker				 Barber
END

BEGIN Processor
	Processor			 RedBarberPress
	Input				 RedHairStrand
	InputCount			 10
	Output				 RedWigBox
	OperatingTime		 30.0
	Object				 RedBarberPress
	Worker				 Prisoner
	Worker				 Barber
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 WigBox
	Container			 Table
	MinSlotId			 0
	MaxSlotId			 3
	Room				 WigProductionRoom
	Worker				 Prisoner
	Worker				 Barber
	Distribution		 Nearest
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 WigBox
	Container			 SmallTable
	MinSlotId			 0
	MaxSlotId			 1
	Room				 WigProductionRoom
	Worker				 Prisoner
	Worker				 Barber
	Distribution		 Nearest
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 WigBox
	Room				 Exports
	Distribution		 Random
	Worker				 Prisoner
	Worker				 Workman
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RedWigBox
	Container			 Table
	MinSlotId			 0
	MaxSlotId			 3
	Room				 WigProductionRoom
	Distribution		 Nearest
	Worker				 Prisoner
	Worker				 Barber
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RedWigBox
	Container			 SmallTable
	MinSlotId			 0
	MaxSlotId			 1
	Room				 WigProductionRoom
	Distribution		 Nearest
	Worker				 Prisoner
	Worker				 Barber
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RedWigBox
	Room				 Exports
	Distribution		 Random
	Worker				 Prisoner
	Worker				 Workman
END

#######################################################
#
#  End BarberMod by oskr13
#
#######################################################



#######################################################
#
#  Begin Manufactury by Decamatus
#
#######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 Jeans
	Container			 SmallTableManufactury
	MinSlotId			 3
	MaxSlotId			 4
	Room				 Manufactury
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 Nearest
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Jeans
	Room				 Exports
	Distribution		 Nearest
	Worker				 Prisoner
	Worker				 Tailor
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ClothSpool
	Container			 SewingStation
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 NonCompeting
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ClothSpool
	Container			 SewingStation
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 OutOfStock
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ClothSpool
	Container			 SmallTableManufactury
	Room				 Manufactury
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 NonCompeting
	MinSlotId			 5
	MaxSlotId			 6
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ClothSpool
	Room				 Manufactury
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 NonCompeting
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RawCotton
	Container			 TextileMill
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 NonCompeting
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RawCotton
	Container			 TextileMill
	Worker				 Prisoner
	Worker				 Tailor
	Distribution		 OutOfStock
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RawCotton
	Container			 SmallGardenTableCotton
	Room				 CottonPlantation
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 6
	Condition			 NotLoaded
	Properties			 HighPriority
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RawCotton
	Room				 CottonPlantation
	Condition			 NotLoaded
	Distribution		 Nearest
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 RawCotton
	Room				 Exports
	Condition			 NotLoaded
	Distribution		 Nearest
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 CottonSeed
	Container			 SmallGardenTablePlantation
	Room				 CottonPlantation
	Distribution		 Nearest
	MinSlotId			 3
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 CottonDDT
	Container			 SmallGardenTablePlantation
	Room				 CottonPlantation
	Distribution		 Nearest
	MinSlotId			 4
	MaxSlotId			 4
	Condition			 NotLoaded
	Properties			 HighPriority
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 CottonCompost
	Container			 SmallGardenTablePlantation
	Room				 CottonPlantation
	Distribution		 Nearest
	MinSlotId			 5
	MaxSlotId			 5
	Condition			 NotLoaded
	Properties			 HighPriority
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 CottonFertilizer
	Container			 SmallGardenTablePlantation
	Room				 CottonPlantation
	Distribution		 Nearest
	MinSlotId			 6
	MaxSlotId			 6
	Condition			 NotLoaded
	Properties			 HighPriority
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN Processor
	Processor			 SmallTableManufactury
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 Tailor
END

BEGIN Processor
	Processor			 SmallGardenTableCotton
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 Tailor
	Worker				 PlantationWorker
END

BEGIN Processor
	Processor			 SmallGardenTablePlantation
	Input				 None
	Output				 None
	OperatingTime		 0
	Worker				 Prisoner
	Worker				 PlantationWorker
END

BEGIN Processor
	Processor			 SewingStation
	Input				 ClothSpool
	InputCount			 1
	Output				 Jeans
	OutputCount			 3
	OperatingTime		 15.0
	Object				 SewingStation
	Worker				 Tailor
	Worker				 Prisoner
END

BEGIN Processor
	Processor			 TextileMill
	Input				 RawCotton
	InputCount			 1
	Output				 ClothSpool
	OutputCount			 1
	OperatingTime		 9.0
	Object				 TextileMill
	Worker				 Tailor
	Worker				 Prisoner
END

#######################################################
#
#  End Manufactury by Decamatus
#
#######################################################



#######################################################
#
# Default game production rules with SmallTable added
#
######################################################

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Container			 Fridge
	Room				 Kitchen
	Distribution		 Kitchens
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Container			 Fridge
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Container			 Table
	MinSlotId			 0
	MaxSlotId			 3
	Room				 Kitchen
	Distribution		 Kitchens
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Container			 SmallTable
	MinSlotId			 0
	MaxSlotId			 1
	Room				 Kitchen
	Distribution		 Kitchens
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
	MinSlotId			 1
	MaxSlotId			 2
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Ingredients
	Room				 Kitchen
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 IngredientsCooked
	Container			 ServingTable
	Distribution		 Nearest
	MinSlotId			 1
	MaxSlotId			 4
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTray
	Container			 ServingTable
	Distribution		 Linked
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTray
	Container			 ServingTable
	Distribution		 OutOfStock
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTray
	Container			 ServingTable
	Distribution		 Nearest
	Condition			 NotInFoodSystem
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTray
	Room				 Kitchen
	Container			 SmallTable
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Distribution		 NonCompeting
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTrayDirty
	Container			 Sink
	Distribution		 Linked
	Condition			 NotDuringMealService
	StackInRoom			 Canteen
    StackInRoom          Staffroom
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTrayDirty
	Container			 SmallSink
	Distribution		 Linked
	Condition			 NotDuringMealService
	StackInRoom			 Canteen
    StackInRoom          Staffroom
	MaxSlotId			 0
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTrayDirty
	Container			 SmallWoodenSink
	Distribution		 Linked
	Condition			 NotDuringMealService
	StackInRoom			 Canteen
    StackInRoom          Staffroom
	MaxSlotId			 0
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTrayDirty
	Container			 Table
	Room				 Canteen
	Distribution		 Nearest
	Condition			 NotInFoodSystem
	StackInRoom			 Canteen
    StackInRoom          Staffroom
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTrayDirty
	Room				 Canteen
	Container			 Table
	Distribution		 Linked
	Condition			 NotInKitchenOrCanteen
	StackInRoom			 Canteen
    StackInRoom          Staffroom
	MinSlotId			 0
	MaxSlotId			 3
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 FoodTrayDirty
	Room				 Canteen
	Container			 SmallTable
	Distribution		 Linked
	Condition			 NotInKitchenOrCanteen
	StackInRoom			 Canteen
    StackInRoom          Staffroom
	MinSlotId			 0
	MaxSlotId			 1
    Properties           HighPriority
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Container			 Table
	Room				 Intake
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 UniformsInIntake
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Container			 SmallTable
	Room				 Intake
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 UniformsInIntake
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Container			 Table
	Room				 Laundry
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 UniformsRequireMoving
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Container			 SmallTable
	Room				 Laundry
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 UniformsRequireMoving
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Room				 Laundry
	Distribution		 NonCompeting
	Condition			 UniformsRequireMoving
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Container			 Table
	Room				 Intake
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 UniformsRequireMovingToIntake
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PrisonerUniform
	Container			 SmallTable
	Room				 Intake
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 UniformsRequireMovingToIntake
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 DirtyPrisonerUniform
	Room				 Laundry
	Distribution		 NonCompeting
	Condition			 UniformsNotTargetted
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 DirtyPrisonerUniform
	Container			 LaundryMachine
	Room				 Laundry
	Distribution		 NonCompeting
	Condition			 UniformsInLaundry
	MaxSlotId			 0
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 DirtyPrisonerUniform
	Container			 LaundryBasket
	Distribution		 Nearest
	Condition			 NotLoadedIsStack
	MaxSlotId			 0
END

######################################################
# Log

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 WoodSaw
	Room				 WoodWorkshop
	Distribution		 Nearest
	Properties			 HighPriority
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 WorkshopSaw
	Room				 Workshop
	Distribution		 NonCompeting
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 WoodSaw
	Room				 WoodWorkshop
	Distribution		 OutOfStock
	Properties			 HighPriority
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 WorkshopSaw
	Room				 Workshop
	Distribution		 OutOfStock
	Worker				 ForestryWorker
	Worker               Prisoner
END

#start loading this fake processor at Slot1, not Slot0 so it will never actually create an Operate job
BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 LogStorageRack
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 LogStorageRack
	Room				 WoodWorkshop
	Distribution		 OutOfStock
	MinSlotId			 1
	MaxSlotId			 7
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 LogStorageRack
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 LogStorageRack
	Room				 Workshop
	Distribution		 OutOfStock
	MinSlotId			 1
	MaxSlotId			 7
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 LogStorageRack
	Room				 PrisonForestry
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 LogStorageRack
	Room				 PrisonForestry
	Distribution		 OutOfStock
	MinSlotId			 1
	MaxSlotId			 7
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 Table
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 Table
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 SmallTable
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Container			 SmallTable
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Room				 Workshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Room				 PrisonForestry
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 ForestryWorker
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Log
	Room				 Exports
	Condition			 NotLoaded
	Distribution		 Nearest
	Worker				 Prisoner
	Worker				 ForestryWorker
END

######################################################
# Wood

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 CoffinTable
	Room				 CoffinWorkshop
	Distribution		 NonCompeting
	Properties			 HighPriority
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 CoffinTable
	Room				 CoffinWorkshop
	Distribution		 OutOfStock
	Properties			 HighPriority
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 CarpenterTable
	Room				 Workshop
	Distribution		 NonCompeting
	Properties			 HighPriority
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 CarpenterTable
	Room				 Workshop
	Distribution		 OutOfStock
	Properties			 HighPriority
	Worker				 Workman
	Worker               Prisoner
END

#start loading this fake processor at Slot1, not Slot0 so it will never actually create an Operate job
BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 WoodStorageRack
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Worker				 ForestryWorker
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 WoodStorageRack
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 7
	Worker				 ForestryWorker
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 Table
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 SmallTable
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 SmallGardenTable
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	MinSlotId			 4
	MaxSlotId			 5
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 Table
	Room				 CoffinWorkshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 SmallTable
	Room				 CoffinWorkshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 Table
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Container			 SmallTable
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Room				 WoodWorkshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Room				 CoffinWorkshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Wood
	Room				 Workshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

# define dummy processors so modded staff know they can put stuff in here and operate it when required
BEGIN Processor
    Processor            LogStorageRack
    Input                Log
    InputCount           3
    OutputCount          3
    Output               Log
    OperatingTime        0
    Properties           ShowDuringOperation
	Worker				 ForestryWorker
    Worker               Prisoner
END

BEGIN Processor
    Processor            WoodStorageRack
    Input                Wood
    InputCount           3
    OutputCount          3
    Output               Wood
    OperatingTime        0
    Properties           ShowDuringOperation
	Worker				 ForestryWorker
    Worker               Prisoner
END

# Forestry worker may cut logs into wood and store it at WoodStorageRacks
# He can now carry stacks of Log from PrisonForestry, to fake processor LogStorageRack, to processor WoodSaw...
# ...and carry the stack of Wood from WoodSaw to WoodStorageRack.
# We could also add him to a CarpenterTable so he would store Wood on that as well, but then he would start making beds, which we don't want.
# That's why he isn't added to the CoffinTable as well.
BEGIN Processor
    Processor            WoodSaw
    Input                Log
    InputCount           1
    Output               Wood
    OutputCount          4
    OperatingTime        8.0
	Object				 WoodSaw
	Properties           ShowDuringOperation
	Worker				 ForestryWorker
    Worker               Prisoner
END

BEGIN Processor
    Processor            CoffinTable
    Input                Wood
	InputCount			 6
	OutputCount			 1
    Output               GraveCoffin
	Object               CoffinTable
    AlternateOutput      GraveCoffin
    AlternateOutputCount 1
    AlternateOutputChance 1
    OperatingTime        60.0
	Properties           ShowDuringOperation
	Worker               Prisoner
END

######################################################
# SheetMetal

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetMetal
	Container			 WorkshopSaw
	Room				 Workshop
	Distribution		 NonCompeting
	Properties			 HighPriority
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetMetal
	Container			 WorkshopSaw
	Room				 Workshop
	Distribution		 OutOfStock
	Properties			 HighPriority
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetMetal
	Container			 MetalStorageRack
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 1
	MaxSlotId			 4
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetMetal
	Container			 Table
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetMetal
	Container			 SmallTable
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 SheetMetal
	Room				 Workshop
	Distribution		 NonCompeting
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

######################################################
# LicensePlate

BEGIN ProductionRule
	Rule				 Storage
	Material			 LicensePlateBlank
	Container			 WorkshopPress
	Distribution		 NonCompeting
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LicensePlateBlank
	Container			 MetalStorageRack
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 5
	MaxSlotId			 7
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LicensePlate
	Container			 Table
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 3
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LicensePlate
	Container			 SmallTable
	Room				 Workshop
	Distribution		 NonCompeting
	MinSlotId			 0
	MaxSlotId			 1
	Condition			 NotLoaded
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LicensePlate
	Room				 Exports
	Distribution		 Random
	Worker				 Workman
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Entity
	Container			 PrisonerBus
	Distribution		 Random
	MaxSlotId			 8
	Condition			 DeathRowTransfer
	Properties			 HighPriority
END

BEGIN ProductionRule
	Rule				 Entity
	Container			 MedicalBed
	Room				 MedicalWard
	Distribution		 Nearest
	Properties			 HighPriority
	Condition			 EntitySeriouslyInjured
END

BEGIN ProductionRule
	Rule				 Entity
	Container			 MedicalBedLarge
	Room				 MedicalWard
	Distribution		 Nearest
	Properties			 HighPriority
	Condition			 EntitySeriouslyInjured
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LibraryBookUnsorted
	Room				 Library
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LibraryBookUnsorted
	Container			 SortingTable
	Room				 Library
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 LibraryBookSorted
	Container			 LibraryBookshelf
	Room				 Library
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 IngredientsCooking
	Container			 Cooker
	Room				 Kitchen
	Distribution		 Nearest
	Condition			 NotLoaded
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailUnsorted
	Container			 SortingTable
	Room				 MailRoom
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailUnsorted
	Container			 Table
	Room				 MailRoom
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 3
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailUnsorted
	Container			 SmallTable
	Room				 MailRoom
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSorted
	Container			 MailSatchel
	Room				 MailRoom
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSatchel
	Container			 Table
	Room				 MailRoom
	Distribution		 OutOfStock
	MinSlotId			 0
	MaxSlotId			 3
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSatchel
	Container			 SmallTable
	Room				 MailRoom
	Distribution		 OutOfStock
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSatchel
	Room				 MailRoom
	Distribution		 OutOfStock
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSatchel
	Container			 Table
	Room				 MailRoom
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 3
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSatchel
	Container			 SmallTable
	Room				 MailRoom
	Distribution		 Random
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 MailSatchel
	Room				 MailRoom
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ShopGoods
	Room				 Shop
	Container			 ShopShelf
	Distribution		 NonCompeting
	Condition			 InRoom
    ConditionTargetRoom	 Shop
	MinSlotId			 0
	MaxSlotId			 2
	Properties			 LoadObject
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ShopGoods
	Room				 Shop
	Container			 Table
	Distribution		 Random
	Condition			 NotLoaded
	MinSlotId			 0
	MaxSlotId			 3
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ShopGoods
	Room				 Shop
	Container			 SmallTable
	Distribution		 Random
	Condition			 NotLoaded
	MinSlotId			 0
	MaxSlotId			 1
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ShopGoods
	Room				 Shop
	Distribution		 Random
	Condition			 NotLoaded
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 ShopGoods
	Room				 Storage
	Distribution		 Random
	Condition			 NotInRoom
    ConditionTargetRoom  Shop
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             Newspaper
    Container            Table  
    Room                 Staffroom
    Distribution         Random  
    MinSlotId            0  
    MaxSlotId            3
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             Newspaper
    Container            SmallTable  
    Room                 Staffroom
    Distribution         Random  
    MinSlotId            0  
    MaxSlotId            1
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             Newspaper
    Room                 Staffroom
    Distribution         Random  
END

BEGIN Processor
	Processor			 SmallSink
	Input				 FoodTrayDirty
	Output				 FoodTray
	OperatingTime		 4.0
	Object				 SmallSink
	Tool				 CleaningBrush
	Properties			 ShowDuringOperation
	Worker				 Cook
	Worker				 Prisoner
END

BEGIN Processor
	Processor			 SmallWoodenSink
	Input				 FoodTrayDirty
	Output				 FoodTray
	OperatingTime		 4.0
	Object				 SmallWoodenSink
	Tool				 CleaningBrush
	Properties			 ShowDuringOperation
	Worker				 Cook
	Worker				 Prisoner
END

BEGIN Processor
    Processor            SortingTable
    Input                LibraryBookUnsorted
    Output               LibraryBookSorted
    OperatingTime        15.0
    Worker               Prisoner
    AlternateOutput      RuinedBook
    AlternateOutputCount 1
    AlternateOutputChance 0.1
END

#######################################################
#
#  Begin Vending Machines
#
#######################################################

BEGIN ProductionRule       
    Rule                 Storage
    Material             StaffFoodBoxed
    Container            ServingTable  
    Distribution         Random  
    MinSlotId            1  
    MaxSlotId            4
    ContainerCondition   StaffOnly
    Properties           HighPriority
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 StaffFoodBoxed
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 StaffFoodBoxed
	Room				 ColdStorageRoom
	Condition			 NotLoaded
	Distribution		 NonCompeting
	Worker				 Cook
END

BEGIN ProductionRule       
    Rule                 Storage
    Material             StaffFood
    Container            ServingTable  
    Distribution         Random  
    MinSlotId            1  
    MaxSlotId            4
    ContainerCondition   StaffOnly
    Properties           HighPriority
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 StaffFood
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 StaffFood
	Room				 ColdStorageRoom
	Condition			 NotLoaded
	Distribution		 NonCompeting
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 WaterBottle
	Container			 WaterCooler
	Distribution		 Random
	MinSlotId			 2
	MaxSlotId			 2
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 WaterBottle
	Container			 StorageRack
	Room				 ColdStorageRoom
	MinSlotId			 0
	MaxSlotId			 0
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PaperCup
	Container			 WaterCooler
	Distribution		 Random
	MinSlotId			 1
	MaxSlotId			 1
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 PaperCup
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
	MinSlotId			 1
	MaxSlotId			 1
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Orange
	Container			 OrangeJuicer
	Distribution		 NonCompeting
	Worker				 Cook
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Orange
	Container			 OrangeJuicer
	Distribution		 OutOfStock
	Worker				 Cook
	Worker               Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Orange
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
	Properties			 HighPriority
	Condition			 NotLoaded
	MinSlotId			 3
	MaxSlotId			 4
	Worker				 Cook
	Worker				 GardenWorker
	Worker				 Prisoner
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 Orange
	Room				 Exports
	Condition			 NotLoaded
	Distribution		 Random
	Worker				 Prisoner
	Worker				 Workman
	Worker				 GardenWorker
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 OrangeJuice
	Container			 JuiceTable
	Distribution		 Random
    MinSlotId            1
	MaxSlotId			 1
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 OrangeJuice
	Container			 StorageRack
	Room				 ColdStorageRoom
	MinSlotId			 2
	MaxSlotId			 2
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 OrangeJuice
	Container			 OrangeJuicer
	Condition			 NotLoaded
	MinSlotId			 2
	MaxSlotId			 2
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 WaterBottleEmpty
	Room				 Exports
	Distribution		 Random
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingWater
	Container			 WaterVendingMachine
	Distribution		 Random
    MinSlotId            1
	MaxSlotId			 1
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingFruit
	Container			 FruitVendingMachine
	Distribution		 Random
    MinSlotId            1
	MaxSlotId			 1
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingSnack
	Container			 SnackVendingMachine
	Distribution		 Random
    MinSlotId            1
	MaxSlotId			 1
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingSandwich
	Container			 SandwichVendingMachine
	Distribution		 Random
    MinSlotId            1
	MaxSlotId			 1
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingCoffee
	Container			 CoffeeVendingMachine
	Distribution		 Random
    MinSlotId            1
	MaxSlotId			 1
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingWater
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingFruit
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingSnack
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingCoffee
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingSandwich
	Container			 StorageRack
	Room				 ColdStorageRoom
	Distribution		 Random
    MinSlotId            3
	MaxSlotId			 7
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingWater
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingFruit
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingSnack
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Cook
END 

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingSandwich
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingCoffee
	Room				 ColdStorageRoom
	Distribution		 Random
	Condition			 NotLoaded
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 OrangeJuice
	Room				 ColdStorageRoom
	Condition			 NotLoaded
	Worker				 Cook
END

BEGIN ProductionRule
	Rule				 Storage
	Material			 VendingEarnings
	Room				 Exports
	Distribution		 Random
END

BEGIN Processor
	Processor			 OrangeJuicer
	Object				 OrangeJuicer
	Input				 Orange
	Output				 OrangeJuice
	InputCount			 20
	OutputCount			 12
	AlternateOutput		 RottenOrangeTreeFruit
	AlternateOutputChance 0.1
	AlternateOutputCount  20
	OperatingTime		 6
	Worker				 Cook
	Worker				 Prisoner
	Worker				 Workman
END

#######################################################
#
#  End Vending Machines
#
#######################################################
