'지난 턴'을 관리하는 기능 추가

This commit is contained in:
2018-10-03 22:38:05 +09:00
parent a33a7317cc
commit e1a266e5d8
11 changed files with 114 additions and 45 deletions
+13
View File
@@ -13,6 +13,19 @@ trait LazyVarUpdater{
return $this->raw[$key];
}
function touchVar(string $key):bool{
if(key_exists($key, $this->raw)){
return false;
}
$this->raw[$key] = null;
return true;
}
function setVar(string $key, $value){
return $this->updateVar($key, $value);
}
function updateVar(string $key, $value){
if($this->raw[$key] === $value){
return;