Skip to content

Latest commit

 

History

4 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

SWGEmu IRC Status Bot

A simple Node.js bot that listened to the SWGEmu IRC status channel and automatically posted server status updates to Twitter.

⚠️ This project is archived and no longer maintained. It was originally built before the Twitter/X API changes and is unlikely to work without significant modifications.


Overview

This bot was designed to bridge the SWGEmu IRC network with Twitter.

Whenever the SWGEmu status bot announced a server status change or update in IRC, this application parsed the message into a cleaner, more readable format and automatically published it as a tweet.

It was intended to provide players with quick status updates without requiring them to join the IRC server.


Features

  • 📡 Connects to an IRC server
  • 👂 Listens to a dedicated status channel
  • 🔍 Parses SWGEmu server status messages
  • 📝 Extracts:
    • Server name
    • Online/Offline status
    • Current player count
    • Server uptime
    • Maximum capacity (when available)
  • 🐦 Automatically posts formatted updates to Twitter
  • 📜 Console logging for debugging

Example

IRC Message

Current Basilisk ONLINE --- Users: 1245 --- Uptime: 18 days 5 hours --- Maximum Capacity: 3000

Tweet

Current Basilisk status is ONLINE - Users: 1245 - Uptime: 18 days 5 hours - Maximum Capacity: 3000 #SWGEmu

Technologies

  • Node.js
  • irc
  • twitter

Installation

git clone https://github.com/yourusername/swgemu-irc-status-bot.git

cd swgemu-irc-status-bot

npm install

Configuration

Edit the configuration section inside the source file.

const IRC_CHANEL = '#status';
const IRC_HOST = 'irc.swgemu.com';
const IRC_USER = 'TwitBot';

Add your Twitter API credentials:

consumer_key
consumer_secret
access_token_key
access_token_secret

Configure the Twitter account or user ID to monitor if necessary.


Running

node index.js

The bot will:

  1. Connect to the IRC server.
  2. Listen for status messages.
  3. Parse incoming server announcements.
  4. Publish formatted updates to Twitter automatically.

Project Status

This project has been archived.

Since it was originally written:

  • Twitter became X.
  • The Twitter API changed significantly.
  • API authentication and pricing have changed.
  • The original twitter package is no longer the recommended library.

The code remains available for historical and educational purposes.


Possible Improvements

  • Support the modern X API
  • Rewrite using TypeScript
  • Use environment variables for credentials
  • Better error handling
  • Docker support
  • Multiple server support
  • Discord webhook integration
  • Slack and Matrix notifications
  • Logging and metrics
  • Unit tests

Disclaimer

This project is unofficial and is not affiliated with SWGEmu, Twitter/X, or any other organization.


License

No license has been specified.

Until a license is added, all rights remain reserved.

About

A simple Node.js bot that listened to the SWGEmu IRC status channel and automatically posted server status updates to Twitter.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages