Catastrophe
Each player suffers 4 damage for each facility and 10 resources he has
Cost (B / G / R)
0 / 25 / 0
BB code
Effect
Each player suffers 4 damage for each facility and 10 resources he has
Code
$my_fac = $t->myData()->Quarry + $t->myData()->Magic + $t->myData()->Dungeons;
$his_fac = $t->hisData()->Quarry + $t->hisData()->Magic + $t->hisData()->Dungeons;
$my_res = $t->myData()->Bricks + $t->myData()->Gems + $t->myData()->Recruits;
$his_res = $t->hisData()->Bricks + $t->hisData()->Gems + $t->hisData()->Recruits;
$t->myData()->attack(($my_fac + floor($my_res / 10)) * 4);
$t->hisData()->attack(($his_fac + floor($his_res / 10)) * 4);