All Projects → PMVirion → libMiniGame

PMVirion / libMiniGame

Licence: MIT license
[Plugin][lib] This plugin is an API that makes it easy to implement MiniGame.

Programming Languages

PHP
23972 projects - #3 most used programming language

Projects that are alternatives of or similar to libMiniGame

MurderMystery
Protect innocents from Murderer and kill him!
Stars: ✭ 155 (+573.91%)
Mutual labels:  minigame, minigame-plugin
VirionTools
A handy plugin for developers who wish to compile and inject virions without using Poggit.
Stars: ✭ 17 (-26.09%)
Mutual labels:  pmmp, virion
NpcDialog
🗽 PocketMine-MP virion to add dialogs to entities easily
Stars: ✭ 55 (+139.13%)
Mutual labels:  pmmp, virion
PMEssentials
A collection of essential PMMP commands, features and more. Heavily inspired by Essentials
Stars: ✭ 13 (-43.48%)
Mutual labels:  pmmp
KitUI
Advance AdvancedKits! Select Kits from a form, just do /kit and get kits info and select it if available! For Minecraft Bedrock Edition!
Stars: ✭ 44 (+91.3%)
Mutual labels:  pmmp
CosmeticMenu
Fun and Easy-to-Use Pocketmine Cosmetics plugin. (Gadgets, Particles, Trails, etc)
Stars: ✭ 22 (-4.35%)
Mutual labels:  pmmp
skinapi
A virion library for saving, modifying and getting skins from png's
Stars: ✭ 19 (-17.39%)
Mutual labels:  pmmp
RedstoneCircuit
This is the PocketMine plugin that implements the Redstone circuit.
Stars: ✭ 81 (+252.17%)
Mutual labels:  pmmp
ServerTools
ServerTools is Pocketmine-MP plugin containing a set of tools that allows you to manage your server directly from the game!
Stars: ✭ 23 (+0%)
Mutual labels:  pmmp
Xakkit
Server Software for Minecraft
Stars: ✭ 27 (+17.39%)
Mutual labels:  pmmp
ProfileUI
Get any player's profile on a Modal Form! MCPE v1.2! PMMP support only!
Stars: ✭ 20 (-13.04%)
Mutual labels:  pmmp
Form Json
JSON mode for mcpe 1.2's ModalFormRequestPacket
Stars: ✭ 15 (-34.78%)
Mutual labels:  pmmp
Offhand
A PocketMine-MP Plugin that implements OffHand (and OffHandInventory)
Stars: ✭ 36 (+56.52%)
Mutual labels:  pmmp
libform
It is a virion library that can handle various forms easily.
Stars: ✭ 12 (-47.83%)
Mutual labels:  virion
Flint
A Minecraft minigame engine.
Stars: ✭ 22 (-4.35%)
Mutual labels:  minigame
FakePlayer
Specter but targeting PocketMine-MP API 4.0.0
Stars: ✭ 46 (+100%)
Mutual labels:  pmmp
CustomItemLoader
This is a plugin that brings the custom item to your server for PocketMine-MP!
Stars: ✭ 87 (+278.26%)
Mutual labels:  pmmp
mp-ci
微信小程序、小游戏发布助手(CI)
Stars: ✭ 76 (+230.43%)
Mutual labels:  minigame
DungeonPlus
[Plugin] A Plugin support Dungeon API.
Stars: ✭ 14 (-39.13%)
Mutual labels:  pmmp
ScoreFactory
A simple virion for making Scoreboards in Minecraft Bedrock Edition.
Stars: ✭ 15 (-34.78%)
Mutual labels:  virion

MiniGameAPI

Tools that make it easy for developers to create MiniGames.

PHP Version: 8.0.9

Usage

Write the code below in the onEnable method of the minigame plugin you are creating.

public function onEnable() : void{
    if(!MiniGameHandler::isRegistered()){
        MiniGameHandler::register($this);
    }
}


Team overrides are as follows:

final class ColorMatchRoom extends MiniGameRoom{
	
	public function __construct(
		string $name,
		int $minPlayerCount, 
		int $maxPlayerCount, 
		Plugin $plugin, 
		int $gamemode = self::GAMEMODE_DEFAULT, 
		array $players = [], 
		?MiniGameTeamManager $teamManager = null){
		parent::__construct($name, $minPlayerCount, $maxPlayerCount, $plugin, $gamemode, $players, $teamManager);
	}
}


This plugin supports team features. If you create a game room without using the team feature.

final class RedTeam extends MiniGameTeam{}
final class BlueTeam extends MiniGameteam{}

$teamManager = new MiniGameTeamManager(
    new RedTeam("RED", []),
    new BlueTeam("BLUE", [])
);


This library manages the player's inventory.

$invManager = PlayerInventoryManager::getInstance();

You can save or load the player's inventory.

public function onPlayerJoinEvent(PlayerJoinEvent $event) : void{
    $invManager = PlayerInventoryManager::getInstance();
    $invManager->send($event->getPlayer());
}
public function onPlayerQuitEvent(PlayerQuitEvent $event) : void{
    $invManager = PlayerInventoryManager::getInstance();
    $invManager->save($event->getPlayer());
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].