InfinityGamers / HungerGames-UPDATED

A HungerGames plugin for PocketMine-MP developed by xBeastMode
45 stars 24 forks source link

Support for Plugin #89

Open Alemiz112 opened 5 years ago

Alemiz112 commented 5 years ago

Hi, I made pocketmine plugin called SlivockyStats! I want to ask If you can add some code to support my rating system and Ranks ?

https://github.com/Alemiz112/SlivockyStats

Thanks

xBeastMode commented 5 years ago

interesting. how would i do that?

Alemiz112 commented 5 years ago

If someone die, kill someone, won it will save that datas to config. You will make simple function whitch I will be able to call from my plugin, like:

$data = $this->plugin->getServer()->getPluginManager()->getPlugin('HungerGames')->getData(0);

It must be returned as array to make me able to create Stats:

arsort($data); foreach ($data as $name => $kills) {}

You can find more here: My HungerGames

You can too add there option to XP Ranks: $ranks = $this->plugin->getServer()->getPluginManager()->getPlugin("SlivockyStats"); if ($ranks !== null){ $ranks->provider->addXP($killer, 2); }

Alemiz112 commented 5 years ago

Artulloss why that ?