css+div实现彩色粒子碎屑喷射动画效果代码
代码语言:html
所属分类:粒子
代码描述:css+div实现彩色粒子碎屑喷射动画效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<style>
html {
overflow:hidden;
background:#222
}
.particle {
position:absolute;
width:4px;
height:4px;
animation:shoot 3s ease-out infinite;
animation-name:shoot,fade
}
.particle:nth-child(1) {
transform:translate(18vw,11vh);
background:#ff4dcf;
animation-duration:1.27s;
animation-delay:-0.635s
}
.particle:nth-child(2) {
transform:translate(43vw,49vh);
background:#bbff4d;
animation-duration:1.04s;
animation-delay:-0.676s
}
.particle:nth-child(3) {
transform:translate(36vw,94vh);
background:#61ff4d;
animation-duration:1.07s;
animation-delay:-0.9309s
}
.particle:nth-child(4) {
transform:translate(35vw,94vh);
background:#b24dff;
animation-duration:1.65s;
animation-delay:-1.2045s
}
.particle:nth-child(5) {
transform:translate(70vw,49vh);
background:#ff4dbe;
animation-duration:1.12s;
animation-delay:-1.1088s
}
.particle:nth-child(6) {
transform:translate(5vw,89vh);
background:#ff614d;
animation-duration:1.83s;
animation-delay:-0.0183s
}
.particle:nth-child(7) {
transform:translate(80vw,93vh);
background:#4dc6ff;
animation-duration:1.64s;
animation-delay:-0.0492s
}
.particle:nth-child(8) {
transform:translate(78vw,36vh);
background:#4dffc9;
animation-duration:1.32s;
animation-delay:-1.188s
}
.particle:nth-child(9) {
transform:translate(93vw,58vh);
background:#884dff;
animation-duration:1.01s;
animation-delay:-0.2929s
}
.particle:nth-child(10) {
transform:translate(27vw,66vh);
background:#ff4dc1;
animation-duration:1.59s;
animation-delay:-0.8268s
}
.particle:nth-child(11) {
transform:translate(48vw,82vh);
background:#ffbb4d;
animation-duration:1.64s;
animation-delay:-1.4432s
}
.particle:nth-child(12) {
transform:translate(34vw,95vh);
background:#4d73ff;
animation-duration:1.49s;
animation-delay:-0.0149s
}
.particle:nth-child(13) {
transform:translate(19vw,82vh);
background:#ff4d9a;
animation-duration:1.24s;
animation-delay:-0.1612s
}
.particle:nth-child(14) {
transform:translate(83vw,79vh);
background:#4dff58;
animation-duration:1.26s;
animation-delay:-1.008s
}
.particle:nth-child(15) {
transform:translate(44vw,86vh);
background:#5bff4d;
animation-duration:1.44s;
animation-delay:-0.504s
}
.particle:nth-child(16) {
transform:translate(47vw,4vh);
background:#4d6dff;
animation-duration:1.87s;
animation-delay:-0.7667s
}
.particle:nth-child(17) {
transform:translate(32vw,46vh);
background:#ff4dac;
animation-duration:1.36s;
animation-delay:-0.2312s
}
.particle:nth-child(18) {
transform:translate(18vw,2vh);
background:#ffb84d;
animation-duration:1.99s;
animation-delay:-1.4328s
}
.particle:nth-child(19) {
transform:translate(98vw,14vh);
background:#a0ff4d;
animation-duration:1.37s;
animation-delay:-0.7261s
}
.particle:nth-child(20) {
transform:translate(45vw,81vh);
background:#ff4de7;
animation-duration:1.55s;
animation-delay:-0.279s
}
.particle:nth-child(21) {
transform:translate(100vw,82vh);
background:#fcff4d;
animation-duration:1.66s;
animation-delay:-1.6102s
}
.particle:nth-child(22) {
transform:translate(94vw,20vh);
background:#9d4dff;
animation-duration:1.89s;
animation-delay:-1.7388s
}
.particle:nth-child(23) {
transform:translate(47vw,58vh);
background:#ffb54d;
animation-duration:1.9s;
animation-delay:-0.855s
}
.particle:nth-child(24) {
transform:translate(84vw,28vh);
background:#4d52ff;
animation-duration:1.17s;
animation-delay:-0.6552s
}
.particle:nth-child(25) {
transform:translate(24vw,80vh);
background:#4dd8ff;
animation-duration:1.54s;
animation-delay:-1.3706s
}
.particle:nth-child(26) {
transform:translate(66vw,99vh);
background:#4d9dff;
animation-duration:1.84s;
animation-delay:-1.012s
}
.particle:nth-child(27) {
transform:translate(66vw,100vh);
background:#97ff4d;
animation-duration:1.03s;
animation-delay:-1.0197s
}
.particle:nth-child(28) {
transform:translate(27vw,20vh);
background:#4d9dff;
animation-duration:1.83s;
animation-delay:-0.0366s
}
.particle:nth-child(29) {
transform:translate(76vw,81vh);
background:#ff4d85;
animation-duration:1.48s;
animation-delay:-0.9028s
}
.particle:nth-child(30) {
transform:translate(70vw,86vh);
background:#fcff4d;
animation-duration:1.2s;
animation-delay:-0.624s
}
.particle:nth-child(31) {
transform:translate(7vw,27vh);
background:#4dff91;
animation-duration:1.06s;
animation-delay:-0.8268s
}
.particle:nth-child(32) {
transform:translate(57vw,93vh);
background:#ffea4d;
animation-duration:1.13s;
animation-delay:-0.5311s
}
.particle:nth-child(33) {
transform:translate(3vw,73vh);
background:#ffd54d;
animation-duration:1.36s;
animation-delay:-0.1224s
}
.particle:nth-child(34) {
transform:translate(73vw,53vh);
background:#4dffe4;
animation-duration:1.4s;
animation-delay:-1.162s
}
.particle:nth-child(35) {
transform:translate(40vw,7vh);
background:#ff4d7c;
animation-duration:1.02s;
animation-delay:-0.5202s
}
.particle:nth-child(36) {
transform:translate(3vw,2vh);
background:#4d85ff;
animation-duration:1.2s;
animation-delay:-0.54s
}
.particle:nth-child(37) {
transform:translate(62vw,87vh);
background:#4d7cff;
animation-duration:1.41s;
animation-delay:-1.3959s
}
.particle:nth-child(38) {
transform:translate(73vw,34vh);
background:#4dd8ff;
animation-duration:1.52s;
animation-delay:-1.3528s
}
.particle:nth-child(39) {
transform:translate(3vw,68vh);
background:#ff824d;
animation-duration:1.23s;
animation-delay:-0.984s
}
.particle:nth-child(40) {
transform:translate(59vw,6vh);
background:#4de1ff;
animation-duration:1.97s;
animation-delay:-0.2167s
}
.particle:nth-child(41) {
transform:translate(72vw,4vh);
background:#4dbeff;
animation-duration:1.71s;
animation-delay:-0.1197s
}
.particle:nth-child(42) {
transform:translate(46vw,11vh);
background:#4dffa9;
animation-duration:1.42s;
animation-delay:-0.4118s
}
.particle:nth-child(43) {
transform:translate(100vw,21vh);
background:#884dff;
animation-duration:1.32s;
animation-delay:-0.462s
}
.particle:nth-child(44) {
transform:translate(72vw,16vh);
background:#acff4d;
animation-duration:1.24s;
animation-delay:-0.6944s
}
.particle:nth-child(45) {
transform:translate(28vw,19vh);
background:#ea4dff;
animation-duration:1.79s;
animation-delay:-1.5573s
}
.particle:nth-child(46) {
transform:translate(12vw,95vh);
background:#e44dff;
animation-duration:1.29s;
animation-delay:-0.6708s
}
.particle:nth-child(47) {
transform:translate(15vw,48vh);
background:#914dff;
animation-duration:1.42s;
animation-delay:-0.0284s
}
.particle:nth-child(48) {
transform:translate(7vw,33vh);
background:#8bff4d;
animation-duration:1.84s;
animation-delay:-1.4536s
}
.particle:nth-child(49) {
transform:translate(73vw,86vh);
background:#ff4d6d;
animation-duration:1.26s;
animation-delay:-0.4662s
}
.particle:nth-child(50) {
transform:translate(55vw,82vh);
background:#ff4dde;
animation-duration:1.34s;
animation-delay:-0.2412s
}
.particle:nth-child(51) {
transform:translate(2vw,58vh);
background:#73ff4d;
animation-duration:1.25s;
animation-delay:-0.2375s
}
.particle:nth-child(52) {
transform:translate(100vw,64vh);
background:#ffe74d;
animation-duration:1.32s;
animation-delay:-1.1088s
}
.particle:nth-child(53) {
transform:translate(25vw,32vh);
background:#4dff52;
animation-duration:1.7s;
animation-delay:-1.071s
}
.particle:nth-child(54) {
transform:translate(1vw,75vh);
background:#cfff4d;
animation-duration:1.43s;
animation-delay:-0.2431s
}
.particle:nth-child(55) {
transform:translate(42vw,35vh);
background:#cc4dff;
animation-duratio.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0