feat: UniqueConst에 숨겨진 hiddenSeed 생성
- 이후 RNG에 사용
This commit is contained in:
@@ -5,6 +5,7 @@ class UniqueConst{
|
|||||||
public static $serverID = '_tK_serverID_';
|
public static $serverID = '_tK_serverID_';
|
||||||
public static $serverName = '_tK_serverName_';
|
public static $serverName = '_tK_serverName_';
|
||||||
public static $seasonIdx = '_tK_seasonIdx_';
|
public static $seasonIdx = '_tK_seasonIdx_';
|
||||||
|
public static $hiddenSeed = '_tK_hiddenSeed_';
|
||||||
|
|
||||||
private function __construct(){}
|
private function __construct(){}
|
||||||
|
|
||||||
|
|||||||
@@ -93,12 +93,15 @@ class ResetHelper{
|
|||||||
$gameStor->resetCache();
|
$gameStor->resetCache();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$hiddenSeed = bin2hex(random_bytes(16));//32byte, 128bit random seed
|
||||||
|
|
||||||
$result = Util::generateFileUsingSimpleTemplate(
|
$result = Util::generateFileUsingSimpleTemplate(
|
||||||
$servRoot.'/d_setting/UniqueConst.orig.php',
|
$servRoot.'/d_setting/UniqueConst.orig.php',
|
||||||
$servRoot.'/d_setting/UniqueConst.php',[
|
$servRoot.'/d_setting/UniqueConst.php',[
|
||||||
'serverID'=>$serverID,
|
'serverID'=>$serverID,
|
||||||
'serverName'=>ServConfig::getServerList()[$prefix]->getKorName(),
|
'serverName'=>ServConfig::getServerList()[$prefix]->getKorName(),
|
||||||
'seasonIdx'=>$seasonIdx,
|
'seasonIdx'=>$seasonIdx,
|
||||||
|
'hiddenSeed'=>$hiddenSeed,
|
||||||
], true
|
], true
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user