Beams are a visual and mechanical utility that allows players to project effects (like lasers or lightning) from their character Similar to the Trail System these beams are modular supporting multiple layers and complex environmental interactions.
Beam files must be placed in:
data/corewithstuff/cws_beams/beamname.json
Commands
/cws-beams [beamId]: Activates a specific beam for the player./cws-beams clear: Deactivates the current beam.JSON Example: Crimson Laser
{
"layers": [
{
"type": "laser",
"body_part": "right_arm",
"glow_color": "#FF2200",
"core_color": "#FFFFFF",
"size": [0.12, 0.42],
"pulse_speed": 2.5,
"emit_light": true,
"light_level": 13,
"damage": 4.0,
"burns": true,
"smelting": true
}
]
}
JSON Example: Blue Lightning
{
"layers": [
{
"type": "lightning",
"body_part": "right_arm",
"visible_first_person": true,
"visible_third_person": true,
"glow_color": "#4488FF",
"core_color": "#FFFFFF",
"bloom": 4,
"glow_falloff": 2.0,
"chromatic_fringe": 0.3,
"size": [0.09, 0.38],
"offset": [0, -0.4, 0],
"offset_first_person": [0.18, -0.28, 0.5],
"offset_third_person": [-0.05, -0.35, 0.1],
"segments": 18,
"frequency": 2,
"spread": 5.5,
"taper": 0.28,
"jaggedness": 0.44,
"branch_chance": 0.38,
"branch_depth": 2,
"branch_length": 0.65,
"normal_transparency": false,
"emit_light": true,
"light_level": 11,
"damage": 8.0,
"burns": true
}
]
}
JSON Example: Mixed beam
{
"layers": [
{
"type": "laser",
"body_part": "right_arm",
"visible_first_person": true,
"visible_third_person": true,
"glow_color": "#FF2200",
"core_color": "#FFFFFF",
"rainbow": 0.0,
"glow_opacity": 0.9,
"core_opacity": 1.0,
"bloom": 5,
"glow_falloff": 2.2,
"chromatic_fringe": 0.35,
"size": [0.12, 0.42],
"offset": [0, 0, 0],
"offset_first_person": [0.18, -0.28, 0.5],
"offset_third_person": [-0.05, -0.35, 0.1],
"normal_transparency": false,
"rotation": 0.0,
"rotation_speed": 15.0,
"pulse_speed": 2.5,
"pulse_amount": 0.25,
"flicker_chance": 0.06,
"flicker_amount": 0.18,
"wobble_amplitude": 0.018,
"wobble_frequency": 5.0,
"wobble_speed": 1.4,
"emit_light": true,
"light_level": 13,
"damage": 4.0,
"burns": true,
"smelting": true,
"command_on_entity_hit": "/particle minecraft:flash ~ ~ ~ 0.5 0.5 0.5 0 1",
"command_on_block_hit": ""
},
{
"type": "lightning",
"body_part": "right_arm",
"visible_first_person": true,
"visible_third_person": true,
"glow_color": "#FF2200",
"core_color": "#FFFFFF",
"bloom": 3,
"glow_falloff": 1.8,
"chromatic_fringe": 0.2,
"size": [0.09, 0.36],
"offset": [0, -0.4, 0],
"offset_first_person": [0.18, -0.28, 0.5],
"offset_third_person": [-0.05, -0.35, 0.1],
"segments": 18,
"frequency": 2,
"spread": 5.5,
"taper": 0.28,
"jaggedness": 0.42,
"branch_chance": 0.35,
"branch_depth": 1,
"branch_length": 0.65,
"normal_transparency": false,
"emit_light": true,
"light_level": 10,
"damage": 8.0,
"burns": true
}
]
}