@zaisma/effects 0.0.0-stage → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (123) hide show
  1. package/EFFECT-FILES.md +301 -0
  2. package/LICENSE.txt +93 -0
  3. package/README.md +63 -2
  4. package/batches/chunks.js +294 -0
  5. package/batches/marks.js +160 -0
  6. package/batches/ribbons.js +233 -0
  7. package/batches/shared.js +155 -0
  8. package/batches/sprites.js +447 -0
  9. package/batches/warps.js +222 -0
  10. package/budget.js +115 -0
  11. package/debris.js +173 -0
  12. package/emit.js +143 -0
  13. package/flashes.js +113 -0
  14. package/format.js +365 -0
  15. package/index.d.ts +373 -0
  16. package/index.js +1168 -0
  17. package/library/bubbles_rising.json +47 -0
  18. package/library/bullet_impact.json +588 -0
  19. package/library/campfire.json +235 -0
  20. package/library/candle_flame.json +100 -0
  21. package/library/confetti.json +165 -0
  22. package/library/dash_burst.json +73 -0
  23. package/library/debris_glass.json +96 -0
  24. package/library/debris_metal.json +106 -0
  25. package/library/debris_stone.json +106 -0
  26. package/library/debris_wood.json +101 -0
  27. package/library/dust_motes.json +51 -0
  28. package/library/dust_puff.json +49 -0
  29. package/library/electric_sparks.json +175 -0
  30. package/library/embers_drift.json +55 -0
  31. package/library/exhaust_puff.json +62 -0
  32. package/library/explosion_air.json +232 -0
  33. package/library/explosion_large.json +373 -0
  34. package/library/explosion_magic.json +266 -0
  35. package/library/explosion_medium.json +289 -0
  36. package/library/explosion_small.json +289 -0
  37. package/library/explosion_water.json +177 -0
  38. package/library/falling_leaves.json +54 -0
  39. package/library/fire_burst.json +185 -0
  40. package/library/fire_large.json +279 -0
  41. package/library/fireball.json +288 -0
  42. package/library/fireflies.json +51 -0
  43. package/library/firework_burst.json +127 -0
  44. package/library/footstep.json +270 -0
  45. package/library/fountain_spray.json +80 -0
  46. package/library/frost_burst.json +202 -0
  47. package/library/ground_mist.json +50 -0
  48. package/library/ground_slam.json +122 -0
  49. package/library/heat_haze.json +24 -0
  50. package/library/hit_blade.json +150 -0
  51. package/library/hit_block.json +157 -0
  52. package/library/hit_critical.json +293 -0
  53. package/library/hit_heavy.json +211 -0
  54. package/library/hit_light.json +122 -0
  55. package/library/hit_magic.json +114 -0
  56. package/library/impact.json +417 -0
  57. package/library/impact_heavy.json +279 -0
  58. package/library/index.json +464 -0
  59. package/library/jump_puff.json +46 -0
  60. package/library/landing_heavy.json +105 -0
  61. package/library/landing_puff.json +75 -0
  62. package/library/level_up.json +164 -0
  63. package/library/lightning_arc.json +90 -0
  64. package/library/lightning_strike.json +387 -0
  65. package/library/magic_aura.json +127 -0
  66. package/library/magic_bolt.json +107 -0
  67. package/library/magic_bolt_impact.json +181 -0
  68. package/library/magic_cast.json +115 -0
  69. package/library/magic_charge.json +91 -0
  70. package/library/magic_heal.json +123 -0
  71. package/library/magic_shield.json +89 -0
  72. package/library/magic_teleport.json +177 -0
  73. package/library/mark_bullet_hole.json +20 -0
  74. package/library/mark_crack.json +18 -0
  75. package/library/mark_footprint.json +20 -0
  76. package/library/mark_frost.json +18 -0
  77. package/library/mark_puddle.json +18 -0
  78. package/library/mark_scorch.json +18 -0
  79. package/library/mark_slash.json +18 -0
  80. package/library/mark_splat.json +18 -0
  81. package/library/pickup_collect.json +117 -0
  82. package/library/pickup_glow.json +76 -0
  83. package/library/poison_cloud.json +107 -0
  84. package/library/portal.json +328 -0
  85. package/library/shockwave_air.json +71 -0
  86. package/library/shockwave_ground.json +95 -0
  87. package/library/slide_dust.json +48 -0
  88. package/library/smoke_column.json +93 -0
  89. package/library/smoke_puff.json +48 -0
  90. package/library/smoke_screen.json +87 -0
  91. package/library/sparks_burst.json +85 -0
  92. package/library/sparks_fountain.json +93 -0
  93. package/library/sparks_shower.json +89 -0
  94. package/library/splash_large.json +181 -0
  95. package/library/splash_small.json +111 -0
  96. package/library/steam_vent.json +64 -0
  97. package/library/summon_circle.json +494 -0
  98. package/library/swim_splash.json +77 -0
  99. package/library/torch_flame.json +219 -0
  100. package/library/trail_blade.json +39 -0
  101. package/library/trail_blade_fire.json +90 -0
  102. package/library/trail_dash.json +80 -0
  103. package/library/trail_magic.json +94 -0
  104. package/library/trail_projectile.json +31 -0
  105. package/library/trail_smoke.json +125 -0
  106. package/library/warp_pulse.json +22 -0
  107. package/library/warp_ripple.json +23 -0
  108. package/library/water_ripple.json +69 -0
  109. package/library/waterfall_mist.json +95 -0
  110. package/looks.js +162 -0
  111. package/motion.js +145 -0
  112. package/online.d.ts +79 -0
  113. package/online.js +32 -0
  114. package/package.json +69 -4
  115. package/partners.js +255 -0
  116. package/piece.json +415 -0
  117. package/piece.json.js +416 -0
  118. package/server.d.ts +55 -0
  119. package/server.js +26 -0
  120. package/shapes.js +269 -0
  121. package/sync.js +528 -0
  122. package/tables.js +109 -0
  123. package/weather.js +289 -0
@@ -0,0 +1,48 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "slide_dust",
4
+ "summary": "Dust streaming from under someone sliding or skidding, for as long as it plays.",
5
+ "family": "character",
6
+ "is_looping": true,
7
+ "duration_sec": 1,
8
+ "importance": "low",
9
+ "elements": [
10
+ {
11
+ "element_kind": "particles",
12
+ "material": "dust",
13
+ "emit": {
14
+ "per_sec": 26,
15
+ "from_kind": "sphere",
16
+ "from_radius_m": 0.12
17
+ },
18
+ "move": {
19
+ "direction_kind": "up",
20
+ "spread_deg": 70,
21
+ "speed_m_per_sec": 0.9,
22
+ "speed_variation_pct": 40,
23
+ "drag_per_sec": 3,
24
+ "wind_pct": 60
25
+ },
26
+ "fade": {
27
+ "life_sec": 0.6,
28
+ "life_variation_pct": 25,
29
+ "size_over_life_m": [
30
+ 0.12,
31
+ 0.4,
32
+ 0.5
33
+ ],
34
+ "size_variation_pct": 30,
35
+ "colors_over_life": [
36
+ "#c8b498",
37
+ "#d8c8b0"
38
+ ],
39
+ "opacity_over_life_pct": [
40
+ 0,
41
+ 40,
42
+ 0
43
+ ],
44
+ "spin_deg_per_sec": 30
45
+ }
46
+ }
47
+ ]
48
+ }
@@ -0,0 +1,93 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "smoke_column",
4
+ "summary": "A column of dark smoke climbing and leaning with the wind: a chimney, a wreck.",
5
+ "family": "smoke",
6
+ "is_looping": true,
7
+ "duration_sec": 1,
8
+ "elements": [
9
+ {
10
+ "element_kind": "particles",
11
+ "material": "smoke",
12
+ "emit": {
13
+ "per_sec": 7,
14
+ "from_kind": "sphere",
15
+ "from_radius_m": 0.18
16
+ },
17
+ "move": {
18
+ "direction_kind": "up",
19
+ "spread_deg": 12,
20
+ "speed_m_per_sec": 1.8,
21
+ "speed_variation_pct": 30,
22
+ "drag_per_sec": 0.3,
23
+ "wind_pct": 100,
24
+ "turbulence_m": 0.55,
25
+ "turbulence_per_sec": 0.5
26
+ },
27
+ "fade": {
28
+ "life_sec": 5.5,
29
+ "life_variation_pct": 25,
30
+ "size_over_life_m": [
31
+ 0.6,
32
+ 2.2,
33
+ 3.4
34
+ ],
35
+ "size_variation_pct": 30,
36
+ "colors_over_life": [
37
+ "#2c2824",
38
+ "#4a4642",
39
+ "#5c5854"
40
+ ],
41
+ "opacity_over_life_pct": [
42
+ 0,
43
+ 70,
44
+ 45,
45
+ 0
46
+ ],
47
+ "spin_deg_per_sec": 20
48
+ },
49
+ "start_delay_sec": 0
50
+ },
51
+ {
52
+ "element_kind": "particles",
53
+ "material": "smoke",
54
+ "emit": {
55
+ "per_sec": 4,
56
+ "from_kind": "sphere",
57
+ "from_radius_m": 0.12
58
+ },
59
+ "move": {
60
+ "direction_kind": "up",
61
+ "spread_deg": 12,
62
+ "speed_m_per_sec": 2.4,
63
+ "speed_variation_pct": 30,
64
+ "drag_per_sec": 0.3,
65
+ "wind_pct": 100,
66
+ "turbulence_m": 0.35,
67
+ "turbulence_per_sec": 0.5
68
+ },
69
+ "fade": {
70
+ "life_sec": 4,
71
+ "life_variation_pct": 25,
72
+ "size_over_life_m": [
73
+ 0.4,
74
+ 1.4,
75
+ 2.2
76
+ ],
77
+ "size_variation_pct": 30,
78
+ "colors_over_life": [
79
+ "#3a3430",
80
+ "#5a5652"
81
+ ],
82
+ "opacity_over_life_pct": [
83
+ 0,
84
+ 40,
85
+ 0
86
+ ],
87
+ "spin_deg_per_sec": 20
88
+ },
89
+ "start_delay_sec": 0,
90
+ "minimum_quality_level": "high"
91
+ }
92
+ ]
93
+ }
@@ -0,0 +1,48 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "smoke_puff",
4
+ "summary": "A burst of grey smoke that rolls out and thins.",
5
+ "family": "smoke",
6
+ "elements": [
7
+ {
8
+ "element_kind": "particles",
9
+ "material": "smoke",
10
+ "emit": {
11
+ "burst_count": 7,
12
+ "from_kind": "sphere",
13
+ "from_radius_m": 0.15
14
+ },
15
+ "move": {
16
+ "direction_kind": "outward",
17
+ "speed_m_per_sec": 1.7,
18
+ "speed_variation_pct": 45,
19
+ "drag_per_sec": 2.2,
20
+ "gravity_pct": -4,
21
+ "wind_pct": 100,
22
+ "turbulence_m": 0.3,
23
+ "turbulence_per_sec": 0.8
24
+ },
25
+ "fade": {
26
+ "life_sec": 1.8,
27
+ "life_variation_pct": 30,
28
+ "size_over_life_m": [
29
+ 0.9,
30
+ 1.6,
31
+ 2
32
+ ],
33
+ "size_variation_pct": 20,
34
+ "colors_over_life": [
35
+ "#9a9894",
36
+ "#c0beba"
37
+ ],
38
+ "opacity_over_life_pct": [
39
+ 45,
40
+ 60,
41
+ 30,
42
+ 0
43
+ ],
44
+ "spin_deg_per_sec": 25
45
+ }
46
+ }
47
+ ]
48
+ }
@@ -0,0 +1,87 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "smoke_screen",
4
+ "summary": "A smoke grenade: thick pale smoke pouring out for three seconds and hanging as a wall for more.",
5
+ "family": "smoke",
6
+ "duration_sec": 11,
7
+ "importance": "high",
8
+ "elements": [
9
+ {
10
+ "element_kind": "particles",
11
+ "material": "smoke",
12
+ "emit": {
13
+ "per_sec": 16,
14
+ "emit_duration_sec": 3,
15
+ "from_kind": "sphere",
16
+ "from_radius_m": 0.3
17
+ },
18
+ "move": {
19
+ "direction_kind": "outward",
20
+ "speed_m_per_sec": 2.8,
21
+ "speed_variation_pct": 50,
22
+ "drag_per_sec": 1.4,
23
+ "gravity_pct": -1,
24
+ "wind_pct": 40,
25
+ "turbulence_m": 0.6,
26
+ "turbulence_per_sec": 0.35
27
+ },
28
+ "fade": {
29
+ "life_sec": 8,
30
+ "life_variation_pct": 20,
31
+ "size_over_life_m": [
32
+ 0.8,
33
+ 3.4,
34
+ 4.4
35
+ ],
36
+ "size_variation_pct": 25,
37
+ "colors_over_life": [
38
+ "#a8a6a2",
39
+ "#c4c2be"
40
+ ],
41
+ "opacity_over_life_pct": [
42
+ 0,
43
+ 90,
44
+ 80,
45
+ 0
46
+ ],
47
+ "spin_deg_per_sec": 12
48
+ }
49
+ },
50
+ {
51
+ "element_kind": "particles",
52
+ "material": "spark",
53
+ "emit": {
54
+ "burst_count": 6
55
+ },
56
+ "move": {
57
+ "direction_kind": "random",
58
+ "speed_m_per_sec": 3,
59
+ "speed_variation_pct": 60,
60
+ "drag_per_sec": 1.2,
61
+ "gravity_pct": 100
62
+ },
63
+ "fade": {
64
+ "life_sec": 0.3,
65
+ "life_variation_pct": 50,
66
+ "size_over_life_m": [
67
+ 0.06,
68
+ 0.025
69
+ ],
70
+ "size_variation_pct": 40,
71
+ "colors_over_life": [
72
+ "#fff6d8",
73
+ "#ffb040",
74
+ "#ff5a10"
75
+ ],
76
+ "opacity_over_life_pct": [
77
+ 100,
78
+ 100,
79
+ 0
80
+ ],
81
+ "glow_pct": 380,
82
+ "facing_kind": "velocity",
83
+ "streak_duration_sec": 0.05
84
+ }
85
+ }
86
+ ]
87
+ }
@@ -0,0 +1,85 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "sparks_burst",
4
+ "summary": "A burst of sparks in every direction that fall and die.",
5
+ "family": "sparks",
6
+ "elements": [
7
+ {
8
+ "element_kind": "particles",
9
+ "material": "glow",
10
+ "emit": {
11
+ "burst_count": 1
12
+ },
13
+ "move": {
14
+ "speed_m_per_sec": 0
15
+ },
16
+ "fade": {
17
+ "life_sec": 0.08,
18
+ "life_variation_pct": 0,
19
+ "size_over_life_m": [
20
+ 0.15,
21
+ 0.6,
22
+ 0.3
23
+ ],
24
+ "size_variation_pct": 0,
25
+ "colors_over_life": [
26
+ "#fff6d0"
27
+ ],
28
+ "opacity_over_life_pct": [
29
+ 100,
30
+ 60,
31
+ 0
32
+ ],
33
+ "glow_pct": 150
34
+ }
35
+ },
36
+ {
37
+ "element_kind": "particles",
38
+ "material": "spark",
39
+ "emit": {
40
+ "burst_count": 34
41
+ },
42
+ "move": {
43
+ "direction_kind": "random",
44
+ "speed_m_per_sec": 6.5,
45
+ "speed_variation_pct": 60,
46
+ "drag_per_sec": 1.2,
47
+ "gravity_pct": 100
48
+ },
49
+ "fade": {
50
+ "life_sec": 0.6,
51
+ "life_variation_pct": 50,
52
+ "size_over_life_m": [
53
+ 0.06,
54
+ 0.025
55
+ ],
56
+ "size_variation_pct": 40,
57
+ "colors_over_life": [
58
+ "#fff6d8",
59
+ "#ffb040",
60
+ "#ff5a10"
61
+ ],
62
+ "opacity_over_life_pct": [
63
+ 100,
64
+ 100,
65
+ 0
66
+ ],
67
+ "glow_pct": 380,
68
+ "facing_kind": "velocity",
69
+ "streak_duration_sec": 0.05
70
+ }
71
+ },
72
+ {
73
+ "element_kind": "flash",
74
+ "color": "#ffc070",
75
+ "strength_lux": 8,
76
+ "radius_m": 5,
77
+ "duration_sec": 0.12,
78
+ "strength_over_life_pct": [
79
+ 100,
80
+ 45,
81
+ 0
82
+ ]
83
+ }
84
+ ]
85
+ }
@@ -0,0 +1,93 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "sparks_fountain",
4
+ "summary": "A fountain of gold sparks thrown up and raining back: a firework on the ground, a forge.",
5
+ "family": "sparks",
6
+ "is_looping": true,
7
+ "duration_sec": 1,
8
+ "elements": [
9
+ {
10
+ "element_kind": "particles",
11
+ "material": "spark",
12
+ "emit": {
13
+ "burst_count": 0,
14
+ "per_sec": 150
15
+ },
16
+ "move": {
17
+ "direction_kind": "up",
18
+ "speed_m_per_sec": 8,
19
+ "speed_variation_pct": 30,
20
+ "drag_per_sec": 0.6,
21
+ "gravity_pct": 100,
22
+ "spread_deg": 15
23
+ },
24
+ "fade": {
25
+ "life_sec": 1.15,
26
+ "life_variation_pct": 50,
27
+ "size_over_life_m": [
28
+ 0.05,
29
+ 0.03
30
+ ],
31
+ "size_variation_pct": 40,
32
+ "colors_over_life": [
33
+ "#ffffff",
34
+ "#ffd860",
35
+ "#ff6a20"
36
+ ],
37
+ "opacity_over_life_pct": [
38
+ 100,
39
+ 100,
40
+ 0
41
+ ],
42
+ "glow_pct": 380,
43
+ "facing_kind": "velocity",
44
+ "streak_duration_sec": 0.05
45
+ }
46
+ },
47
+ {
48
+ "element_kind": "particles",
49
+ "material": "glow",
50
+ "emit": {
51
+ "per_sec": 12
52
+ },
53
+ "move": {
54
+ "speed_m_per_sec": 0,
55
+ "is_attached": true
56
+ },
57
+ "fade": {
58
+ "life_sec": 0.16,
59
+ "life_variation_pct": 30,
60
+ "size_over_life_m": [
61
+ 0.5,
62
+ 0.7
63
+ ],
64
+ "size_variation_pct": 20,
65
+ "colors_over_life": [
66
+ "#fff0b0"
67
+ ],
68
+ "opacity_over_life_pct": [
69
+ 80,
70
+ 0
71
+ ],
72
+ "glow_pct": 200
73
+ }
74
+ },
75
+ {
76
+ "element_kind": "flash",
77
+ "color": "#ffd070",
78
+ "strength_lux": 20,
79
+ "radius_m": 9,
80
+ "duration_sec": 1,
81
+ "strength_over_life_pct": [
82
+ 100,
83
+ 100
84
+ ],
85
+ "flicker_pct": 35,
86
+ "offset_m": [
87
+ 0,
88
+ 0.6,
89
+ 0
90
+ ]
91
+ }
92
+ ]
93
+ }
@@ -0,0 +1,89 @@
1
+ {
2
+ "effect_format_version_number": 1,
3
+ "name": "sparks_shower",
4
+ "summary": "A steady shower of sparks along its direction: grinding, welding, a cut cable.",
5
+ "family": "sparks",
6
+ "is_looping": true,
7
+ "duration_sec": 1,
8
+ "elements": [
9
+ {
10
+ "element_kind": "particles",
11
+ "material": "spark",
12
+ "emit": {
13
+ "burst_count": 0,
14
+ "per_sec": 95
15
+ },
16
+ "move": {
17
+ "direction_kind": "along",
18
+ "speed_m_per_sec": 7,
19
+ "speed_variation_pct": 60,
20
+ "drag_per_sec": 1.2,
21
+ "gravity_pct": 100,
22
+ "spread_deg": 22
23
+ },
24
+ "fade": {
25
+ "life_sec": 0.75,
26
+ "life_variation_pct": 50,
27
+ "size_over_life_m": [
28
+ 0.06,
29
+ 0.025
30
+ ],
31
+ "size_variation_pct": 40,
32
+ "colors_over_life": [
33
+ "#fff6d8",
34
+ "#ffb040",
35
+ "#ff5a10"
36
+ ],
37
+ "opacity_over_life_pct": [
38
+ 100,
39
+ 100,
40
+ 0
41
+ ],
42
+ "glow_pct": 380,
43
+ "facing_kind": "velocity",
44
+ "streak_duration_sec": 0.05
45
+ }
46
+ },
47
+ {
48
+ "element_kind": "particles",
49
+ "material": "glow",
50
+ "emit": {
51
+ "per_sec": 24
52
+ },
53
+ "move": {
54
+ "speed_m_per_sec": 0,
55
+ "is_attached": true
56
+ },
57
+ "fade": {
58
+ "life_sec": 0.08,
59
+ "life_variation_pct": 40,
60
+ "size_over_life_m": [
61
+ 0.2,
62
+ 0.34
63
+ ],
64
+ "size_variation_pct": 40,
65
+ "colors_over_life": [
66
+ "#ffffff",
67
+ "#c8dcff"
68
+ ],
69
+ "opacity_over_life_pct": [
70
+ 100,
71
+ 0
72
+ ],
73
+ "glow_pct": 260
74
+ }
75
+ },
76
+ {
77
+ "element_kind": "flash",
78
+ "color": "#e0e8ff",
79
+ "strength_lux": 12,
80
+ "radius_m": 6,
81
+ "duration_sec": 1,
82
+ "strength_over_life_pct": [
83
+ 100,
84
+ 100
85
+ ],
86
+ "flicker_pct": 60
87
+ }
88
+ ]
89
+ }