Skip to content

DynamicLightsPumpkin ​v0.0.7

Server-driven dynamic lights for held items and nearby entities

See the plugin guide and API reference on the documentation site.

Installation ​

Put dynamic-lights-pumpkin.wasm from the plugin's GitHub release in your server's plugins/ folder and restart. Hot reload cannot ask for permissions, so the first load needs a restart.

How it works ​

Holding a supported light source shows a temporary invisible light block only to your client. It updates when you enter another block, change held slot or inventory, drop or use an item, teleport, respawn, or change world. Event updates read the completed action on the next tick. Movement within the same block is ignored to avoid repeated world and inventory lookups. Either hand can provide light, and the brighter configured item wins. The server world is never changed, so no light block can replace terrain or be left behind after a crash.

Built-in sources, including torches and lava buckets, are listed in config.toml. Remove an entry to disable it, change its light_level, or add any item ID you want to support.

Entity lights are enabled by default. The plugin checks entities in a 15-block cube around each player every 10 ticks by default and sends changes only when a configured entity light moves, changes level or leaves range. Configure entity_sources with Pumpkin entity names such as blaze, magma-cube, glow-squid or glow-item-frame. Dropped items use the same configured level as their held form when the plugin observes them spawn or drop. A player drop is identified only when exactly one new nearby item entity appears; ambiguous drops and existing drops after a plugin or server restart are deliberately not guessed at.

Use /dynamiclights to toggle dynamic lights for yourself. It is available to all players by default and remembers your choice. Overlapping sources use the brightest level, and disabling lights or unloading the plugin restores the real blocks.

The plugin retains its old recovery data reader solely to repair temporary server light levels written by an earlier version.

Permissions ​

Pumpkin asks for these on the server console the first time the plugin loads.

PermissionWhy
fs.read.dataRead its light-source settings, player preferences and old recovery data.
fs.write.dataWrite its light-source settings and player preferences, and clean up old recovery data.
http.outboundCheck Pumpkin Market for plugin updates.

Commands ​

CommandDescriptionPermissionDefault access
/dynamiclightsToggle dynamic lights for yourselfDynamicLightsPumpkin:command.dynamiclightseveryone

Configuration ​

Settings live in plugins/data/DynamicLightsPumpkin/config.toml. The plugin creates the file if needed, adds settings from the schema and removes settings no longer defined there. Values for existing settings are preserved.

OptionTypeDefaultDescription
sources."<item>".light_levelintegernoneLight emitted while this item is held, from 0 through 15.
entities.enabledbooleantrueWhether configured entities emit temporary client-only light.
entities.refresh_interval_ticksinteger10Ticks between nearby-entity refreshes. Higher values reduce work but make moving lights less smooth.
entity_sources."<entity type>".light_levelintegernoneLight emitted by this entity type, from 0 through 15.
A fresh install gets this file:
toml
# DynamicLightsPumpkin configuration.
# This file is managed by the plugin: when it starts, settings that were added are written here with
# their defaults and settings that were removed are dropped. Your values are kept; comments you add
# are not.

# Per-item light levels for held sources, including items that are not blocks such as lava buckets.
# Set a level to 0 to disable a source.
#
# [sources."minecraft:lava_bucket"]
# light_level = 15  # Light emitted while this item is held, from 0 through 15.

[sources."minecraft:torch"]
light_level = 14

[sources."minecraft:soul_torch"]
light_level = 10

[sources."minecraft:redstone_torch"]
light_level = 7

[sources."minecraft:lantern"]
light_level = 15

[sources."minecraft:soul_lantern"]
light_level = 10

[sources."minecraft:glowstone"]
light_level = 15

[sources."minecraft:sea_lantern"]
light_level = 15

[sources."minecraft:shroomlight"]
light_level = 15

[sources."minecraft:ochre_froglight"]
light_level = 15

[sources."minecraft:verdant_froglight"]
light_level = 15

[sources."minecraft:pearlescent_froglight"]
light_level = 15

[sources."minecraft:end_rod"]
light_level = 14

[sources."minecraft:jack_o_lantern"]
light_level = 15

[sources."minecraft:magma_block"]
light_level = 3

[sources."minecraft:campfire"]
light_level = 15

[sources."minecraft:soul_campfire"]
light_level = 10

[sources."minecraft:lava_bucket"]
light_level = 15

[sources."minecraft:blaze_rod"]
light_level = 10

[sources."minecraft:blaze_powder"]
light_level = 10

[sources."minecraft:fire_charge"]
light_level = 15

[sources."minecraft:glow_ink_sac"]
light_level = 8

[sources."minecraft:glowstone_dust"]
light_level = 8

[sources."minecraft:glow_item_frame"]
light_level = 8

[sources."minecraft:magma_cream"]
light_level = 8

# Controls the optional dynamic lights shown around configured entity types.
[entities]

# Whether configured entities emit temporary client-only light.
enabled = true

# Ticks between nearby-entity refreshes. Higher values reduce work but make moving lights less
# smooth.
refresh_interval_ticks = 10

# Per-entity-type light levels. Entity type names use Pumpkin names such as blaze, magma-cube and
# glow-squid.
#
# [entity_sources."blaze"]
# light_level = 15  # Light emitted by this entity type, from 0 through 15.

[entity_sources."blaze"]
light_level = 15

[entity_sources."glow-item-frame"]
light_level = 8

[entity_sources."magma-cube"]
light_level = 8

[entity_sources."glow-squid"]
light_level = 8

Pumpkin Plugins documentation