execute store result score random temp run random value 1..4

execute if score random temp matches 1 run summon firework_rocket ~ ~ ~ {Life:0,LifeTime:30,FireworksItem:{id:"minecraft:firework_rocket",count:1,components:{"minecraft:fireworks":{explosions:[{shape:"large_ball",has_twinkle:true,has_trail:true,colors:[I;16711680],fade_colors:[I;7864320]}]}}}}
execute if score random temp matches 2 run summon firework_rocket ~ ~ ~ {Life:0,LifeTime:30,FireworksItem:{id:"minecraft:firework_rocket",count:1,components:{"minecraft:fireworks":{explosions:[{shape:"burst",has_trail:true,colors:[I;16711680],fade_colors:[I;7864320]}]}}}}
execute if score random temp matches 3 run summon firework_rocket ~ ~ ~ {Life:0,LifeTime:30,FireworksItem:{id:"minecraft:firework_rocket",count:1,components:{"minecraft:fireworks":{explosions:[{shape:"star",has_twinkle:true,colors:[I;16711680],fade_colors:[I;7864320,13100031,16711680]}]}}}}
execute if score random temp matches 4 run summon firework_rocket ~ ~ ~ {Life:0,LifeTime:30,FireworksItem:{id:"minecraft:firework_rocket",count:1,components:{"minecraft:fireworks":{explosions:[{shape:"small_ball",has_twinkle:true,has_trail:true,colors:[I;16711680],fade_colors:[I;7864320]}]}}}}