From bf393a56f1cd358a165af7c9c727ec3faa03cdbd Mon Sep 17 00:00:00 2001 From: Max Klaversma Date: Thu, 17 Apr 2014 20:24:31 +0200 Subject: [PATCH] Added get dedimania records function --- application/plugins/Dedimania/Dedimania.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/application/plugins/Dedimania/Dedimania.php b/application/plugins/Dedimania/Dedimania.php index 6d0e8bd6..286ad7d0 100644 --- a/application/plugins/Dedimania/Dedimania.php +++ b/application/plugins/Dedimania/Dedimania.php @@ -784,6 +784,19 @@ class Dedimania implements CallbackListener, TimerListener, Plugin { return array('UId' => $map->uid, 'GameMode' => $gameMode); } + /** + * Function to retrieve the dedimania records on the current map + * + * @return array|RecordData + */ + public function getDedimaniaRecords() { + if (!$this->dedimaniaData->records) { + return new RecordData(null); + } + $records = $this->dedimaniaData->records; + return $records; + } + /** * Get the dedimania record of the given login *