readingNotice['data']); // ======================== CONFIG ======================== $hasHero = (!empty($dataarray[14]) && $dataarray[14] > 0); $colspan = $hasHero ? 11 : 10; // ======================== EVENT TYPE ======================== $attackerId = $dataarray[0]; $targetId = $dataarray[2]; $type = isset($dataarray[15]) ? (int)$dataarray[15] : 0; // CACHE DB CALLS (reduce repeated queries) $attackerName = $database->getUserField($attackerId, "username", 0); $attackerUid = $database->getUserField($attackerId, "id", 0); $targetName = $database->getUserField($targetId, "username", 0); // ======================== MESSAGE BUILD ======================== if ($type == 1) { $message1 = $attackerName." visited ".$targetName."'s troops"; } elseif ($type == 2) { $message1 = $attackerName." wishes you Merry Christmas"; } elseif ($type == 3) { $message1 = $attackerName." wishes you Happy New Year"; } else { $message1 = $attackerName." wishes you Happy Easter"; } ?> procMtime($message->readingNotice['time']); ?>
Subject: readingNotice['topic']; ?>
Sent: on hour
getUnitName($i); echo ""; } // HERO if ($hasHero) { echo ""; } echo ""; // TROOPS for ($i = 4; $i <= 13; $i++) { echo ($dataarray[$i] == 0) ? "" : ""; } // HERO TROOPS if ($hasHero) { echo ""; } ?>
Attacker from the village getVillageField($dataarray[1], "name"); ?>
  \"$unitName\"\"Hero\"
Troops0".$dataarray[$i]."".$dataarray[14]."
Information Event