Changes wire & hose colors while they are providing insufficient power or fluid
Supported Games
Features
- Changes the color of electrical wires while they are providing 0 or insufficient power (default: red)
- Changes the color of hoses while they are providing 0 fluid (default: red)
- Restores the original wire or hose color when sufficient power or fluid starts flowing
Permissions
dynamicwirecolors.use-- While the plugin is configured with"RequiresPermission": true(default), wires connecting player-owned entities will only be dynamically colored if at least one of the entities was deployed by a player with this permission.
Configuration
Default configuration:
{
"InsufficientPowerColor": "Red",
"InsufficientFluidColor": "Red",
"RequiresPermission": true,
"AppliesToUnownedEntities": false
}
InsufficientPowerColor-- Color to use for electrical wires that are providing 0 or insufficient power.- Allowed values:
"Gray"|"Red"|"Green"|"Blue"|"Yellow"|"LightBlue"|"Orange"|"Pink"|"Purple"|"White"
- Allowed values:
InsufficientFluidColor-- Color to use while for hoses that are providing 0 fluid.- Allowed values:
"Gray"|"Red"|"Green"|"Blue"|"Yellow"|"LightBlue"|"Orange"|"Pink"|"Purple"|"White"
- Allowed values:
RequiresPermission(trueorfalse) -- Whiletrue(default), wires connecting player-owned entities will only be dynamically colored if at least one of the entities was deployed by a player with thedynamicwirecolors.usepermission. Whilefalse, wires connected to any player-owned entity will be dynamically colored, as though you had granted the permission to all players.AppliesToUnownedEntities(trueorfalse) -- Whiletrue, wires and hoses connecting unowned entities (entities that haveOwnerIDset to0) will be dynamically colored. For example, this applies to entities at monuments, as well as to modular car tanker modules. Whilefalse(default), wires connecting unowned entities will not be affected by the plugin.
Developer Hooks
OnDynamicWireColorChange
bool? OnDynamicWireColorChange(IOEntity ioEntity, IOEntity.IOSlot slot, WireTool.WireColour color)
- Called when this plugin is about to change the wire or hose color of an entity's slot
- Returning
falsewill prevent the wire color from being changed - Returning
nullwill allow the wire color to be changed
MIT License
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

