Build your own Plugin
A guide on how to build a plugin.
Objective
Make a plugin that replaces the Deeeep.io logo with <Your Name>.io
Prerequisites
A basic knowledge of JavaScript is required. If you don't know it, JavaScript.info is
a good place to start.
You will also need the Plugin Dev (plugin-dev) plugin by Canned Seagull (DRC's dev) installed.
The plugin is not required for building plugins but will make your life really easier.
Setting Up
Open the Plugins window. With the Plugin Dev plugin installed, click on the blue "Developer"
button, then click on "new".
You should now see a plugin editor appear.
Fill in your plugin's name, description, and your author name. Under "ID", fill in any unique
identifier name containing only alphanumeric characters, the dot, underscore and hyphen.
Example:
Name: My Plugin
ID: my-plugin
Description: A testing plugin
Author: Me
Writing the Code
Click on "New Script". You should see a new script section appear.
Under the left dropdown, you can select a script type. Select "domloaded". This will run the
script on DOM load.
Under the center text input of the script, enter the following code, replacing "<Your
Name>" with your name.
const logoWrapper = document.querySelector("div.el-image");
logoWrapper.innerHTML = "";
const text = document.createElement("h1");
text.setAttribute("style", "font-size:3em;height:1em;white-space:nowrap;line-height:1;");
text.innerText = "<Your Name>" + ".io";
logoWrapper.appendChild(text);
Completing
You created your own Plugin! Restart Deeeep.io Reef Client to see the plugin in action.