com.threerings.puzzle.drop.server

## Class DropManagerDelegate

- java.lang.Object
- - com.threerings.crowd.server.PlaceManagerDelegate
  - - com.threerings.parlor.server.PlayManagerDelegate
    - - com.threerings.parlor.game.server.GameManagerDelegate
      - - com.threerings.puzzle.server.PuzzleManagerDelegate
        - - com.threerings.puzzle.drop.server.DropManagerDelegate

All Implemented Interfaces:
  com.threerings.presents.data.InvocationCodes, PuzzleCodes, PuzzleGameCodes, DropCodes

    public abstract class DropManagerDelegate
    extends PuzzleManagerDelegate
    implements PuzzleCodes, DropCodes

Provides the necessary support for a puzzle game that involves a two-dimensional board containing pieces, with new pieces either falling into the board as a "drop block", or rising into the bottom of the board in new piece rows, groups of blocks can be "broken" and garbage can be sent to other players' boards as a result. This is implemented as a delegate so that the natural hierarchy need not be twisted to differentiate between puzzles that use piece dropping and those that don't. Because we have need to structure our hierarchy around things like whether a puzzle is a duty puzzle, this becomes necessary.

A puzzle game using these services will then need to extend this delegate, implementing the necessary methods to customize it for the particulars of their game and then register it with their game manager via `PlaceManager.addDelegate(com.threerings.crowd.server.PlaceManagerDelegate)`.

It also keeps track of, for each player, board level information, and player game status. Miscellaneous utility routines are provided for checking things like whether the game is over, whether a player is still active in the game, and so forth.

Derived classes are likely to want to override `getPieceDropLogic()`.

### Field Summary

### Fields inherited from interface com.threerings.puzzle.data.PuzzleCodes

`DEBUG_PUZZLE, DEFAULT_DIFFICULTY, PUZZLE_MESSAGE_BUNDLE`

### Fields inherited from interface com.threerings.presents.data.InvocationCodes

`ACCESS_DENIED, E_ACCESS_DENIED, E_INTERNAL_ERROR, GLOBAL_GROUP, INTERNAL_ERROR`

### Fields inherited from interface com.threerings.puzzle.drop.data.DropCodes

`DROP_MESSAGE_BUNDLE, DROP_STREAM, RISE_STREAM`

### Constructor Summary

Constructors
Constructor and Description
`DropManagerDelegate(DropLogic logic)` Creates a drop manager delegate with a logic that it uses to determine how to manage the drop puzzle.
`DropManagerDelegate(PuzzleManager puzmgr, DropLogic logic)` Deprecated. use `DropManagerDelegate(DropLogic)`.

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `didInit(com.threerings.crowd.data.PlaceConfig config)`
`void` `didStartup(com.threerings.crowd.data.PlaceObject plobj)`
`void` `gameWillStart()` Called by the game manager when the game is about to start.

### Methods inherited from class com.threerings.parlor.game.server.GameManagerDelegate

`gameDidEnd, gameDidStart, gameWillEnd, gameWillReset, playerWasReplaced, setAI, tickAI`

### Methods inherited from class com.threerings.crowd.server.PlaceManagerDelegate

`bodyEntered, bodyLeft, bodyUpdated, didShutdown, init, placeBecameEmpty, where`

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### DropManagerDelegate

    @Deprecated
    public DropManagerDelegate(PuzzleManager puzmgr,
                                           DropLogic logic)

Deprecated. use `DropManagerDelegate(DropLogic)`.

#### DropManagerDelegate

    public DropManagerDelegate(DropLogic logic)

Creates a drop manager delegate with a logic that it uses to determine how to manage the drop puzzle.

### Method Detail

#### didInit

    public void didInit(com.threerings.crowd.data.PlaceConfig config)

Overrides:
  `didInit` in class `PuzzleManagerDelegate`

#### didStartup

    public void didStartup(com.threerings.crowd.data.PlaceObject plobj)

Overrides:
  `didStartup` in class `com.threerings.crowd.server.PlaceManagerDelegate`

#### gameWillStart

    public void gameWillStart()

Description copied from class: `GameManagerDelegate`
Called by the game manager when the game is about to start.

Overrides:
  `gameWillStart` in class `GameManagerDelegate`