mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-06-28 00:24:23 +00:00
Fix vacation mode
This commit is contained in:
@@ -148,12 +148,6 @@ class Units {
|
||||
$id = $generator->getBaseID($coor['x'],$coor['y']);
|
||||
if (!$database->getVillageState($id)){
|
||||
$form->addError("error","Coordinates do not exist");
|
||||
//check vaction mode- by advocaite
|
||||
if($database->getUserField($_POST['user'],"vac_mode",1) == 1){
|
||||
//if($database->getvacmodexy($id)){
|
||||
$form->addError("error","User is on vacation mode");
|
||||
}
|
||||
//END Vaction mode check
|
||||
}
|
||||
}
|
||||
if (!empty($coor)) {
|
||||
@@ -191,6 +185,12 @@ class Units {
|
||||
$form->addError("error","Player is Banned. You can't attack him");
|
||||
//break;
|
||||
}
|
||||
//check if vacation mode:
|
||||
$villageOwner = $database->getVillageField($id,'owner');
|
||||
if($database->getvacmodexy($id)){
|
||||
$form->addError("error","User is on vacation mode");
|
||||
//break;
|
||||
}
|
||||
|
||||
//check if attacking same village that units are in
|
||||
if($id == $village->wid){
|
||||
|
||||
Reference in New Issue
Block a user