# AllocPoolItem

Allocates an item from an item pool.

### Synopsis

`Item AllocPoolItem (ItemPoolPtr itemPool)`

### Description

Allocates an item from the specified item pool. An item pool must be created with `CreateItemPool()` before `AllocPoolItem()` can allocate items from it.

### Arguments

`itemPool`
  Pool of items from which an item is allocated.

### Return Value

Value
  Error Condition

(The first available item)
  None

0
  No items available in pool

### Associated Files

ItemPool.h

### See Also

`CreateItemPool`, ReturnPoolItem