Skip to content

PocketMine-MP spawning API for NPCs with a talk screen.(This is Proof of concept and currently not working).

License

Notifications You must be signed in to change notification settings

DaisukeDaisuke/npcForm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 

Repository files navigation

npcForm

This plugin has not been developed.

We recommend that you use the following plugins instead.

libNpcDialogue (library, bedrock 1.18+)

https://github.com/refteams/libNpcDialogue

NpcDialog

https://github.com/andresbytes/NpcDialog

NpcForm

https://github.com/ScarceityPvP/NpcForm

DialogueUIAPI

https://github.com/ohYanoox/DialogueUIAPI

_20200702_112544

example

use pocketmine\Player;

use npc\entity\npc;
use npc\chat\SimpleChat;
//$player = $event->getPlayer();
//$level = $player->getLevel();
//$pos = $player->asVector3();

$chat = new SimpleChat(function(Player $player, ?int $response){
	if($response === null){
		$player->sendMessage("canceled");
		return;
	}
	$player->sendMessage((String) $response);
});

$chat->setTitle("title");
$chat->setContents("contents");

$chat->addButton("button0");
$chat->addButton("button1");
$chat->addButton("button2");
$chat->addButton("button3");
$chat->addButton("button4");
$chat->addButton("button5");

$entity = npc::create($pos, $level, $chat);//NPC Entity Spawn

License

NYSL

NYSL English

About

PocketMine-MP spawning API for NPCs with a talk screen.(This is Proof of concept and currently not working).

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages