poi-plugin-sunny-replay
v2.0.0
Published
A plugin which shows battle replay for poi.
Readme
POI Plugin - Sunny's Battle Replay
A POI plugin for Kantai Collection that converts battle-detail files to KC3Kai's battle replayer format.
Features
- Converts POI battle-detail files to KC3Kai replay format
- Displays battle replays using KC3Kai's battle replayer
- Generates battle images for sharing
- Supports multiple battle file formats
- Multi-language support (English, Japanese, Chinese)
Installation
Method 1: Through POI Plugin Manager (Recommended)
- Open POI-viewer
- Go to Settings → Plugin
- Search for "poi-plugin-sunny-replay"
- Click Install
Method 2: Manual Installation
- Clone this repository:
git clone [email protected]:Aravind-Sundararajan/poi-plugin-battle-replay.git - Navigate to POI's plugin directory:
- Windows:
%APPDATA%/poi/plugins/ - macOS:
~/Library/Application Support/poi/plugins/ - Linux:
~/.config/poi/plugins/
- Windows:
- Copy the plugin folder to the plugins directory
- Restart POI-viewer
Method 3: NPM Installation
npm install poi-plugin-sunny-replayUsage
- Start POI-viewer and ensure the plugin is enabled
- Navigate to the plugin in POI's plugin menu
- Select a battle file from the dropdown (files are automatically loaded from your battle-detail directory)
- Click "Copy to Battle Player" to load the battle data
- View the battle replay in the embedded player
- Download battle images using the download button
Requirements
- POI-viewer (latest version recommended)
- Internet connection (for KC3Kai battle replayer)
- Battle-detail files in POI's data directory
Troubleshooting
Plugin Not Loading
- Ensure POI-viewer is up to date
- Check that all dependencies are installed
- Verify the plugin is in the correct directory
No Battle Files Found
- Check that POI is recording battle data
- Verify the battle-detail directory exists in your POI data folder
- Ensure you have recent battle files (
.json.gzformat)
Battle Replay Not Working
- Check your internet connection (replayer loads from KC3Kai's servers)
- Try reloading the battle player
- Verify the battle data format is correct
Error Messages
- "APPDATA_PATH not found": POI environment not properly configured
- "No battle files found": No battle data in the expected directory
- "Error reading battle-detail directory": Permission or path issues
File Structure
poi-plugin-sunny-replay/
├── index.js # Plugin entry point
├── index.html # Main interface
├── main.css # Styling
├── env-loader.js # Environment initialization
├── converter.js # Battle data converter
├── preload.js # Battle replayer preload script
├── preload2.js # Converter preload script
├── constants/ # Plugin constants
│ ├── poi-fleets.js
│ └── ship-images.js
├── i18n/ # Internationalization
│ ├── en-US.json
│ └── zh-CN.json
└── package.json # Plugin metadataDependencies
lodash: Utility functionsi18n-2: Internationalizationzlib: File compression handling
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Submit a pull request
License
MIT License - see LICENSE file for details
Credits
- Uses KC3Kai's kancolle-replay (external web application)
- Uses poi-to-kc3-battle-replay-converter
- Ship images from WhoCallsTheFleet
Technical Details
Battle Replayer Integration
This plugin uses KC3Kai's battle replayer web application hosted at:
https://kc3kai.github.io/kancolle-replay/battleplayer.html
The replayer is embedded in a webview and receives battle data via IPC messages. This approach:
- ✅ Always up-to-date: Uses the latest version from KC3Kai's servers
- ✅ Lightweight: No need to package the replayer with the plugin
- ✅ Maintained: KC3Kai team handles updates and maintenance
- ✅ Reliable: Hosted on GitHub Pages with good uptime
Data Flow
- Battle File Selection: User selects a battle file from POI's battle-detail directory
- Data Conversion: POI battle format is converted to KC3Kai format using the converter
- IPC Communication: Converted data is sent to the embedded webview
- Battle Replay: KC3Kai replayer displays the battle animation
Support
If you encounter issues:
- Check the troubleshooting section above
- Search existing issues on GitHub
- Create a new issue with detailed information about your problem
