Skip to content

Conversation

@TATCHAN0825
Copy link

No description provided.

@TATCHAN0825 TATCHAN0825 closed this Jun 6, 2022
@TATCHAN0825 TATCHAN0825 reopened this Jun 6, 2022
@TATCHAN0825
Copy link
Author

<?php
/**
 * @name rpttestpm3
 * @version 0.0.1
 * @main tatchan\rpttestpm3\Main
 * @api 3.0.0
 */

namespace tatchan\rpttestpm3;

use pocketmine\plugin\PluginBase;
use pocketmine\utils\UUID;

class Main extends PluginBase {
    public function onEnable(): void {
        $pluginName = "testplugin";
        echo UUID::fromData($pluginName, "header")->toString() . PHP_EOL;
        //3e89107d-3e09-bec1-ddf3-3bed247b9ff2
    }
}
<?php
/**
 * @name rpttestpm4
 * @version 0.0.1
 * @main tatchan\rpttestpm4\Main
 * @api 4.0.0
 */

namespace tatchan\rpttestpm4;

use pocketmine\plugin\PluginBase;
use Ramsey\Uuid\Uuid;

class Main extends PluginBase {
    public function onEnable(): void {
        $pluginName = "testplugin";
        echo Uuid::fromBytes(md5($pluginName . "header", true))->toString() . PHP_EOL;
        //3e89107d-3e09-bec1-ddf3-3bed247b9ff2
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant