Public Member Functions | |
setModalNotificationsEnabled ($value) | |
setModalCollectionsEnabled ($value) | |
setModalCoinsEnabled ($value) | |
getModalNotificationsEnabled () | |
getModalCollectionsEnabled () | |
getModalCoinsEnabled () | |
init () | |
resetDeferredPointTypesAndValuesByUserIdToAdd () | |
getDeferredPointTypesAndValuesByUserIdToAdd () | |
isScoringModelsOnSaveMuted () | |
muteScoringModelsOnSave () | |
unmuteScoringModelsOnSave () | |
muteScoringModelsOnDelete () | |
unmuteScoringModelsOnDelete () | |
initCustom () | |
triggerSearchModelsEvent ($modelClassName) | |
triggerMassEditEvent ($modelClassName) | |
triggerMassDeleteEvent ($modelClassName) | |
triggerImportEvent ($modelClassName) | |
processDeferredPoints () | |
resolveLevelChange () | |
resolveNewCollectionItems () | |
resolveNewBadges () | |
Static Public Member Functions | |
static | addPointsByUserDeferred (User $user, $type, $value) |
Data Fields | |
$enabled = true | |
Protected Member Functions | |
resolveLevelChangeByType ($levelType, GameLevel $currentGameLevel, $pointSumsIndexedByType) | |
Static Protected Member Functions | |
static | resolveSummationValueByLevelTypeAndPointSums ($levelType, $pointSumsIndexedByType) |
static | processLevelChangeGameNotification ($nextLevelValue) |
Protected Attributes | |
$_modalNotificationsEnabled | |
$_modalCollectionsEnabled | |
$_modalCoinsEnabled | |
$scoringModelsOnSaveIsMuted = false | |
$scoringModelsOnDeleteIsMuted = false | |
Helps with game logic exuected during a page request. As scores are added, the point information is tabulated in the GamePointManager so it can then update persistent storage in a single request at the end of the page request.
Definition at line 42 of file GameHelper.php.
initCustom | ( | ) |
Override as needed to customize various aspects of gamification. A few examples of things you can do here: GeneralGameLevelRules::setLastLevel(100); GeneralGameLevelRules::setLevelPointMap($newLevelPointMap);
Definition at line 187 of file GameHelper.php.
triggerSearchModelsEvent | ( | $modelClassName | ) |
string | $modelClassName |
Definition at line 194 of file GameHelper.php.
triggerMassEditEvent | ( | $modelClassName | ) |
string | $modelClassName |
Definition at line 208 of file GameHelper.php.
triggerMassDeleteEvent | ( | $modelClassName | ) |
string | $modelClassName,(mass | delete) |
Definition at line 222 of file GameHelper.php.
triggerImportEvent | ( | $modelClassName | ) |
string | $modelClassName |
Definition at line 236 of file GameHelper.php.
|
static |
Given a user, point type, and value, store the information in the
User | $user | |
String | $type | |
Integer | $value |
Definition at line 254 of file GameHelper.php.
processDeferredPoints | ( | ) |
Process any points that have been added to
Definition at line 274 of file GameHelper.php.
resolveLevelChange | ( | ) |
Called at the end of the page request. Processes anylevel changes for the current user.
Definition at line 304 of file GameHelper.php.
|
protected |
string | $levelType | |
GameLevel | $currentGameLevel | |
array | $pointSumsIndexedByType |
FailedToSaveModelException |
Definition at line 338 of file GameHelper.php.
|
staticprotected |
string | $levelType | |
array | $pointSumsIndexedByType |
Definition at line 378 of file GameHelper.php.
|
staticprotected |
int | $nextLevelValue |
FailedToSaveModelException |
Definition at line 403 of file GameHelper.php.
resolveNewBadges | ( | ) |
Called at the end of the page request. Processes any new badges or badge grade changes for the current user.
Definition at line 427 of file GameHelper.php.