CEL

Public API Reference

iLootGenerator Struct Reference

Loot generator. More...

#include <tools/loot.h>

Inheritance diagram for iLootGenerator:

List of all members.

Public Member Functions

virtual bool GenerateLoot (iPcInventory *inventory, iCelParameterBlock *params)=0
 Generate loot in an inventory.
virtual const char * GetName () const =0
 Get the name of this generator.

Detailed Description

Loot generator.

Both loot packages as loot selectors (see below) are loot generators.

Definition at line 31 of file loot.h.


Member Function Documentation

virtual bool iLootGenerator::GenerateLoot ( iPcInventory inventory,
iCelParameterBlock params 
) [pure virtual]

Generate loot in an inventory.

The inventory doesn't have to be empty for this to work. If there are already items in the inventory then the loot is simply added. If the constraints are set too strict then it is possible that no loot can ever be generated. The given parameter block should at the very least contain 'this' as the current entity. This function returns false in case the inventory rejected (part) of the generated loot. In that case it is possible that part of the loot was added.

virtual const char* iLootGenerator::GetName (  )  const [pure virtual]

Get the name of this generator.


The documentation for this struct was generated from the following file:

Generated for CEL: Crystal Entity Layer 2.1 by doxygen 1.6.1