Download this documentation page as a PDF.
Contents
Installation
Before you begin pooling, you will need to follow the steps below to ensure the libraries are installed correctly.
Installing Pure Pool
If you wish to use object pooling from a language other than C#, you should ensure you place the files listed below inside the Plugins folder.
- Ensure the file Umbrace.Unity.PurePool.dll is placed within your Assets folder.
- Ensure the documentation file Umbrace.Unity.PurePool.xml is placed next to the file above.
- Ensure the editor file Umbrace.Unity.PurePool.Editor.dll is placed within your Assets folder, inside an Editor folder.
- Ensure the documentation file Umbrace.Unity.PurePool.Editor.xml is placed next to the file above.
Installing PlayMaker support
A PlayMaker integration library is supplied to help you get started with object pooling from within your PlayMaker FSMs. If you do not own PlayMaker or do not wish to use the integration library, you can delete the file PlayMaker Integration Library.unitypackage.
- Import the integration package PlayMaker Integration Library.unitypackage to your project. Ensure the file Umbrace.Unity.PurePool.PlayMaker.dll is placed within your Assets folder. You should only place it inside the Plugins folder if PlayMaker is installed in the Plugins folder.
Installing UNet support
A Unity Networking (UNet) integration library is supplied to help you use object pooling in your networked game. If you do not wish to use the integration library, you can delete the file UNet Integration Library.unitypackage.
- Import the integration package UNet Integration Library.unitypackage to your project.
- If you wish to use UNet object pooling from a language other than C#, you should ensure you place the imported files inside the Plugins folder.
Please note that UNet has been deprecated, and is no longer recommended for the creation of networked games.
Installing Photon support
Integration scripts are supplied for both Photon Unity Networking Classic and Photon Unity Networking 2, to help you use object pooling in your networked game. If you do not own PUN Classic or PUN2, or do not wish to use the integration script, you can delete the files Photon Integration Library V1.unitypackage and/or Photon Integration Library V2.unitypackage.
- Import the integration package Photon Integration Library V1.unitypackage or Photon Integration Library V2.unitypackage to your project. Ensure the files PrefabPool.cs and PunPoolingSetup.cs are placed within your Assets folder. You should only place them inside the Plugins folder if PUN is installed in the Plugins folder.
An integration script is also included for Photon Bolt. If you do not wish to use Bolt integration, you can delete the file Photon Bolt Integration Library.unitypackage.
- Import the integration package Photon Bolt Integration Library.unitypackage to your project.
Installing Mirror support
A Mirror networking integration script is supplied to help you use object pooling in your networked game. If you do not wish to use the integration library, you can delete the file Mirror Networking Integration Library.unitypackage.
- Import the integration package Mirror Networking Integration Library.unitypackage to your project.
Mirror Networking is an attempt to continue the now deprecated UNet networking. It aims to provide a drop-in replacement for UNet.