Ошибка: Предупреждение: file_put_contents (/ root / server / plugins / API // root / server / plu gins / SW / stats / win / shenkovdev987.yml): не удалось открыть поток: нет таких файла или каталога в /root/server/src/pocketmine/utils/Config.php o n строка 206 Код: public function register($player, $password){ $nickname = strtolower($player->getName()); $client = $player->getClientId(); $this->authplayer = new Config($this->getDataFolder() .'/auth/player/'.$nickname.'.yml', Config::JSON); $this->wins = new Config($this->getDataFolder() . "/root/server/plugins/SW/stats/win/".$nickname.".yml", Config::YAML); $this->kills = new Config($this->getDataFolder() . "/root/server/plugins/SW/stats/win/".$nickname.".yml", Config::YAML); $hash = $this->hashpassword($password); $this->setSession($player, false); $this->authplayer->set('player', $nickname); $this->kills->set('kills', 0); $this->wins->set('wins', 0); $this->wins->save(); $this->kills->save(); $this->authplayer->set('id', $client); $this->authplayer->set('password', $hash); $this->authplayer->save(); $player->sendMessage('§aВы успешно зарегистрировались.'); }
arning: file_put_contents(/root/server/plugins/ API//root/server/plugins/SW_svile/stats/win/shen kovdev987.yml): failed to open stream: Is a dire ctory in /root/server/src/pocketmine/utils/Confi g.php on line 206 stop
Code: public function register ($ player, $ password) { $ nickname = strtolower ($ player-> getName ()); $ client = $ player-> getClientId (); $ this-> authplayer = new Config ($ this-> getDataFolder (). '/ auth / player /'.$ nickname.'. yml ', Config :: JSON); $ this-> wins = new Config ($ this-> getDataFolder (). "/root/server/plugins/SW/stats/win/".$nickname.".yml", Config :: YAML); $ this-> kills = new Config ($ this-> getDataFolder (). "/root/server/plugins/SW/stats/win/".$nickname.".yml", Config :: YAML); $ hash = $ this-> hashpassword ($ password); $ this-> setSession ($ player, false); $ this-> authplayer-> set ('player', $ nickname); $ this-> kill-> set ('kill', 0); $ this-> wins-> set ('wins', 0); $ this-> wins-> Save (); $ this-> kills-> Save (); $ this-> authplayer-> set ('id', $ client); $ this-> authplayer-> set ('password', $ hash); $ this-> authplayer-> Save (); $ player-> sendMessage ('§aВыуспешно зарегистрировались.'); }