U3Games

Games | Desarrollo & Soporte => L2 | Sección Web => Lineage => L2 | Codes Web => Mensaje iniciado por: Swarlog en Jun 13, 2025, 11:50 PM

Título: Raid Boss On/Off Status, Respawn Time
Publicado por: Swarlog en Jun 13, 2025, 11:50 PM
<html>
<head>
<title>
Raid Boss Information
</title>
</head>
<body>
<table>
<tr><td>Name</td><td>Status</td><td>Spawn</td></tr>
<?php$hostname = "localhost"; // server ip$database = "l2jdb"; // mysql database$user = "root"; // mysql username$pass = "password"; // mysql password$connect = @mysql_connect($hostname, $user, $pass);@mysql_select_db($database, $connect);if(!$connect)echo 'Can\'t connect to the database';else{$raidspawn = mysql_query("SELECT boss_id,respawn_time FROM raidboss_spawnlist ORDER BY respawn_time DESC");while(list($boss_id,$respawn_time) = mysql_fetch_row($raidspawn)){	$raidnames = mysql_query("SELECT name FROM npc WHERE id = $boss_id");	$text = '<font color="00FF00">Alive</font>';	$respawn = '<font color="0000FF">Spawn</font>';	if($respawn_time > 0)	{		$respawntime = date('r',($respawn_time / 1000));		$text = '<font color="FF0000">Alive</font>';		$respawn = '<font color="FF0000">Respawn in '.$respawntime.'</font>';	}	while(list($raidname) = mysql_fetch_row($raidnames))	{		echo '<tr><td>'.$raidname.'</td><td>'.$text.'</td><td>'.$respawn.'</td></tr>';	}}}?>

</table>
</body>
</html>