Skip to content

Commit

Permalink
Release V1.6.2
Browse files Browse the repository at this point in the history
- fixed #32
- code cleanup
  • Loading branch information
supercrafter333 committed Mar 7, 2022
1 parent 38b05e9 commit 6dfaa94
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 17 deletions.
5 changes: 3 additions & 2 deletions .changlogs.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,8 @@ End of theSpawn PM3 support
- *[POGGIT]* - forms are no longer dispatching commands
- *[VERSION]* - Version bump

### Changelog V1.6.1 » V1.6.2-DEV
> This version does contain some major code changes from the previous version. It's only a code cleanup, feature and bug fix update.
### Changelog V1.6.1 » V1.6.2
> This version does contain some code changes from the previous version. It's only a code cleanup and bug fix update.
- *[FIXED]* - TPA's cannot be awnsered ([#32](https://github.com/supercrafter333/theSpawn/issues/32))
- *[CLEANUP]* - sourced out events from `theSpawn.php` to `EventListener.php`
- *[VERSION]* - Version bump
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
> This version is under development and can contain bugs!
[![Discord](https://img.shields.io/badge/chat-on%20discord-7289da.svg)](https://discord.gg/ca6cWPpERp)
# theSpawn - V1.6.2-DEV [![](https://poggit.pmmp.io/shield.state/theSpawn)](https://poggit.pmmp.io/p/theSpawn) [![](https://poggit.pmmp.io/shield.dl.total/theSpawn)](https://poggit.pmmp.io/p/theSpawn)
# theSpawn - V1.6.2 [![](https://poggit.pmmp.io/shield.state/theSpawn)](https://poggit.pmmp.io/p/theSpawn) [![](https://poggit.pmmp.io/shield.dl.total/theSpawn)](https://poggit.pmmp.io/p/theSpawn)

**This plugin is a much better MSpawns alternative! Help me to make this plugin better!**

Expand Down
2 changes: 1 addition & 1 deletion plugin.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: theSpawn
version: 1.6.2-DEV
version: 1.6.2
api: 4.0.0
main: supercrafter333\theSpawn\theSpawn
author: supercrafter333
Expand Down
2 changes: 1 addition & 1 deletion resources/Languages/en_BE.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ no-spawn-set-for-world: "§cThere's no spawn set for world {world}!"



#compatible with v1.6.2-DEV (and lower)
#compatible with v1.6.2 (and lower)


############################
Expand Down
2 changes: 1 addition & 1 deletion resources/Languages/ger_DE.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ no-spawn-set-for-world: "§cEs wurde noch kein Spawn für die Welt {world} festg



#compatible with v1.6.2-DEV (and lower)
#compatible with v1.6.2 (and lower)


############################
Expand Down
2 changes: 1 addition & 1 deletion resources/Languages/messages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ no-spawn-set-for-world: "§cThere's no spawn set for world {world}!"


#don't change this
version: "1.6.2-DEV"
version: "1.6.2"


############################
Expand Down
2 changes: 1 addition & 1 deletion resources/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ language: "en_BE"


#DON'T CHANGE THIS!!
version: "1.6.2-DEV"
version: "1.6.2"

############################
##########theSpawn##########
Expand Down
10 changes: 5 additions & 5 deletions src/supercrafter333/theSpawn/Commands/TpacceptCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,20 +51,20 @@ public function execute(CommandSender $s, string $commandLabel, array $args): vo
$s->sendMessage($this->usageMessage);
return;
}
if (!$pl->hasTpaOf($args[0], $s->getName())) {
if (!$pl->hasTpaOf($s->getName(), $args[0])) {
$s->sendMessage(str_replace("{target}", (string)$args[0], MsgMgr::getMsg("no-pending-tpa")));
return;
}
$tpaInfo = new TpaInfo($s->getName());
$tpaInfo = new TpaInfo($args[0]);
if (!$tpaInfo->getTargetAsPlayer() instanceof Player) {
$s->sendMessage(str_replace("{target}", (string)$args[0], theSpawn::$prefix . MsgMgr::getMsg("player-not-online")));
$s->sendMessage(str_replace("{target}", (string)$args[0], theSpawn::$prefix . MsgMgr::getMsg("player-not-found")));
return;
}
$target = $tpaInfo->getTargetAsPlayer();
$name = $target->getName();
$tpaInfo->complete();
$target->sendMessage(str_replace("{target}", $name, theSpawn::$prefix . MsgMgr::getMsg("tpa-accepted-source")));
$s->sendMessage(str_replace("{source}", $s->getName(), theSpawn::$prefix . MsgMgr::getMsg("tpa-accepted-target")));
$s->sendMessage(str_replace("{target}", $name, theSpawn::$prefix . MsgMgr::getMsg("tpa-accepted-source")));
$target->sendMessage(str_replace("{source}", $s->getName(), theSpawn::$prefix . MsgMgr::getMsg("tpa-accepted-target")));
}

/**
Expand Down
5 changes: 1 addition & 4 deletions src/supercrafter333/theSpawn/theSpawn.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,10 @@ class theSpawn extends PluginBase
/**
* @var string
*/
public string $version = "1.6.2-DEV";
public string $version = "1.6.2";


/**
* On plugin loading. (That's before enabling)
* On plugin loading. (That's before enabling)
*/
public function onLoad(): void
Expand Down Expand Up @@ -116,7 +115,6 @@ public function onEnable(): void
}
$this->aliasCfg = new Config($this->getDataFolder() . "aliaslist.yml", Config::YAML);
$this->warpCfg = new Config($this->getDataFolder() . "warps.yml", Config::YAML);
$aliasCfg = new Config($this->getDataFolder() . "aliaslist.yml", Config::YAML);
$cmdMap->registerAll("theSpawn",
[
new SpawnCommand("spawn"),
Expand Down Expand Up @@ -299,7 +297,6 @@ public function addTpa(string $source, string $target, bool $isTpaHere = false):
{
if (isset($this->TPAs[$source])) return false;
$arr = ["target" => $target, "isTpaHere" => $isTpaHere];
$this->TPAs[] = $source;
$this->TPAs[$source] = $arr;
return true;
}
Expand Down

0 comments on commit 6dfaa94

Please sign in to comment.