Skip to content

eSports-Alliance/TeamSpeakBundle

Repository files navigation

ESATeamSpeakBundle

Latest Stable Version Total Downloads License

This Bundle give you a connection to a TeamSpeak³-Server. It listen add events and triggered listener in your project.

Installation

Run composer require esports-academy/backup-bundle to use ESATeamSpeakBundle in your Project.

Configuration

Add to AppKernel.php

    class AppKernel extends Kernel
    {
        public function registerBundles()
        {
            $bundles = array(
            new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
            new Symfony\Bundle\SecurityBundle\SecurityBundle(),
            new Symfony\Bundle\TwigBundle\TwigBundle(),
            // ...
            new ESA\TeamSpeakBundle\ESATeamSpeakBundle(),
            // ...
            
            return $bundles;
        }
        // ...
    }

config.yml

    esa_team_speak:
        host: ts.es-a.org       // TeamSpeak-IP
        port: 9987              // TeamSpeak-Port
        query_port: 10011       // Serverquery-Port
        username: serverquery   // Serverquery-Username
        password: p4ssw0rd      // Serverquery-Password
        nickname: James         // Nickname
        timeout: 10             // Timeout in Seconds

Usage

Create your method

AppBundle/TeamSpeakBot/ClientListener.php

    class TeamSpeakBot {
        public function onClientEnterView($event) {
            // do stuff
        }
    }

Register your method

services.yml

    services:
        AppBundle\TeamSpeakBot\ClientListener:
            tags:
                - { name: kernel.event_listener, event: teamspeak.client_enter_view, method: onClientEnterView }            

Run the bot

To run the bot execute php bin/console teamspeak:bot:run or php bin/console teamspeak:bot:start for background job.

Roadmap

Here are some functions we will be include in future.

  • adding functions to manipulate the bot outisde of events

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published