Quantcast

Move state kept in OvaleState into the relevant modules.

Author Johnny C. Lam <jlam88@gmail.com>
Author date 2013-11-10 00:31:29
Author local date 2013-11-10 00:31:29 +0000
Committer Johnny C. Lam <jlam88@gmail.com>
Committer date 2013-11-10 00:31:29
Committer local date 2013-11-10 00:31:29 +0000
Commit 0937d619099495317d38478b523dd0b36743b970
Tree 1595ee41495d2e42cf879cdfc2c1a2c61a6e14f1
Parent 4ead29262bdfab25d6253f70c2fb884112afacb0
Move state kept in OvaleState into the relevant modules.

Each module now manages part of the state for the simulator.  A module
needs to define the following (possibly empty) methods:

    ResetState(state)
    ApplySpellStart(state, ...)
    ApplySpellToPlayer(state, ...)
    ApplySpellToTarget(state, ...)

The module also needs to define a state prototype with additional methods
that should be mixed into the state object maintained by OvaleState.

Modules register/unregister their state for the simulator using:

    OvaleState:RegisterState(...)
    OvaleState:UnregisterState(...)

This de-couples OvaleState from every module that tracks some piece of
information in the game.

git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@1149 d5049fe3-3747-40f7-a4b5-f36d6801af5f