File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ function validate() {
3232 errors .push ({text: ` The effect attempts to use opacity but the material is not set to 'Blend'` })
3333 }
3434
35- if (Config .particle_appearance_facing_camera_mode .substr ( 0 , 9 ) == ' direction' && Config .particle_appearance_direction_mode == ' derive_from_velocity' ) {
35+ if (Config .particle_appearance_facing_camera_mode .includes ( ' direction' ) && Config .particle_appearance_direction_mode == ' derive_from_velocity' ) {
3636 if (Config .particle_motion_mode == ' dynamic' && ! (Config .particle_motion_linear_speed && parseFloat (Config .particle_motion_linear_speed ) != 0 )) {
3737 errors .push ({text: ` The particles are set to face a direction, but no speed is set. Only particles with an initial speed support directions` })
3838
Original file line number Diff line number Diff line change @@ -303,12 +303,13 @@ function generateFile() {
303303 comps [ 'minecraft:particle_kill_plane' ] = getValue ( 'particle_lifetime_kill_plane' ) ;
304304
305305 //Texture
306+ let facing_camera_mode = getValue ( 'particle_appearance_facing_camera_mode' ) ;
306307 var tex_comp = comps [ 'minecraft:particle_appearance_billboard' ] = {
307308 size : getValue ( 'particle_appearance_size' ) ,
308- facing_camera_mode : getValue ( 'particle_appearance_facing_camera_mode' ) ,
309+ facing_camera_mode : facing_camera_mode ,
309310
310311 }
311- if ( getValue ( 'particle_appearance_facing_camera_mode' ) . substr ( 0 , 9 ) == 'direction' &&
312+ if ( ( facing_camera_mode . substring ( 0 , 9 ) == 'direction' || facing_camera_mode == 'lookat_direction' ) &&
312313 ( getValue ( 'particle_appearance_speed_threshold' ) != 0.01 || getValue ( 'particle_appearance_direction_mode' ) != 'derive_from_velocity' )
313314 ) {
314315 tex_comp . direction = {
You can’t perform that action at this time.
0 commit comments