Skip to content

VlastikYoutubeKo/lfs-lmar

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

100 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ LFS Live Map + Radio v0.0.7_ML

Live For Speed InSim application combining a real-time server map with an integrated internet radio player.

๐Ÿ“ฆ Releases

Download the latest version from the Releases page.

โœจ Features

  • Live Map - Real-time positioning of all players on the server
  • 9 Supported Tracks - Blackwood, South City, Fern Bay, Aston, Kyoto, Westhill, Autocross, Rockingham, Layout Square
  • Internet Radio - 30,000+ international stations + Czech stations (Abradia.cz)
  • InSim GUI - Control the radio directly inside LFS
  • Metadata - "Now Playing" overlay with song info
  • Multilingual - English / Czech support
  • Player Tracking - Click on a player in the list to auto-follow camera

๐Ÿš€ Quick Start

This application runs on Node.js.

Prerequisites

  • Node.js (Version 18 or newer): Download Here
  • MPV Player (Recommended for Radio): choco install mpv (or add to PATH)

Installation

  1. Download the latest ZIP from Releases
  2. Extract the ZIP content to a folder.
  3. Double-click START.bat to launch the server.
  4. In LFS chat, type: /insim 29999
  5. Open browser: http://localhost:3000

๐Ÿ› ๏ธ Development Setup

# 1. Clone repo
git clone https://github.com/VlastikYoutubeKo/lfs-lmar.git
cd lfs-live-map-radio

# 2. Install dependencies
npm install

# 3. Run dev server
npm start

๐Ÿ“– Usage Guide

InSim GUI Commands:

  • /o gui - Reset GUI if it disappears
  • /o np - Show "Now Playing" overlay manually

Radio GUI:

  1. Click the [R] icon in the top-right corner of LFS screen
  2. Select Category: Favorites, Recent, Abradia.cz, or Search.
  3. Volume Control: +/- buttons
  4. Language: Switch between EN/CZ

๐ŸŽต Spotify Integration (Optional):

Control your Spotify playback directly from the radio interface and in-game!

Setup:

  1. See readme_spotify.txt for full setup instructions
  2. Create a free Spotify Developer app at https://developer.spotify.com/dashboard
  3. Add your Client ID and Client Secret to radio_config.json
  4. Enable Spotify integration and authenticate via the radio web interface

Features:

  • Play/Pause control
  • Next/Previous track
  • Volume control
  • Real-time "Now Playing" display with album artwork
  • Works both in web interface and InSim GUI
  • Optional - can be enabled/disabled with a toggle switch

Requirements:

  • Spotify Premium account (required for Web API playback control)
  • Active Spotify device (desktop app, mobile, or web player)

Web Map:

  • Zoom: Mouse wheel or +/- buttons
  • Pan: Click and drag
  • Reset View: Home button (โŒ‚)
  • Follow Player: Click player name in the sidebar list

๐ŸŽฎ LFS Configuration

Manual Connection:

If the app doesn't connect automatically, type this in LFS:

/insim 29999

๐Ÿ“ Project Structure

lfs-live-map-radio/
โ”œโ”€โ”€ server.js              # Main server logic
โ”œโ”€โ”€ START.bat              # Launcher script
โ”œโ”€โ”€ public/                # Web interface files
โ”œโ”€โ”€ radio_browser.js       # Radio API
โ”œโ”€โ”€ abradia_api.js         # Czech Radio API
โ””โ”€โ”€ .github/workflows/     # CI/CD

๐Ÿ”ง Tech Stack

  • Node.js - Runtime
  • node-insim - LFS InSim protocol
  • WebSocket - Real-time communication
  • Canvas API - Map rendering
  • MPV - Audio playback

๐Ÿ“ Configuration

The radio_config.json file is generated automatically on the first run.

{
  "favorites": [],
  "recent": [],
  "lang": "en"
}

๐Ÿ› Troubleshooting

"Node is not recognized"

  • Ensure you have installed Node.js from nodejs.org.
  • Restart your computer after installation.

Radio not playing

  • Install MPV player and ensure it is in your system PATH.
    • Use choco choco install mpv

Map not loading

  • Check the browser console (F12) for errors.
  • Ensure port 3000 is not used by another application.

๐Ÿ“œ License

MIT License - Vlastimil ยฉ 2025

๐Ÿ“ง Contact


Made with โค๏ธ for the Live For Speed Community

About

๐Ÿ Real-time InSim application for Live For Speed combining live track map with internet radio player. Features 30K+ stations, web-based visualization, mobile support, and in-game GUI controls.

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages