public class bonus extends Functions implements ScriptFile
{
private boolean HaveBonus(String type)
{
L2Player player = (L2Player) getSelf();
ResultSet rs = null;
ThreadConnection con = null;
FiltredPreparedStatement offline = null;
Calendar end_;
end_ = Calendar.getInstance();
try
{
con = L2DatabaseFactory.getInstance().getConnection();
offline = con.prepareStatement("SELECT bonus_expire_time FROM bonus WHERE obj_id LIKE ? AND bonus_name = ?");
offline.setInt(1, player.getObjectId());
offline.setString(2, type);
rs = offline.executeQuery();
if(rs.next())
{
end_.setTimeInMillis(rs.getLong(1) * 1000L);