Skip to content
This repository has been archived by the owner on Jul 7, 2020. It is now read-only.

Commit

Permalink
Bugfixes (#38)
Browse files Browse the repository at this point in the history
- Make compatible with other UI plugins
  • Loading branch information
Awzaw authored and Infernus101 committed Dec 2, 2017
1 parent 4c7b549 commit 09103fc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/Infernus101/KitUI/Main.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class Main extends PluginBase implements Listener {
public $kitused = [];
public $language;
public $piggyEnchants;
public $config;

public function onEnable(){
@mkdir($this->getDataFolder()."timer/");
Expand Down
6 changes: 3 additions & 3 deletions src/Infernus101/KitUI/PlayerEvents.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ public function onDataPacket(DataPacketReceiveEvent $event){
return;
}
$windowHandler = new Handler();
$packet->formId = $windowHandler->getWindowIdFor($packet->formId);
if(!$windowHandler->isInRange($packet->formId)) {
$formId = $windowHandler->getWindowIdFor($packet->formId);
if(!$windowHandler->isInRange($formId)) {
return;
}
$window = $windowHandler->getWindow($packet->formId, $this->pl, $event->getPlayer());
$window = $windowHandler->getWindow($formId, $this->pl, $event->getPlayer());
$window->handle($packet);
}
}
Expand Down

1 comment on commit 09103fc

@XoticRealmsOwnerandDev
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this plugin use formapi now?

Please sign in to comment.