Classes | Public Member Functions | Public Attributes

DiceMaster.Spawner Class Reference

Attach this to any GameObject to make it spawn dice. More...

List of all members.

Classes

class  SpawnDiceEvent

Public Member Functions

virtual Vector3 GetSpawnPosition (int index)
 Gets the spawn position for a given dice in the array Virtual, so it can be extended with different spawn rules.
void Trigger ()
 Called when we want to spawn new dice.

Public Attributes

GameObject dicePrefab
bool triggerOnStart = true
int nSpawn = 1
int span = 5
bool randomizeInitialRotation = true
SpawnDiceEvent onSpawnDice

Detailed Description

Attach this to any GameObject to make it spawn dice.

This will spawn dice in a grid when triggered. Will also automatically work with any Thrower or Spinner.


Member Function Documentation

virtual Vector3 DiceMaster.Spawner.GetSpawnPosition ( int  index  )  [virtual]

Gets the spawn position for a given dice in the array Virtual, so it can be extended with different spawn rules.

Parameters:
index index of the dice to spawn in the array
Returns:
The position the dice should be spawned at
void DiceMaster.Spawner.Trigger (  ) 

Called when we want to spawn new dice.


Member Data Documentation


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Properties Defines