<?php $randomPlayerList = rand(0, 10000); ?>
<?php $randomPlugins = rand(0, 10000); ?>
<?php echo $args['before_widget']; ?>
<?php echo $args['before_title'] . $instance['title'] . $args['after_title']; ?>
<p>
    Status: <span style="color:green;font-weight:bold">Online</span><br>

    <?php if (isset($instance['show_latency']) && $instance['show_latency'] == 'on'): ?>
        Latency: <strong><?php echo $status['latency']; ?>ms</strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_players_max']) && $instance['show_players_max']): ?>
        Players max: <strong><?php echo $status['players_max']; ?></strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_players_online']) && $instance['show_players_online']): ?>
        Players online: <strong><?php echo $status['players_online']; ?></strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_host']) && $instance['show_host'] == 'on'): ?>
        Host: <strong><?php echo $status['server']['host']; ?></strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_ip']) && $instance['show_ip'] == 'on'): ?>
        Ip: <strong><?php echo $status['server']['ip']; ?></strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_port']) && $instance['show_port']): ?>
        Port: <strong><?php echo $status['server']['port']; ?></strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_version']) && $instance['show_version']): ?>
        Version: <strong><?php echo $status['server']['version']; ?></strong><br>
    <?php endif; ?>

    <?php if (isset($instance['show_protocol']) && $instance['show_protocol']): ?>
        Protocol: <strong><?php echo $status['server']['protocol']; ?></strong><br>
    <?php endif; ?>

</p>

<?php echo $args['after_widget']; ?>