2017 © Pedro Peláez
 

symfony-bundle fm-steamcondenser-bundle

Symfony SteamcondenserBundle

image

marioz2002/fm-steamcondenser-bundle

Symfony SteamcondenserBundle

  • Wednesday, May 20, 2015
  • by Mario2002
  • Repository
  • 0 Watchers
  • 0 Stars
  • 7 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

FMSteamcondenserBundle

Add some Steam[http://steampowered.com] to your Symfony 2 project!, (*1)

This bundle allows you to query game servers, getting information about players/Steam users, getting server information, such as current player list and etc. Bundle depends on Steam Condenser library by Sebastian Staudt, (*2)

This Bundle status is WIP (work in progress), (*3)

Installation

To install this bundle, you'll need both the Steam Condenser and this bundle., (*4)

Step 1: Installation

Using Composer, just add the following configuration to your composer.json:, (*5)

{
    "require": {
        "helios-ag/fm-steamcondenser-bundle": "dev-master"
    }
}

Now tell composer to download the bundle by running the command:, (*6)

``` bash $ php composer.phar update helios-ag/fm-steamcondenser-bundle, (*7)


## Step 2: Enable the bundle Finally, enable the bundle in the kernel: ``` php <?php // app/AppKernel.php public function registerBundles() { $bundles = array( // ... new FM\SteamcondenserBundle\FMSteamcondenserBundle(), ); }

Configuration

Before using this you need to configure bundle:, (*8)

fm_steamcondenser:
  server_list:
    my_server:
      address: 127.0.0.1
      port: 27015
      password: passw0rd
      source: true

Under server_list node, you can define multiple servers. Each server has address - an ip address of the server, and port. Password field used to set Rcon (remote console) password. Source option, defines, is server uses source based engine or not (games like Team Fortress 2, Half-Life 2, CS:S and many others Valve games, but not Half-Life 1, CS 1.6), (*9)

Command line tools

Bundle provide some useful CLI commands, to survey servers, get information about steam users,, (*10)

Rcon command

php app/console steam:rcon [server] [command]

Send rcon command to server, syntax is [server] - server alias, defined in configuration, for example "my_server" [command] - command to send, (*11)

Server Info Command

php app/console steam:serverinfo [server] --ip [ip] --port [port] --showplayers

Show server information, like server name, game, list current players, ping. Arguments: [server] - server alias defined in configuration, (*12)

Optional parameters: --ip and --port options can be used to define server explicitly via CLI (in this case you omit server alias) --showplayers - show current players on server, (*13)

User Info Command

php app/console steam:userinfo [username/steamID]

Accept Steam ID (64 bit unique number) or Steam user name, (*14)

Show username and list of available games. Also shows user current nickname and his online status., (*15)

Server List Command

php app/console steam:serverlist

Show list of defined servers via config.yml, (*16)

Services

Work in progress, (*17)

Twig Extensions

Currently available two twig extensions (actually widgets):, (*18)

 {{steam_server(ip,port,source)}}

Show server information. List curent players and etc. Arguments: ip - ip address server port - server port source - true or false, true if source based server, false otherwise, (*19)

 {{steam_user(steamID || steam name,showgames)}}

Show STEAM user information. Avatar and games. Provied link to user profile. Accept steamID or steam nickname. Parameters: showgames - boolean (true||false), specifies show list of games or no, belonged to user., (*20)

Translations

Currently two language supported: English and Russian, feel free to contribute., (*21)

The Versions