livemaps

last built 6 months ago
Build #21
By downloading this file, you agree to our license terms.
Source: github.com
License: MIT
Maintainer: Nexis
This plugin does not compile with the latest version of RocketMod.
Contact the author and kindly ask him to update this plugin or consider fixing it on GitHub.

The RocketMod team curates a dozen of community plugins and could need your support.
Consider a donation to RocketMod and sponsor your favourite plugins or contribute code to them.

Livemaps

This plugin was developed using Rocket Mod libraries for the Steam game Unturned. The Rocket Mod plugin collects server, player, and chat data recurrently, and then saves the retrieved data to a user-configured MySQL database. The API provides an AJAX interface for retrieving the latest JSON-encoded server data. Livemap API responses are then used to update the WebUI maps.

The WebUI portion of this plugin is optional, and is intended only as a default theme for this project. The API may be used independently to support fully custom livemap themes and features.

Livemap Loading

Current Source Code Release

How-to Install

There are three parts to this plugin:

  1. Rocket Mod Plugin (livemap.dll)
  2. API – how the WebUI gets updates from the server
  3. WebUI – the website files

Rocket Mod Plugin

  1. Copy the compiled Livemap.dll to your Rocket Mod plugin directory
  2. Start/stop your server to generate Livemap.configuration.xml
  3. Edit Livemap.configuration.xml and configure MySQL database settings
  4. Add a Rocket Mod permission for the /livemap command by adding it to your Permissions.config.xml
    1. Example<Permission Cooldown="0">livemap</Permission>
  5. Start Unturned Server

Web Interface (WebUI)

  1. Copy the complete contents of the www folder to your web server.

API

  1. Edit www/api/config.api.php and configure your MySQL database settings
    1. Note: For standalone API usage, copy only the www/api folder to your web server

How to View Livemaps

  1. For a complete list of all active servers currently running the Livemap plugin, navigate your browser to the www/ directory you’ve added previously.
    1. Example: http://nexisrealms.com/www/
  2. Show a specific Livemap by passing your server instance name to the id URL parameter
    1. Example: http://nexisrealms.com/www/?id=pei, http://nexisrealms.com/www/?id=server01,  etc.

Live development Demo

Permissions

The following command is used by players to hide their location on the Livemaps. Hiding and cooldown duration settings are configurable via Livemap.configuration.xml.

  • <Permission Cooldown="0">livemap</Permission>

Requirements:

  • PHP 5.6.+
  • MySQL 5.6.5+
    • It is required to have a minimum MySQL version of 5.6.5 to use this plugin. This is to support the use of tables with multiple timestamp fields.

Notes

  • Release #14: If you receive the following error, it is because: You Must Configure Livemap.configuration.xml with your MySQL database information FIRST 😉
  • Release #5: Fixed the download to include the www folder


author: Nexis (steam:iamtwidget) <nexis@nexisrealms.com>

Default configuration


<?xml version="1.0" encoding="utf-8"?>
<LivemapConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <LivemapEnabled>true</LivemapEnabled>
  <LivemapStatusEnabled>true</LivemapStatusEnabled>
  <LivemapRefreshInterval>10</LivemapRefreshInterval>
  <WorldChatEnabled>true</WorldChatEnabled>
  <PlayerHideEnabled>true</PlayerHideEnabled>
  <PlayerHideCooldownEnabled>true</PlayerHideCooldownEnabled>
  <PlayerHideDuration>300</PlayerHideDuration>
  <PlayerHideCooldownDuration>600</PlayerHideCooldownDuration>
  <PlayerDefaultSteamAvatar>images/avatars/unknown.png</PlayerDefaultSteamAvatar>
  <DatabaseHost>localhost</DatabaseHost>
  <DatabaseUser>unturned</DatabaseUser>
  <DatabasePass>password</DatabasePass>
  <DatabaseName>unturned</DatabaseName>
  <DatabasePort>3306</DatabasePort>
  <DatabaseTableLivemapServer>livemap_server</DatabaseTableLivemapServer>
  <DatabaseTableLivemapData>livemap_data</DatabaseTableLivemapData>
  <DatabaseTableLivemapChat>livemap_chat</DatabaseTableLivemapChat>
</LivemapConfiguration>

Default english translation


Commands and permissions


Git changelog


e50d3db9ca69340 2017-08-12 17:39:55

Added Options to Enable/Disable Livemaps

  • Added config option to enable/disabled a certain Livemap
  • Added config option to enabled/disable a certain status badge
  • Added update sql file to update existing databases from previous version
  • Updated Rocket Mode libraries

f1663298d9fe875 2017-07-27 20:23:24

Updated Status Page

  • Updated the look of the main status page
  • Included PSD of overlay

ad354ce1174ec96 2017-07-25 23:15:15

Readability

    3e9ca001ce236cc 2017-07-18 23:55:50

    Included Libraries

    • Added Libraries to output

    de9be78c92823fc 2017-07-17 14:55:27

    Rocket Mod Libraries #1206 Update

    • Updated Rocket Mod libraries to current version.

    896b5341d0afb63 2017-07-17 14:18:04

    Fixed Null Value

    • Fixed `livemap_data` column `last_disconnect` default value, which was
    • throwing an error during initial setup.

    47f29f7192d13be 2017-07-16 21:10:51

    Warning Fixes

      c08ad22c3f2a6f8 2017-07-16 21:01:57

      Map Name Fix

        f505ab1942f8b8a 2017-07-16 20:53:08

        Duplicate Maps

          c6661da842690d8 2017-07-16 20:51:19

          Fixing Leftover Maps

            8bb7d758514a24a 2017-07-16 19:27:03

            Optimize Code

            • Nope.

            121f6e07b3fa27c 2017-07-16 19:05:21

            Renamed Map

            • Renamed Alpha Valey folder so that it does not contain a space

            b7e25c981c72241 2017-07-16 18:57:01

            Fixed Output

            • Jenkins didn't like my post-build events, so let's try this...

            05b7159cf3aa331 2017-07-16 17:59:34

            Fixed Output

            • Included missing www folder with the output
            • Moved additional libraries to a Libraries folder
            • Fixed potential MySQL bug

            95c13c3499a3b8a 2017-07-15 19:16:04

            Player Node Fixes

            • Removed the background color from player nodes when their icon changes
            • to a vehicle
            • Removed border from player nodes
            • Added rotation updates to player nodes when in a vehicle, but this needs
            • to be refined
            • Also changed the badge animation for when a player connects to the
            • server

            7ad626c6396b178 2017-07-15 02:51:34

            Steam Profiles

            • Added Steam profile link to player badge avatars

            991a2ecf71b3db9 2017-07-15 02:28:40

            Badge Reputation Fixed

            • Added a couple missing reputation icons
            • Added PSD for reputation icons
            • Fixed reputation icons and color

            44a2701fa7c7a3b 2017-07-14 18:38:43

            Added Default View

            • If a server parameter is not set. the page will display a list of
            • running servers.

            806aad5bc0a0c0b 2017-07-14 18:02:16

            Livemap Parameters

            • Instead of showing all server Livemaps on the same page, I decided to
            • split them up so that you can display a specific Livemap using URL
            • parameter `id`. Also included some more PSD files I've created. Replaced
            • index.html with index.php.

            8b8d25eeb7893fa 2017-07-10 02:29:15

            README

              68394c302a925ae 2017-07-10 02:27:41

              Airdrop Crate

              • Bunch of updates. Too many to list. Added some of the vehicle images I'm
              • working on, a new loading heart image(s), and everything in the
              • livemap.js file. I haven't been committing much, recently, but that
              • certainly doesn't mean I've stopped development! :+1:

              f19f825e002d1c1 2017-07-01 10:06:26

              Optimization

              • Optimized the entire plugin to be more efficient and less resource
              • heavy. Trimmed some fat. I also refined the /livemap command so that
              • it's no longer exploitable.

              927e8d0d903af10 2017-06-30 13:31:29

              Missing Image

              • Added a new image for default server avatar (zombie face) that I forgot
              • to add in the previous commit. Also removed old loading gif.

              ee09fe7111f672b 2017-06-29 08:14:38

              Working Copy

              • Too many changes since last commit to outline. Put simply, everything
              • seems to be working well. Player node and badges are both added and
              • removed upon connect/disconnect, /livemap command is fully functional,
              • world chat now displays correctly, is draggable, and notifies when a
              • player connects/disconnects/hides. More to come!

              a59a67c5873cdbc 2017-06-18 04:01:53

              Null Fix

              • Fixed a null error I was getting because I knocked on wood..

              dffc1ddc3525006 2017-06-18 00:16:43

              Livemap Hide Cooldown

              • Added all the functionality for player hide cooldowns. You can now set
              • the duration a player can hide themselves from the livemap, as well as
              • the cooldown duration before they can hide again. Besides a couple small
              • bug fixes, this commit concludes the development of the RocketMod plugin
              • portion of this project for public release. *knocks on wood*

              01329019ad49d6a 2017-06-17 19:24:25

              Livemap Command Fix

              • Fixed the /livemap command to correctly toggle player visibility on the
              • website livemaps; database updates correctly. I will reflect this in the
              • WebUI soon. I also fixed a null error that occurs when a player 'has not
              • set up their steam profile' resulting in a null value. I added a check
              • for this and a config option for the default (missing) avatar.

              21bf1da28d47fff 2017-06-17 17:10:27

              README

                66cb277a4fa8b91 2017-06-13 09:03:38

                Basic Functionality

                • Player nodes and badges now load properly. Players now move to their
                • updated location on the maps. Fixed multirealm world chat. Will commit
                • the rest later zzzz

                0e2b32d284d9f04 2017-06-09 16:23:24

                World Chat Fix

                • Fixed bug where only the newest message was syncing with World Chat.
                • Also added an effect to new messages using Velocity.js

                0c757caca634e18 2017-06-06 02:24:09

                README

                  57d2ce932dc6193 2017-06-05 15:34:56

                  README

                    40cc71b26bbc9f7 2017-06-05 15:31:22

                    Fixed World Chat Encoding

                    • The API was improperly rendering certain languages in World Chat.
                    • Solution was to specify encoding to utf8 in mysql database connection.

                    34eeb90e682269f 2017-06-05 04:31:36

                    Working World Chat

                    • Server world chat now updates properly. I have set this to a static
                    • refresh timer of 10 seconds. I will add this to the config in an
                    • upcoming commit.
                    • I have also updated the loading screen to appear as a small icon on the
                    • bottom right of the screen.

                    46236b23a3f3ab2 2017-06-04 02:31:10

                    Null Bug Fix

                    • Workaround for NullReference error. Will track this down later..

                    4394e340342c16a 2017-06-04 02:06:14

                    README

                      5ebb6c17e5a2537 2017-06-04 02:00:03

                      Rocket Mod Libraries #1205 Update

                      • Updated to newest Rocket libraries (#1205)

                      7f96bbca3b311ed 2017-05-17 04:45:30

                      Functioning World Chat

                      • Updated API to also pass admin status for blue chat names; added jquery
                      • plugin to style scrollbars; Added an option to disable specific
                      • livemaps from appearing; Removed excessive ajax requests from chat;
                      • Other code cleanup

                      7cdf0d7bf6c85fe 2017-05-16 23:30:23

                      Working Copy

                      • Player nodes load correctly, chat loads correctly, and badges load
                      • correctly. Now on to making it refresh, wooo!

                      bca327360bf5ba0 2017-05-16 20:12:27

                      Player Nodes & World Chat

                      • Added player pin nodes, world chat, player badges, and made all maps
                      • load dynamically. I also updated an API query. This is still very much
                      • incomplete. More to come shortly. I also updated the Rocket libraries.

                      4ed4e0e7bc6d307 2017-05-11 12:53:42

                      README

                        fedc8a823987ebe 2017-05-11 03:50:46

                        README

                          22dce73164a42a0 2017-05-11 03:43:37

                          README

                            4ca5da2c792ae99 2017-05-11 03:39:34

                            README

                              1654d1820550ddc 2017-05-11 03:34:02

                              README

                                8d84e5605c38cbb 2017-04-30 11:29:06

                                Optimized Maps

                                • Optimized all native map images; reducing overall file size.

                                0320ca901eb90fc 2017-04-30 05:39:00

                                Node Faces

                                • Recreated all the different player faces with transparent backgrounds to
                                • easily update player skin tone while still reflecting current face
                                • selection. These images will become the livemap player "pins" (nodes)
                                • that reflect each player position. I've also included the PSD file, for
                                • the cool kids.

                                308d3d31f66db50 2017-04-30 04:47:11

                                AssemblyInfo.cs

                                • This file might be helpful.. thanks @natherox#6337

                                690ef57df96e167 2017-04-22 22:38:29

                                Loading Screen & API

                                • Added loading screen & gif, velocity.js, jquery, and compressed the huge
                                • map image. I will be compressing the rest of the maps in the next
                                • commit. API request and response successful (see console).

                                f39a2b9f378a068 2017-04-19 08:29:58

                                WebUI Progress

                                  205535f72c33102 2017-04-19 07:12:36

                                  README

                                    4e148f69c104d8d 2017-04-19 06:59:06

                                    README

                                      3d3450edb482aa5 2017-04-19 06:44:07

                                      WebUI Progress

                                        391dc27874b686b 2017-04-16 04:58:49

                                        Server Offline Check

                                        • Added checks for server online / offline

                                        ca12b35f83b164c 2017-04-16 03:10:19

                                        Refined Result Query

                                          462fab75eaef861 2017-04-16 02:21:29

                                          Chat Activity Duration

                                          • Added a setting for limiting chat queries by filtering how many minutes
                                          • ago they were sent.

                                          b1505456bd3164c 2017-04-16 00:59:12

                                          README

                                            645b22f71011efc 2017-04-16 00:56:12

                                            README

                                              2743796934f6ab9 2017-04-16 00:53:04

                                              README

                                                bcdbdfd61756f16 2017-04-16 00:52:52

                                                Added API Filtering

                                                • Added filtering options to API and updated the request processing
                                                • function to be less clunky.

                                                c6a624e2dca3253 2017-04-16 00:43:41

                                                Altered table name

                                                • Renamed `livemap_servers` table to `livemap_server`

                                                faf99735e46b4d7 2017-04-15 23:03:08

                                                Added server_id & sterilization

                                                • Added server_id to other tables in order to filter multiple servers.
                                                • Also added world chat sterilization to mysql queries.

                                                02377ebff647fd3 2017-04-15 19:09:36

                                                Livemap API

                                                • Added Livemap API to handle WebUI AJAX requests.

                                                0c28b51d1beafbd 2017-04-15 08:31:52

                                                README

                                                  849fc98f15c8035 2017-04-15 08:23:29

                                                  Working Release

                                                  • Plugin is fully functional. However, some of the code needs refinement.

                                                  f6235a779f8962a 2017-04-14 14:39:21

                                                  README

                                                    20164e055ce8394 2017-04-14 14:30:47

                                                    README

                                                      fc2ccf9bd27c19c 2017-04-09 23:41:43

                                                      progress.

                                                        5363c8b893ca26a 2017-04-09 09:04:34

                                                        props

                                                          64201287b3be8b2 2017-04-09 08:50:42

                                                          Update

                                                            bad2a0ed63183f3 2017-04-09 08:48:08

                                                            Directory Update

                                                              14c4f9d5c92e81a 2017-04-09 08:44:12

                                                              gitignore

                                                                ddca6a415e04081 2017-04-09 08:41:50

                                                                Rambling, man.

                                                                  93efb2d982ef4ab 2017-03-03 21:15:15

                                                                  Initial Commit