package net.cobem.grizzly.habbohotel.misc.commands;

import net.cobem.grizzly.Grizzly;
import net.cobem.grizzly.communication.composers.misc.SendNotificationComposer;
import net.cobem.grizzly.habbohotel.misc.ChatCommand;
import net.cobem.grizzly.habbohotel.sessions.Session;

public class OfficialStream implements ChatCommand {
    @Override
    public int rank() {
        return 6;
    }

    @Override
    public void execute(Session session, String[] args) {
        if (args.length < 1) {
            session.sendResponse(SendNotificationComposer.compose("Invalid number of arguments!"));
            return;
        }

        String Message = null;
        int Key = 0;

        for (String Whatever : args) {
            if (Key == 0) {
                Message = Whatever;
            } else {
                Message += " " + Whatever;
            }

            Key++;
        }
        Grizzly.getHabboHotel().getStream().addOfficial(Message);
    }
}
