diff --git a/PixelComposer.resource_order b/PixelComposer.resource_order index 16a64090d..5a212fe26 100644 --- a/PixelComposer.resource_order +++ b/PixelComposer.resource_order @@ -87,6 +87,7 @@ {"name":"d3d light","order":14,"path":"folders/nodes/data/3D/d3d light.yy",}, {"name":"d3d mesh","order":12,"path":"folders/nodes/data/3D/d3d mesh.yy",}, {"name":"d3d modifier","order":18,"path":"folders/nodes/data/3D/d3d modifier.yy",}, + {"name":"d3d particle","order":19,"path":"folders/nodes/data/3D/d3d particle.yy",}, {"name":"animation","order":6,"path":"folders/nodes/data/animation.yy",}, {"name":"compose","order":11,"path":"folders/nodes/data/compose.yy",}, {"name":"armature","order":5,"path":"folders/nodes/data/compose/armature.yy",}, @@ -127,7 +128,8 @@ {"name":"fluidSim","order":2,"path":"folders/nodes/data/simulation/fluidSim.yy",}, {"name":"strandSim","order":1,"path":"folders/nodes/data/simulation/strandSim.yy",}, {"name":"VFX","order":3,"path":"folders/nodes/data/simulation/VFX.yy",}, - {"name":"effector","order":9,"path":"folders/nodes/data/simulation/VFX/effector.yy",}, + {"name":"affector","order":9,"path":"folders/nodes/data/simulation/VFX/affector.yy",}, + {"name":"effects","order":11,"path":"folders/nodes/data/simulation/VFX/effects.yy",}, {"name":"transform","order":8,"path":"folders/nodes/data/transform.yy",}, {"name":"value","order":4,"path":"folders/nodes/data/value.yy",}, {"name":"array","order":1,"path":"folders/nodes/data/value/array.yy",}, @@ -220,7 +222,6 @@ {"name":"biterator","order":2,"path":"folders/VCT/biterator.yy",}, {"name":"widget","order":3,"path":"folders/VCT/widget.yy",}, {"name":"widgets","order":5,"path":"folders/widgets.yy",}, - {"name":"d3d particle","order":19,"path":"folders/nodes/data/3D/d3d particle.yy",}, ], "ResourceOrderSettings": [ {"name":"s_node_corner","order":16,"path":"sprites/s_node_corner/s_node_corner.yy",}, @@ -416,6 +417,7 @@ {"name":"s_biterator_b_grey_short","order":8,"path":"sprites/s_biterator_b_grey_short/s_biterator_b_grey_short.yy",}, {"name":"printer","order":2,"path":"scripts/printer/printer.yy",}, {"name":"sh_de_stray","order":16,"path":"shaders/sh_de_stray/sh_de_stray.yy",}, + {"name":"s_node_vfx_osc","order":14,"path":"sprites/s_node_vfx_osc/s_node_vfx_osc.yy",}, {"name":"sh_chromatic_aberration","order":31,"path":"shaders/sh_chromatic_aberration/sh_chromatic_aberration.yy",}, {"name":"fd_rectangle_create_view","order":3,"path":"scripts/fd_rectangle_create_view/fd_rectangle_create_view.yy",}, {"name":"node_fluid_vortex","order":8,"path":"scripts/node_fluid_vortex/node_fluid_vortex.yy",}, @@ -632,7 +634,6 @@ {"name":"pack_bottom_left","order":2,"path":"scripts/pack_bottom_left/pack_bottom_left.yy",}, {"name":"o_dialog_lua_reference","order":5,"path":"objects/o_dialog_lua_reference/o_dialog_lua_reference.yy",}, {"name":"__node_custom","order":14,"path":"scripts/__node_custom/__node_custom.yy",}, - {"name":"node_VFX_trail_path","order":10,"path":"scripts/node_VFX_trail_path/node_VFX_trail_path.yy",}, {"name":"s_node_note","order":35,"path":"sprites/s_node_note/s_node_note.yy",}, {"name":"node_strand_gravity","order":4,"path":"scripts/node_strand_gravity/node_strand_gravity.yy",}, {"name":"palette_functions","order":3,"path":"scripts/palette_functions/palette_functions.yy",}, @@ -809,6 +810,7 @@ {"name":"node_perlin","order":8,"path":"scripts/node_perlin/node_perlin.yy",}, {"name":"node_blur_simple","order":4,"path":"scripts/node_blur_simple/node_blur_simple.yy",}, {"name":"node_feedback_input","order":1,"path":"scripts/node_feedback_input/node_feedback_input.yy",}, + {"name":"s_node_vfx_trail","order":13,"path":"sprites/s_node_vfx_trail/s_node_vfx_trail.yy",}, {"name":"s_node_base_conversion","order":10,"path":"sprites/s_node_base_conversion/s_node_base_conversion.yy",}, {"name":"node_transform_array","order":15,"path":"scripts/node_transform_array/node_transform_array.yy",}, {"name":"s_node_loop_array","order":23,"path":"sprites/s_node_loop_array/s_node_loop_array.yy",}, @@ -1021,6 +1023,7 @@ {"name":"s_node_vfx_spawn","order":2,"path":"sprites/s_node_vfx_spawn/s_node_vfx_spawn.yy",}, {"name":"__vec3","order":8,"path":"scripts/__vec3/__vec3.yy",}, {"name":"texture_set_repeat","order":1,"path":"scripts/texture_set_repeat/texture_set_repeat.yy",}, + {"name":"node_VFX_effect_oscillate","order":9,"path":"scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.yy",}, {"name":"o_dialog_color_quick_pick","order":5,"path":"objects/o_dialog_color_quick_pick/o_dialog_color_quick_pick.yy",}, {"name":"fd_rectangle_update_velocity","order":22,"path":"scripts/fd_rectangle_update_velocity/fd_rectangle_update_velocity.yy",}, {"name":"sh_3d_extrude_filler_depth","order":9,"path":"shaders/sh_3d_extrude_filler_depth/sh_3d_extrude_filler_depth.yy",}, diff --git a/PixelComposer.yyp b/PixelComposer.yyp index 434301df9..b91ae7439 100644 --- a/PixelComposer.yyp +++ b/PixelComposer.yyp @@ -111,6 +111,7 @@ {"resourceType":"GMFolder","resourceVersion":"1.0","name":"d3d light","folderPath":"folders/nodes/data/3D/d3d light.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"d3d mesh","folderPath":"folders/nodes/data/3D/d3d mesh.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"d3d modifier","folderPath":"folders/nodes/data/3D/d3d modifier.yy",}, + {"resourceType":"GMFolder","resourceVersion":"1.0","name":"d3d particle","folderPath":"folders/nodes/data/3D/d3d particle.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"animation","folderPath":"folders/nodes/data/animation.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"compose","folderPath":"folders/nodes/data/compose.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"armature","folderPath":"folders/nodes/data/compose/armature.yy",}, @@ -154,7 +155,8 @@ {"resourceType":"GMFolder","resourceVersion":"1.0","name":"rigidSim","folderPath":"folders/nodes/data/simulation/rigidSim.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"strandSim","folderPath":"folders/nodes/data/simulation/strandSim.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"VFX","folderPath":"folders/nodes/data/simulation/VFX.yy",}, - {"resourceType":"GMFolder","resourceVersion":"1.0","name":"effector","folderPath":"folders/nodes/data/simulation/VFX/effector.yy",}, + {"resourceType":"GMFolder","resourceVersion":"1.0","name":"affector","folderPath":"folders/nodes/data/simulation/VFX/affector.yy",}, + {"resourceType":"GMFolder","resourceVersion":"1.0","name":"effects","folderPath":"folders/nodes/data/simulation/VFX/effects.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"transform","folderPath":"folders/nodes/data/transform.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"value","folderPath":"folders/nodes/data/value.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"array","folderPath":"folders/nodes/data/value/array.yy",}, @@ -253,7 +255,6 @@ {"resourceType":"GMFolder","resourceVersion":"1.0","name":"biterator","folderPath":"folders/VCT/biterator.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"widget","folderPath":"folders/VCT/widget.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"widgets","folderPath":"folders/widgets.yy",}, - {"resourceType":"GMFolder","resourceVersion":"1.0","name":"d3d particle","folderPath":"folders/nodes/data/3D/d3d particle.yy",}, ], "IncludedFiles": [ {"resourceType":"GMIncludedFile","resourceVersion":"1.0","name":"ApolloHelp.html","ConfigValues":{"Itch":{"CopyToMask":"0",},},"CopyToMask":-1,"filePath":"datafiles",}, @@ -995,6 +996,7 @@ {"id":{"name":"printer","path":"scripts/printer/printer.yy",},}, {"id":{"name":"node_iterate","path":"scripts/node_iterate/node_iterate.yy",},}, {"id":{"name":"sh_de_stray","path":"shaders/sh_de_stray/sh_de_stray.yy",},}, + {"id":{"name":"s_node_vfx_osc","path":"sprites/s_node_vfx_osc/s_node_vfx_osc.yy",},}, {"id":{"name":"sh_chromatic_aberration","path":"shaders/sh_chromatic_aberration/sh_chromatic_aberration.yy",},}, {"id":{"name":"fd_rectangle_create_view","path":"scripts/fd_rectangle_create_view/fd_rectangle_create_view.yy",},}, {"id":{"name":"node_fluid_vortex","path":"scripts/node_fluid_vortex/node_fluid_vortex.yy",},}, @@ -1450,6 +1452,7 @@ {"id":{"name":"node_perlin","path":"scripts/node_perlin/node_perlin.yy",},}, {"id":{"name":"node_blur_simple","path":"scripts/node_blur_simple/node_blur_simple.yy",},}, {"id":{"name":"node_feedback_input","path":"scripts/node_feedback_input/node_feedback_input.yy",},}, + {"id":{"name":"s_node_vfx_trail","path":"sprites/s_node_vfx_trail/s_node_vfx_trail.yy",},}, {"id":{"name":"o_dialog_add_multiple_images","path":"objects/o_dialog_add_multiple_images/o_dialog_add_multiple_images.yy",},}, {"id":{"name":"assets_data","path":"scripts/assets_data/assets_data.yy",},}, {"id":{"name":"s_node_base_conversion","path":"sprites/s_node_base_conversion/s_node_base_conversion.yy",},}, @@ -1686,6 +1689,7 @@ {"id":{"name":"s_node_vfx_spawn","path":"sprites/s_node_vfx_spawn/s_node_vfx_spawn.yy",},}, {"id":{"name":"__vec3","path":"scripts/__vec3/__vec3.yy",},}, {"id":{"name":"texture_set_repeat","path":"scripts/texture_set_repeat/texture_set_repeat.yy",},}, + {"id":{"name":"node_VFX_effect_oscillate","path":"scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.yy",},}, {"id":{"name":"o_dialog_color_quick_pick","path":"objects/o_dialog_color_quick_pick/o_dialog_color_quick_pick.yy",},}, {"id":{"name":"fd_rectangle_update_velocity","path":"scripts/fd_rectangle_update_velocity/fd_rectangle_update_velocity.yy",},}, {"id":{"name":"sh_3d_extrude_filler_depth","path":"shaders/sh_3d_extrude_filler_depth/sh_3d_extrude_filler_depth.yy",},}, diff --git a/scripts/__VFX/__VFX.gml b/scripts/__VFX/__VFX.gml index bc58ea7e5..82dc031c1 100644 --- a/scripts/__VFX/__VFX.gml +++ b/scripts/__VFX/__VFX.gml @@ -70,6 +70,9 @@ function __part(_node) constructor { ground_bounce = 0; ground_friction = 1; + trailLife = 0; + trailActive = false; + frame = 0; static reset = function() { #region @@ -89,13 +92,18 @@ function __part(_node) constructor { x = _x; y = _y; + drawx = x; + drawy = y; + life_incr = 0; life = _life; life_total = life; if(node.onPartCreate != noone) node.onPartCreate(self); - x_history = array_create(life); - y_history = array_create(life); + trailActive = true; + trailLife = 0; + x_history = array_create(life); + y_history = array_create(life); } #endregion static setPhysic = function(_sx, _sy, _ac, _g, _gDir, _turn, _turnSpd) { #region @@ -168,6 +176,7 @@ function __part(_node) constructor { static step = function(frame = 0) { #region gml_pragma("forceinline"); + trailLife++; if(!active) return; x += speedx; @@ -206,10 +215,6 @@ function __part(_node) constructor { if(node.onPartStep != noone && step_int > 0 && safe_mod(life, step_int) == 0) node.onPartStep(self); - x_history[life_incr] = x; - y_history[life_incr] = y; - - life_incr++; if(life-- < 0) kill(); if(prevx != undefined) { @@ -217,6 +222,10 @@ function __part(_node) constructor { spVec[1] = point_direction(prevx, prevy, x, y); } + x_history[life_incr] = drawx; + y_history[life_incr] = drawy; + life_incr++; + prevx = x; prevy = y; @@ -255,7 +264,8 @@ function __part(_node) constructor { //print($"Drawing part destroy when animation end"); kill(); return; - } else ss = surf[ind]; + } else + ss = surf[ind]; break; } } diff --git a/scripts/_node_VFX_spawner/_node_VFX_spawner.gml b/scripts/_node_VFX_spawner/_node_VFX_spawner.gml index b9c0dbdb0..d043dc86c 100644 --- a/scripts/_node_VFX_spawner/_node_VFX_spawner.gml +++ b/scripts/_node_VFX_spawner/_node_VFX_spawner.gml @@ -428,7 +428,6 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co //var activeParts = 0; for(var i = 0; i < array_length(parts); i++) { - if(!parts[i].active) continue; //activeParts++; parts[i].step(_time); } diff --git a/scripts/globalvar_drawer/globalvar_drawer.gml b/scripts/globalvar_drawer/globalvar_drawer.gml index 0be93827b..de0004580 100644 --- a/scripts/globalvar_drawer/globalvar_drawer.gml +++ b/scripts/globalvar_drawer/globalvar_drawer.gml @@ -1,15 +1,20 @@ function globalvar_viewer_init() { var_editing = false; + + var_dragging = noone; + var_drag_insert = 0; } function globalvar_viewer_draw(xx, yy, ww, _m, focus, hover, _scrollPane, rx, ry) { var hh = 0; var lb_h = line_get_height(f_p0) + ui(8); var padd = ui(8); - + + var _node = PROJECT.globalNode; + if(var_editing) { var del = noone; - if(ds_list_size(PROJECT.globalNode.inputs)) { + if(ds_list_size(_node.inputs)) { yy += ui(8); hh += ui(8); } @@ -17,25 +22,56 @@ function globalvar_viewer_draw(xx, yy, ww, _m, focus, hover, _scrollPane, rx, ry var wd_x = xx; var wd_w = ww; - for( var j = 0; j < ds_list_size(PROJECT.globalNode.inputs); j++ ) { - var _inpu = PROJECT.globalNode.inputs[| j]; + var _len = ds_list_size(_node.inputs); + var _ins = var_drag_insert; + var_drag_insert = _len; + + for( var j = 0; j < _len; j++ ) { + var _inpu = _node.inputs[| j]; var _edit = _inpu.editor; var wd_h = ui(32); - - if(j) { + + if(var_dragging != noone) { + if(_m[1] < yy + wd_h && var_drag_insert == _len) + var_drag_insert = j; + + if(j == _ins) { + draw_set_color(COLORS._main_icon); + draw_line_round(wd_x + ui(8), yy, wd_x + wd_w - ui(16), yy, 4); + } + + if(var_dragging == j) + continue; + + yy += ui(10); + hh += ui(10); + } else if(j) { draw_set_color(merge_color(c_black, COLORS.panel_toolbar_separator, 0.75)); draw_line_round(wd_x + ui(8), yy, wd_x + wd_w - ui(16), yy, 4); - + yy += ui(10); hh += ui(10); } - + + var bx = wd_x + ui(10); + var by = yy + ui(16); + if(hover && point_in_rectangle(_m[0], _m[1], bx - ui(12), by - ui(12), bx + ui(12), by + ui(12))) { + draw_sprite_stretched_ext(THEME.group_label, 0, bx - ui(12), by - ui(12), ui(24), ui(24), COLORS._main_icon_light, 1); + + if(mouse_press(mb_left, focus)) { + var_dragging = j; + } + } else + draw_sprite_stretched_ext(THEME.group_label, 0, bx - ui(12), by - ui(12), ui(24), ui(24), COLORS._main_icon_light, 0.75); + + draw_sprite_ext(THEME.hamburger, 0, bx, by, 0.5, 0.5, 0, COLORS._main_icon_light, 1); + _edit.tb_name.setFocusHover(focus, hover); _edit.sc_type.setFocusHover(focus, hover); _edit.sc_disp.setFocusHover(focus, hover); - - _edit.tb_name.draw(wd_x, yy, wd_w - wd_h - ui(4), wd_h, _inpu.name, _m, TEXTBOX_INPUT.text); - if(buttonInstant(THEME.button_hide, wd_x + wd_w - wd_h, yy + ui(2), wd_h, wd_h, _m, focus, hover,, THEME.icon_delete,, COLORS._main_value_negative) == 2) + + _edit.tb_name.draw(wd_x + ui(32), yy, wd_w - wd_h - ui(32 + 4), wd_h, _inpu.name, _m, TEXTBOX_INPUT.text); + if(buttonInstant(THEME.button_hide, wd_x + wd_w - wd_h, yy, wd_h, wd_h, _m, focus, hover,, THEME.icon_delete,, COLORS._main_value_negative) == 2) del = j; yy += wd_h + ui(8); hh += wd_h + ui(8); @@ -51,18 +87,38 @@ function globalvar_viewer_draw(xx, yy, ww, _m, focus, hover, _scrollPane, rx, ry yy += wd_h + ui(4); hh += wd_h + ui(4); } + + if(var_dragging != noone) { + if(var_drag_insert == _len) { + draw_set_color(COLORS._main_icon); + draw_line_round(wd_x + ui(8), yy, wd_x + wd_w - ui(16), yy, 4); + + yy += ui(10); + hh += ui(10); + } + + if(mouse_release(mb_left)) { + var _inp = _node.inputs[| var_dragging]; + ds_list_delete(_node.inputs, var_dragging); + + if(var_drag_insert > var_dragging) var_drag_insert--; + ds_list_insert(_node.inputs, var_drag_insert, _inp); + + var_dragging = noone; + } + } if(del != noone) - ds_list_delete(PROJECT.globalNode.inputs, del); + ds_list_delete(_node.inputs, del); } else { - for( var j = 0; j < ds_list_size(PROJECT.globalNode.inputs); j++ ) { - var widg = drawWidget(xx, yy, ww, _m, PROJECT.globalNode.inputs[| j], true, focus, hover, _scrollPane, rx, ry); + for( var j = 0; j < ds_list_size(_node.inputs); j++ ) { + var widg = drawWidget(xx, yy, ww, _m, _node.inputs[| j], true, focus, hover, _scrollPane, rx, ry); var widH = widg[0]; var mbRight = widg[1]; if(hover && point_in_rectangle(_m[0], _m[1], xx, yy, xx + ww, yy + widH)) - _HOVERING_ELEMENT = PROJECT.globalNode.inputs[| j]; - + _HOVERING_ELEMENT = _node.inputs[| j]; + yy += lb_h + widH + padd; hh += lb_h + widH + padd; } diff --git a/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.gml b/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.gml index ceae09d81..f27d46b32 100644 --- a/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.gml +++ b/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.gml @@ -10,8 +10,8 @@ function Node_VFX_Accelerate(_x, _y, _group = noone) : Node_VFX_effector(_x, _y, var _rot = random_range(_rot_range[0], _rot_range[1]); var _sca = [ random_range(_sca_range[0], _sca_range[1]), random_range(_sca_range[2], _sca_range[3]) ]; - part.sx = part.sx + _vect[0] * str * _sten; - part.sy = part.sy + _vect[1] * str * _sten; + part.speedx = part.speedx + _vect[0] * str * _sten; + part.speedy = part.speedy + _vect[1] * str * _sten; part.rot += _rot * str; diff --git a/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.yy b/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.yy index c24d3a8ea..bdb3500af 100644 --- a/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.yy +++ b/scripts/node_VFX_effect_accelerate/node_VFX_effect_accelerate.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effect_attract/node_VFX_effect_attract.gml b/scripts/node_VFX_effect_attract/node_VFX_effect_attract.gml index ac877960a..1860bd9c4 100644 --- a/scripts/node_VFX_effect_attract/node_VFX_effect_attract.gml +++ b/scripts/node_VFX_effect_attract/node_VFX_effect_attract.gml @@ -4,6 +4,10 @@ function Node_VFX_Attract(_x, _y, _group = noone) : Node_VFX_effector(_x, _y, _g inputs[| 4].setVisible(false, false); + inputs[| effector_input_length + 0] = nodeValue("Destroy when reach middle", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false ); + + array_push(input_display_list, effector_input_length + 0); + function onAffect(part, str) { var _area = getInputData(1); var _area_x = _area[0]; @@ -15,6 +19,8 @@ function Node_VFX_Attract(_x, _y, _group = noone) : Node_VFX_effector(_x, _y, _g var _rot = random_range(_rot_range[0], _rot_range[1]); var _sca = [ random_range(_sca_range[0], _sca_range[1]), random_range(_sca_range[2], _sca_range[3]) ]; + var _dest = getInputData(effector_input_length + 2); + var pv = part.getPivot(); var dirr = point_direction(pv[0], pv[1], _area_x, _area_y); part.x = part.x + lengthdir_x(_sten * str, dirr); @@ -29,6 +35,9 @@ function Node_VFX_Attract(_x, _y, _group = noone) : Node_VFX_effector(_x, _y, _g else part.sc_sx += sign(part.sc_sx) * scx_s; if(scy_s < 0) part.sc_sy = lerp_linear(part.sc_sy, 0, abs(scy_s)); else part.sc_sy += sign(part.sc_sy) * scy_s; + + if(_dest && point_distance(part.x, part.y, _area_x, _area_y) <= _sten) + part.kill(); } PATCH_STATIC diff --git a/scripts/node_VFX_effect_attract/node_VFX_effect_attract.yy b/scripts/node_VFX_effect_attract/node_VFX_effect_attract.yy index 3812c5d3f..ea942579c 100644 --- a/scripts/node_VFX_effect_attract/node_VFX_effect_attract.yy +++ b/scripts/node_VFX_effect_attract/node_VFX_effect_attract.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effect_destroy/node_VFX_effect_destroy.yy b/scripts/node_VFX_effect_destroy/node_VFX_effect_destroy.yy index 33339e403..6abfa3daf 100644 --- a/scripts/node_VFX_effect_destroy/node_VFX_effect_destroy.yy +++ b/scripts/node_VFX_effect_destroy/node_VFX_effect_destroy.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.gml b/scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.gml new file mode 100644 index 000000000..b58e71503 --- /dev/null +++ b/scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.gml @@ -0,0 +1,38 @@ +function Node_VFX_Oscillate(_x, _y, _group = noone) : Node_VFX_effector(_x, _y, _group) constructor { + name = "Oscillate"; + node_draw_icon = s_node_vfx_osc; + + inputs[| 4].setVisible(false, false); + inputs[| 6].setVisible(false, false); + inputs[| 7].setVisible(false, false); + + inputs[| effector_input_length + 0] = nodeValue("Amplitude", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 2 ); + + inputs[| effector_input_length + 1] = nodeValue("Frequency", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.2 ); + + inputs[| effector_input_length + 2] = nodeValue("Multiply by speed", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false ); + + array_push(input_display_list, effector_input_length + 0, effector_input_length + 1, effector_input_length + 2); + + function onAffect(part, str) { + var _sten = getInputData(5); + + var _amp = getInputData(effector_input_length + 0); + var _fre = getInputData(effector_input_length + 1); + var _mls = getInputData(effector_input_length + 2); + + var _lif = part.life; + var _dir = part.spVec[1] + 90; + + var _aamp = sin(part.seed + _lif * _fre) * _amp; + if(_mls) _aamp *= part.spVec[0]; + + var _dx = lengthdir_x(_aamp, _dir); + var _dy = lengthdir_y(_aamp, _dir); + + part.drawx += _dx; + part.drawy += _dy; + } + + PATCH_STATIC +} \ No newline at end of file diff --git a/scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.yy b/scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.yy new file mode 100644 index 000000000..f1aef1f6c --- /dev/null +++ b/scripts/node_VFX_effect_oscillate/node_VFX_effect_oscillate.yy @@ -0,0 +1,11 @@ +{ + "resourceType": "GMScript", + "resourceVersion": "1.0", + "name": "node_VFX_effect_oscillate", + "isCompatibility": false, + "isDnD": false, + "parent": { + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", + }, +} \ No newline at end of file diff --git a/scripts/node_VFX_effect_repel/node_VFX_effect_repel.yy b/scripts/node_VFX_effect_repel/node_VFX_effect_repel.yy index c1599652e..9dc170265 100644 --- a/scripts/node_VFX_effect_repel/node_VFX_effect_repel.yy +++ b/scripts/node_VFX_effect_repel/node_VFX_effect_repel.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effect_turbulence/node_VFX_effect_turbulence.yy b/scripts/node_VFX_effect_turbulence/node_VFX_effect_turbulence.yy index 0315da5d7..881fd4af5 100644 --- a/scripts/node_VFX_effect_turbulence/node_VFX_effect_turbulence.yy +++ b/scripts/node_VFX_effect_turbulence/node_VFX_effect_turbulence.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effect_vortex/node_VFX_effect_vortex.yy b/scripts/node_VFX_effect_vortex/node_VFX_effect_vortex.yy index 7c13c258d..dd0144ffb 100644 --- a/scripts/node_VFX_effect_vortex/node_VFX_effect_vortex.yy +++ b/scripts/node_VFX_effect_vortex/node_VFX_effect_vortex.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effect_wind/node_VFX_effect_wind.yy b/scripts/node_VFX_effect_wind/node_VFX_effect_wind.yy index d4ae653a2..82729f4c5 100644 --- a/scripts/node_VFX_effect_wind/node_VFX_effect_wind.yy +++ b/scripts/node_VFX_effect_wind/node_VFX_effect_wind.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_effector/node_VFX_effector.gml b/scripts/node_VFX_effector/node_VFX_effector.gml index b3bbb7c8d..9c07b2428 100644 --- a/scripts/node_VFX_effector/node_VFX_effector.gml +++ b/scripts/node_VFX_effector/node_VFX_effector.gml @@ -9,10 +9,12 @@ enum FORCE_TYPE { } function Node_VFX_effector(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { - name = "Effector"; - color = COLORS.node_blend_vfx; - icon = THEME.vfx; - previewable = false; + name = "Effector"; + color = COLORS.node_blend_vfx; + icon = THEME.vfx; + reloop = true; + + previewable = false; node_draw_icon = s_node_vfx_accel; w = 96; diff --git a/scripts/node_VFX_effector/node_VFX_effector.yy b/scripts/node_VFX_effector/node_VFX_effector.yy index 8153c0b1c..c6841b656 100644 --- a/scripts/node_VFX_effector/node_VFX_effector.yy +++ b/scripts/node_VFX_effector/node_VFX_effector.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "effector", - "path": "folders/nodes/data/simulation/VFX/effector.yy", + "name": "affector", + "path": "folders/nodes/data/simulation/VFX/affector.yy", }, } \ No newline at end of file diff --git a/scripts/node_VFX_spawner/node_VFX_spawner.gml b/scripts/node_VFX_spawner/node_VFX_spawner.gml index 02882d407..e71fe0b3f 100644 --- a/scripts/node_VFX_spawner/node_VFX_spawner.gml +++ b/scripts/node_VFX_spawner/node_VFX_spawner.gml @@ -1,7 +1,8 @@ function Node_VFX_Spawner(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _group) constructor { - name = "Spawner"; - color = COLORS.node_blend_vfx; - icon = THEME.vfx; + name = "Spawner"; + color = COLORS.node_blend_vfx; + icon = THEME.vfx; + reloop = true; attributes.Output_pool = false; diff --git a/scripts/node_VFX_trail_path/node_VFX_trail_path.gml b/scripts/node_VFX_trail_path/node_VFX_trail_path.gml index 2ea579b36..2bf1fb27d 100644 --- a/scripts/node_VFX_trail_path/node_VFX_trail_path.gml +++ b/scripts/node_VFX_trail_path/node_VFX_trail_path.gml @@ -1,16 +1,20 @@ -function Node_VXF_Trail(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { - name = "Trail Path"; +function Node_VFX_Trail(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { + name = "VFX Trail"; previewable = false; w = 96; - length = []; - lengthAcc = []; + length = []; + lengthAcc = []; + lines = []; + lineLength = []; + lineData = []; - lines = []; + inputs[| 0] = nodeValue("Particles", self, JUNCTION_CONNECT.input, VALUE_TYPE.particle, -1 ) + .setVisible(true, true); - inputs[| 0] = nodeValue("Point array", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, []) - .setVisible(true, true) - .setArrayDepth(2); + inputs[| 1] = nodeValue("Life", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 4 ); + + inputs[| 2] = nodeValue("Color", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false ); outputs[| 0] = nodeValue("Path", self, JUNCTION_CONNECT.output, VALUE_TYPE.pathnode, self); @@ -35,26 +39,29 @@ function Node_VXF_Trail(_x, _y, _group = noone) : Node(_x, _y, _group) construct static getLength = function(index) { return array_safe_get(length, index); } static getAccuLength = function(index) { return array_safe_get(lengthAcc, index, []); } - static getPointRatio = function(_rat, _ind = 0) { #region + static getPointRatio = function(_rat, _ind = 0, out = undefined) { #region + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _p0, _p1; var _x, _y; - var line = array_safe_get(lines, _ind, []); + var line = lines[_ind]; + var _st = _rat * (lineLength[_ind] - 1); + _p0 = line[floor(_st) + 0]; + _p1 = line[floor(_st) + 1]; - var _st = _rat * (array_length(line) - 1); - _p0 = array_safe_get(line, floor(_st) + 0); - _p1 = array_safe_get(line, floor(_st) + 1); + if(!is_array(_p0)) return out; + if(!is_array(_p1)) return out; - if(!is_array(_p0)) return new __vec2(); - if(!is_array(_p1)) return new __vec2(); - - _x = lerp(_p0[0], _p1[0], frac(_st)); - _y = lerp(_p0[1], _p1[1], frac(_st)); + out.x = lerp(_p0[0], _p1[0], frac(_st)); + out.y = lerp(_p0[1], _p1[1], frac(_st)); - return new __vec2( _x, _y ); + return out; } #endregion - static getPointDistance = function(_dist, ind = 0) { return getPointRatio(_dist / length[ind], ind); } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / length[ind], ind, out); } + + static getPathData = function() { return lineData; } static getBoundary = function() { #region var boundary = new BoundingBox(); @@ -69,46 +76,64 @@ function Node_VXF_Trail(_x, _y, _group = noone) : Node(_x, _y, _group) construct } #endregion static update = function() { #region - var _lines = getInputData(0); - if(array_empty(_lines)) return; + var _vfxs = getInputData(0); + if(array_empty(_vfxs) || !is_array(_vfxs)) return; - lines = _lines; - if(!is_array(_lines[0][0])) - lines = [ lines ]; + var _life = getInputData(1); _life = max(_life, 1); + var _colr = getInputData(2); - var _len = array_length(lines); - length = array_create(_len); - lengthAcc = array_create(_len); + lines = []; + length = []; + lengthAcc = []; + lineLength = []; + lineData = []; - for( var i = 0; i < _len; i++ ) { - var _line = lines[i]; + for( var i = 0; i < array_length(_vfxs); i++ ) { + var _vfx = _vfxs[i]; + + var _posx = _vfx.x_history; + var _posy = _vfx.y_history; + + var _trail_ed = min(_vfx.life_incr, _vfx.life_total); + var _trail_st = max(1, _vfx.trailLife - _life); + var _trail_len = _trail_ed - _trail_st; + + if(_trail_len <= 0) continue; + var _lngh = 0; - var _lenA = []; + var _ox = _posx[_trail_st], _nx; + var _oy = _posy[_trail_st], _ny; + var _line = array_create(_trail_len); + var _lenA = array_create(_trail_len - 1); + _line[0] = [ _ox, _oy ]; - var _ox = _line[0], _nx; - - for( var j = 1, m = array_length(_line); j < m; j++ ) { - _nx = _line[j]; + for( var j = 0; j <= _trail_len; j++ ) { + var _index = _trail_st + j; + if(j == _trail_len) { + _nx = _vfx.drawx; + _ny = _vfx.drawy; + } else { + _nx = _posx[_index]; + _ny = _posy[_index]; + } - var p0x = array_safe_get(_ox, 0); - var p0y = array_safe_get(_ox, 1); - var p1x = array_safe_get(_nx, 0); - var p1y = array_safe_get(_nx, 1); - - p0x = is_real(p0x)? p0x : 0; - p0y = is_real(p0y)? p0y : 0; - p1x = is_real(p1x)? p1x : 0; - p1y = is_real(p1y)? p1y : 0; - - var dist = point_distance(p0x, p0y, p1x, p1y); + var dist = point_distance(_ox, _oy, _nx, _ny); _lngh += dist; - array_push(_lenA, dist); + _lenA[j] = _lngh; + _line[j] = [ _nx, _ny ]; _ox = _nx; } - length[i] = _lngh; - lengthAcc[i] = _lenA; + array_push(lines, _line); + array_push(length, _lngh); + array_push(lengthAcc, _lenA); + array_push(lineLength, array_length(_line)); + + if(_colr) + array_push(lineData, { + color: _vfx.blend, + }); } outputs[| 0].setValue(self); @@ -116,6 +141,6 @@ function Node_VXF_Trail(_x, _y, _group = noone) : Node(_x, _y, _group) construct static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) { #region var bbox = drawGetBbox(xx, yy, _s); - draw_sprite_fit(s_node_path_builder, 0, bbox.xc, bbox.yc, bbox.w, bbox.h); + draw_sprite_fit(s_node_vfx_trail, 0, bbox.xc, bbox.yc, bbox.w, bbox.h); } #endregion } \ No newline at end of file diff --git a/scripts/node_VFX_trail_path/node_VFX_trail_path.yy b/scripts/node_VFX_trail_path/node_VFX_trail_path.yy index 7d4ebc9fa..f741901f3 100644 --- a/scripts/node_VFX_trail_path/node_VFX_trail_path.yy +++ b/scripts/node_VFX_trail_path/node_VFX_trail_path.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "VFX", - "path": "folders/nodes/data/simulation/VFX.yy", + "name": "effects", + "path": "folders/nodes/data/simulation/VFX/effects.yy", }, } \ No newline at end of file diff --git a/scripts/node_armature_to_path/node_armature_to_path.gml b/scripts/node_armature_to_path/node_armature_to_path.gml index 0bb1d4fb1..1a9e4a310 100644 --- a/scripts/node_armature_to_path/node_armature_to_path.gml +++ b/scripts/node_armature_to_path/node_armature_to_path.gml @@ -59,21 +59,21 @@ function Node_Armature_Path(_x, _y, _group = noone) : Node(_x, _y, _group) const return lerp(_p0[2], _p1[2], _rat); } #endregion - static getPointDistance = function(_dist, _ind = 0) { #region - return getPointRatio(_dist / current_length, _ind); - } #endregion + static getPointDistance = function(_dist, _ind = 0, out = undefined) { return getPointRatio(_dist / current_length, _ind, out); } - static getPointRatio = function(_rat, _ind = 0) { #region + static getPointRatio = function(_rat, _ind = 0, out = undefined) { #region + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _p0 = lines[_ind][0]; var _p1 = lines[_ind][1]; - if(!is_array(_p0) || array_length(_p0) < 2) return new __vec2(); - if(!is_array(_p1) || array_length(_p1) < 2) return new __vec2(); + if(!is_array(_p0) || array_length(_p0) < 2) return out; + if(!is_array(_p1) || array_length(_p1) < 2) return out; - var _x = lerp(_p0[0], _p1[0], _rat); - var _y = lerp(_p0[1], _p1[1], _rat); + out.x = lerp(_p0[0], _p1[0], _rat); + out.y = lerp(_p0[1], _p1[1], _rat); - return new __vec2( _x, _y ); + return out; } #endregion static update = function() { #region diff --git a/scripts/node_line/node_line.gml b/scripts/node_line/node_line.gml index 4d03279a1..0a2c8a138 100644 --- a/scripts/node_line/node_line.gml +++ b/scripts/node_line/node_line.gml @@ -62,12 +62,14 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[| 23] = nodeValue("Texture scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ]) .setDisplay(VALUE_DISPLAY.vector); + inputs[| 24] = nodeValue("Random Blend", self, JUNCTION_CONNECT.input, VALUE_TYPE.gradient, new gradientObject(c_white) ); + input_display_list = [ ["Output", true], 0, 1, ["Line data", false], 6, 7, 19, 2, 20, ["Line settings", false], 17, 3, 11, 12, 8, 9, 13, 14, ["Wiggle", false], 4, 5, - ["Render", false], 10, 15, 16, + ["Render", false], 10, 24, 15, 16, ["Texture", false], 18, 21, 22, 23, ]; @@ -78,7 +80,7 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons attribute_surface_depth(); attribute_interpolation(); - static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { + static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region draw_set_color(COLORS._main_accent); for( var i = 0, n = array_length(lines); i < n; i++ ) { var points = lines[i]; @@ -98,9 +100,9 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons draw_line(x0, y0, x1, y1); } } - } + } #endregion - static step = function() { + static step = function() { #region var px = !getInputData(17); var _tex = inputs[| 18].value_from != noone; var _flen = getInputData(19); @@ -117,7 +119,7 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[| 2].setVisible(!_flen); inputs[| 20].setVisible( _flen); - } + } #endregion static processData = function(_outSurf, _data, _output_index, _array_index) { var _dim = _data[0]; @@ -149,6 +151,8 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons var _texRot = _data[22]; var _texSca = _data[23]; + var _colb = _data[24]; + inputs[| 14].setVisible(_cap); var _rangeMin = min(_ratio[0], _ratio[1]); @@ -174,14 +178,19 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons _outSurf = surface_verify(_outSurf, _dim[0], _dim[1], attrDepth()); + var p = new __vec2(); var _ox, _nx, _nx1, _oy, _ny, _ny1; var _ow, _nw, _oa, _na, _oc, _nc, _owg, _nwg; + var _pathData = []; + lines = []; - if(_use_path) { + if(_use_path) { #region var lineLen = 1; if(struct_has(_pat, "getLineCount")) lineLen = _pat.getLineCount(); + if(struct_has(_pat, "getPathData")) + _pathData = _pat.getPathData(); if(_rtMax > 0) for( var i = 0; i < lineLen; i++ ) { @@ -207,7 +216,7 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons var _prog = _prog_curr + 1; //Record previous position to delete from _total var _prog_total = 0; //Record how far the pointer have moved so far var points = []; - var p, wght; + var wght; if(_useDistance) { _pathStr *= _pathLength; @@ -238,11 +247,11 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons wght = 1; if(_useDistance) { - p = _pat.getPointDistance(_prog_curr, i); + p = _pat.getPointDistance(_prog_curr, i, p); if(struct_has(_pat, "getWeightRatio")) wght = _pat.getWeightRatio(_prog_curr, i); } else { - p = _pat.getPointRatio(_prog_curr, i); + p = _pat.getPointRatio(_prog_curr, i, p); if(struct_has(_pat, "getWeightDistance")) wght = _pat.getWeightDistance(_prog_curr, i); } @@ -281,7 +290,8 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons array_push(lines, points); } - } else { + #endregion + } else { #region var x0, y0, x1, y1; var _0 = point_rectangle_overlap(_dim[0], _dim[1], (_ang + 180) % 360); var _1 = point_rectangle_overlap(_dim[0], _dim[1], _ang); @@ -322,7 +332,7 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons } lines = [ points ]; - } + } #endregion surface_set_target(_outSurf); if(_bg) draw_clear_alpha(0, 1); @@ -340,11 +350,16 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons draw_primitive_begin_texture(pr_trianglestrip, tex); } + for( var i = 0, n = array_length(lines); i < n; i++ ) { var points = lines[i]; if(array_length(points) < 2) continue; + random_set_seed(_sed + i); var pxs = []; + var dat = array_safe_get(_pathData, i, noone); + + var _col_base = dat == noone? _colb.eval(random(1)) : dat.color; for( var j = 0; j < array_length(points); j++ ) { var p0 = points[j]; @@ -362,7 +377,7 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons _nw *= eval_curve_x(_widc, _widap? prog : prgc); _nw *= p0.weight; - _nc = _color.eval(_colP? prog : prgc); + _nc = colorMultiply(_col_base, _color.eval(_colP? prog : prgc)); if(_cap) { if(j == 1) { diff --git a/scripts/node_path/node_path.gml b/scripts/node_path/node_path.gml index 5102f3ec5..941f31145 100644 --- a/scripts/node_path/node_path.gml +++ b/scripts/node_path/node_path.gml @@ -881,10 +881,12 @@ function Node_Path(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { static getLength = function() { return lengthTotal; } static getAccuLength = function() { return lengthAccs; } - static getPointDistance = function(_dist) { #region + static getPointDistance = function(_dist, _ind = 0, out = undefined) { #region if(ds_map_exists(cached_pos, _dist)) return cached_pos[? _dist].clone(); + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var loop = getInputData(1); var rond = getInputData(3); if(!is_real(rond)) rond = false; @@ -895,7 +897,7 @@ function Node_Path(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { var ansize = array_length(lengths); var amo = ds_list_size(inputs) - input_fix_len; - if(ansize == 0) return new __vec2(); + if(ansize == 0) return out; var _a0, _a1; @@ -904,7 +906,7 @@ function Node_Path(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { _a1 = array_clone(anchors[safe_mod(i + 1, amo)]); if(!is_array(_a0) || !is_array(_a1)) - return new __vec2(); + return out; if(rond) { _a0[0] = round(_a0[0]); @@ -920,18 +922,19 @@ function Node_Path(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { var _t = _dist / lengths[i]; var _p = eval_bezier(_t, _a0[0], _a0[1], _a1[0], _a1[1], _a0[0] + _a0[4], _a0[1] + _a0[5], _a1[0] + _a1[2], _a1[1] + _a1[3]); - var _point = new __vec2(_p); + out.x = _p[0]; + out.y = _p[1]; - cached_pos[? _oDist] = _point.clone(); - return _point; + cached_pos[? _oDist] = out.clone(); + return out; } - return new __vec2(); + return out; } #endregion - static getPointRatio = function(_rat) { #region + static getPointRatio = function(_rat, _ind = 0, out = undefined) { #region var pix = frac(_rat) * lengthTotal; - return getPointDistance(pix); + return getPointDistance(pix, _ind, out); } #endregion static getPointSegment = function(_rat) { #region diff --git a/scripts/node_path_blend/node_path_blend.gml b/scripts/node_path_blend/node_path_blend.gml index e8016587a..fc893793d 100644 --- a/scripts/node_path_blend/node_path_blend.gml +++ b/scripts/node_path_blend/node_path_blend.gml @@ -85,7 +85,9 @@ function Node_Path_Blend(_x, _y, _group = noone) : Node(_x, _y, _group) construc return res; } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _path1 = getInputData(0); var _path2 = getInputData(1); var _lerp = getInputData(2); @@ -93,23 +95,20 @@ function Node_Path_Blend(_x, _y, _group = noone) : Node(_x, _y, _group) construc var p1 = _path1 != noone && struct_has(_path1, "getPointRatio"); var p2 = _path2 != noone && struct_has(_path2, "getPointRatio"); - if(!p1 && !p2) return new __vec2(); - if( p1 && !p2) return _path1.getPointRatio(_rat, ind); - if(!p1 && p2) return _path2.getPointRatio(_rat, ind); + if(!p1 && !p2) return out; + if( p1 && !p2) return _path1.getPointRatio(_rat, ind, out); + if(!p1 && p2) return _path2.getPointRatio(_rat, ind, out); var _p1 = _path1.getPointRatio(_rat, ind); var _p2 = _path2.getPointRatio(_rat, ind); - var _r = new __vec2(); - _r.x = lerp(_p1.x, _p2.x, _lerp); - _r.y = lerp(_p1.y, _p2.y, _lerp); + out.x = lerp(_p1.x, _p2.x, _lerp); + out.y = lerp(_p1.y, _p2.y, _lerp); - return _r; + return out; } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(ind), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(ind), ind, out); } static getBoundary = function(ind = 0) { var _path1 = getInputData(0); diff --git a/scripts/node_path_builder/node_path_builder.gml b/scripts/node_path_builder/node_path_builder.gml index 897948b15..8fc0c6de7 100644 --- a/scripts/node_path_builder/node_path_builder.gml +++ b/scripts/node_path_builder/node_path_builder.gml @@ -35,26 +35,27 @@ function Node_Path_Builder(_x, _y, _group = noone) : Node(_x, _y, _group) constr static getLength = function(index) { return array_safe_get(length, index); } static getAccuLength = function(index) { return array_safe_get(lengthAcc, index, []); } - static getPointRatio = function(_rat, _ind = 0) { #region + static getPointRatio = function(_rat, _ind = 0, out = undefined) { #region + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _p0, _p1; var _x, _y; var line = array_safe_get(lines, _ind, []); - - var _st = _rat * (array_length(line) - 1); + var _st = _rat * (array_length(line) - 1); _p0 = array_safe_get(line, floor(_st) + 0); _p1 = array_safe_get(line, floor(_st) + 1); - if(!is_array(_p0)) return new __vec2(); - if(!is_array(_p1)) return new __vec2(); + if(!is_array(_p0)) return out; + if(!is_array(_p1)) return out; - _x = lerp(_p0[0], _p1[0], frac(_st)); - _y = lerp(_p0[1], _p1[1], frac(_st)); + out.x = lerp(_p0[0], _p1[0], frac(_st)); + out.y = lerp(_p0[1], _p1[1], frac(_st)); - return new __vec2( _x, _y ); + return out; } #endregion - static getPointDistance = function(_dist, ind = 0) { return getPointRatio(_dist / length[ind], ind); } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / length[ind], ind, out); } static getBoundary = function() { #region var boundary = new BoundingBox(); diff --git a/scripts/node_path_l_system/node_path_l_system.gml b/scripts/node_path_l_system/node_path_l_system.gml index 65b589297..d2ea09e3b 100644 --- a/scripts/node_path_l_system/node_path_l_system.gml +++ b/scripts/node_path_l_system/node_path_l_system.gml @@ -188,22 +188,22 @@ function Node_Path_L_System(_x, _y, _group = noone) : Node(_x, _y, _group) const return lerp(_p0[2], _p1[2], _rat); } #endregion - static getPointRatio = function(_rat, _ind = 0) { #region + static getPointRatio = function(_rat, _ind = 0, out = undefined) { #region + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _p0 = lines[_ind][0]; var _p1 = lines[_ind][1]; - if(!is_array(_p0) || array_length(_p0) < 2) return new __vec2(); - if(!is_array(_p1) || array_length(_p1) < 2) return new __vec2(); + if(!is_array(_p0) || array_length(_p0) < 2) return out; + if(!is_array(_p1) || array_length(_p1) < 2) return out; - var _x = lerp(_p0[0], _p1[0], _rat); - var _y = lerp(_p0[1], _p1[1], _rat); + out.x = lerp(_p0[0], _p1[0], _rat); + out.y = lerp(_p0[1], _p1[1], _rat); - return new __vec2( _x, _y ); + return out; } #endregion - static getPointDistance = function(_dist, _ind = 0) { #region - return getPointRatio(_dist / current_length, _ind); - } #endregion + static getPointDistance = function(_dist, _ind = 0, out = undefined) { return getPointRatio(_dist / current_length, _ind, out); } static getBoundary = function() { return boundary; } diff --git a/scripts/node_path_map_area/node_path_map_area.gml b/scripts/node_path_map_area/node_path_map_area.gml index bc8cad032..0b7584395 100644 --- a/scripts/node_path_map_area/node_path_map_area.gml +++ b/scripts/node_path_map_area/node_path_map_area.gml @@ -37,7 +37,9 @@ function Node_Path_Map_Area(_x, _y, _group = noone) : Node(_x, _y, _group) const return struct_has(_path, "getAccuLength")? _path.getAccuLength(ind) : []; } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _path = getInputData(0); var _area = getInputData(1); @@ -47,20 +49,18 @@ function Node_Path_Map_Area(_x, _y, _group = noone) : Node(_x, _y, _group) const } if(!is_struct(_path) || !struct_has(_path, "getPointRatio")) - return new __vec2(); + return out; var _b = _path.getBoundary(); - var _p = _path.getPointRatio(_rat, ind).clone(); + var _p = _path.getPointRatio(_rat, ind); - _p.x = (_area[AREA_INDEX.center_x] - _area[AREA_INDEX.half_w]) + (_p.x - _b.minx) / _b.width * _area[AREA_INDEX.half_w] * 2; - _p.y = (_area[AREA_INDEX.center_y] - _area[AREA_INDEX.half_h]) + (_p.y - _b.miny) / _b.height * _area[AREA_INDEX.half_h] * 2; + out.x = (_area[AREA_INDEX.center_x] - _area[AREA_INDEX.half_w]) + (_p.x - _b.minx) / _b.width * _area[AREA_INDEX.half_w] * 2; + out.y = (_area[AREA_INDEX.center_y] - _area[AREA_INDEX.half_h]) + (_p.y - _b.miny) / _b.height * _area[AREA_INDEX.half_h] * 2; - return _p; + return out; } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(), ind, out); } static getBoundary = function() { var _area = getInputData(1); diff --git a/scripts/node_path_plot/node_path_plot.gml b/scripts/node_path_plot/node_path_plot.gml index 9e443b955..d2c872f0e 100644 --- a/scripts/node_path_plot/node_path_plot.gml +++ b/scripts/node_path_plot/node_path_plot.gml @@ -50,7 +50,9 @@ function Node_Path_Plot(_x, _y, _group = noone) : Node(_x, _y, _group) construct static getLength = function(ind = 0) { return length; } static getAccuLength = function(ind = 0) { return [ length ]; } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _sca = getInputData(0); var _coor = getInputData(1); var _eqa = getInputData(2); @@ -63,22 +65,20 @@ function Node_Path_Plot(_x, _y, _group = noone) : Node(_x, _y, _group) construct _rat = _ran[0] + (_rat * (_ran[1] - _ran[0])); - var _p = new __vec2(); - switch(_coor) { case 0 : switch(_eqa) { case 0 : - _p.x = _rat * _iran[0] + _shf[0]; - _p.y = evaluateFunction(_eq0, { x: _rat * _iran[0] + _shf[0] }); + out.x = _rat * _iran[0] + _shf[0]; + out.y = evaluateFunction(_eq0, { x: _rat * _iran[0] + _shf[0] }); break; case 1 : - _p.x = evaluateFunction(_eq0, { y: _rat * _iran[1] + _shf[1] }); - _p.y = _rat * _iran[1] + _shf[1]; + out.x = evaluateFunction(_eq0, { y: _rat * _iran[1] + _shf[1] }); + out.y = _rat * _iran[1] + _shf[1]; break; case 2 : - _p.x = evaluateFunction(_eq0, { t: _rat * _iran[0] + _shf[0] }); - _p.y = evaluateFunction(_eq1, { t: _rat * _iran[1] + _shf[1] }); + out.x = evaluateFunction(_eq0, { t: _rat * _iran[0] + _shf[0] }); + out.y = evaluateFunction(_eq1, { t: _rat * _iran[1] + _shf[1] }); break; } break; @@ -99,20 +99,18 @@ function Node_Path_Plot(_x, _y, _group = noone) : Node(_x, _y, _group) construct break; } - _p.x = cos(_a.y) * _a.x; - _p.y = -sin(_a.y) * _a.x; + out.x = cos(_a.y) * _a.x; + out.y = -sin(_a.y) * _a.x; break; } - _p.x = _p.x * _sca[0] + _orig[0]; - _p.y = -_p.y * _sca[1] + _orig[1]; + out.x = out.x * _sca[0] + _orig[0]; + out.y = -out.y * _sca[1] + _orig[1]; - return _p; + return out; } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(ind), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(ind), ind, out); } static getBoundary = function() { return boundary; } diff --git a/scripts/node_path_reverse/node_path_reverse.gml b/scripts/node_path_reverse/node_path_reverse.gml index 36d21cba4..d1c65377a 100644 --- a/scripts/node_path_reverse/node_path_reverse.gml +++ b/scripts/node_path_reverse/node_path_reverse.gml @@ -34,17 +34,16 @@ function Node_Path_Reverse(_x, _y, _group = noone) : Node(_x, _y, _group) constr return struct_has(_path, "getBoundary")? _path.getBoundary(ind) : new BoundingBox(0, 0, 1, 1); } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } var _path = getInputData(0); if(!is_struct(_path) || !struct_has(_path, "getPointRatio")) - return new __vec2(); - return _path.getPointRatio(1 - _rat, ind).clone(); + return out; + return _path.getPointRatio(1 - _rat, ind, out); } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(), ind, out); } static update = function() { outputs[| 0].setValue(self); diff --git a/scripts/node_path_shift/node_path_shift.gml b/scripts/node_path_shift/node_path_shift.gml index b931bb490..3b77f368a 100644 --- a/scripts/node_path_shift/node_path_shift.gml +++ b/scripts/node_path_shift/node_path_shift.gml @@ -31,7 +31,9 @@ function Node_Path_Shift(_x, _y, _group = noone) : Node(_x, _y, _group) construc return struct_has(_path, "getAccuLength")? _path.getAccuLength(ind) : []; } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _path = getInputData(0); var _shf = getInputData(1); @@ -41,23 +43,21 @@ function Node_Path_Shift(_x, _y, _group = noone) : Node(_x, _y, _group) construc } if(!is_struct(_path) || !struct_has(_path, "getPointRatio")) - return new __vec2(); + return out; var _p0 = _path.getPointRatio(clamp(_rat - 0.001, 0, 0.999999), ind); - var _p = _path.getPointRatio(_rat, ind).clone(); + var _p = _path.getPointRatio(_rat, ind); var _p1 = _path.getPointRatio(clamp(_rat + 0.001, 0, 0.999999), ind); var dir = point_direction(_p0.x, _p0.y, _p1.x, _p1.y) + 90; - _p.x += lengthdir_x(_shf, dir); - _p.y += lengthdir_y(_shf, dir); + out.x += _p.x + lengthdir_x(_shf, dir); + out.y += _p.y + lengthdir_y(_shf, dir); - return _p; + return out; } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(), ind, out); } static getBoundary = function(ind = 0) { var _path = getInputData(0); diff --git a/scripts/node_path_transform/node_path_transform.gml b/scripts/node_path_transform/node_path_transform.gml index 4abb649d1..fc4c8faf5 100644 --- a/scripts/node_path_transform/node_path_transform.gml +++ b/scripts/node_path_transform/node_path_transform.gml @@ -83,7 +83,9 @@ function Node_Path_Transform(_x, _y, _group = noone) : Node(_x, _y, _group) cons return new BoundingBox(_minx, _miny, _maxx, _maxy); } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _path = getInputData(0); var _pos = getInputData(1); var _rot = getInputData(2); @@ -96,7 +98,7 @@ function Node_Path_Transform(_x, _y, _group = noone) : Node(_x, _y, _group) cons } if(!is_struct(_path) || !struct_has(_path, "getPointRatio")) - return new __vec2(); + return out; var _p = _path.getPointRatio(_rat, ind).clone(); @@ -105,15 +107,13 @@ function Node_Path_Transform(_x, _y, _group = noone) : Node(_x, _y, _group) cons var _pp = point_rotate(_p.x, _p.y, _anc[0], _anc[1], _rot); - _p.x = _pp[0] + _pos[0]; - _p.y = _pp[1] + _pos[1]; + out.x = _pp[0] + _pos[0]; + out.y = _pp[1] + _pos[1]; - return _p; + return out; } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(), ind, out); } static getBoundary = function(ind = 0) { var _path = getInputData(0); diff --git a/scripts/node_path_trim/node_path_trim.gml b/scripts/node_path_trim/node_path_trim.gml index 9d333668b..59333c1fe 100644 --- a/scripts/node_path_trim/node_path_trim.gml +++ b/scripts/node_path_trim/node_path_trim.gml @@ -32,7 +32,9 @@ function Node_Path_Trim(_x, _y, _group = noone) : Node(_x, _y, _group) construct return struct_has(_path, "getAccuLength")? _path.getAccuLength(ind) : []; } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _path = getInputData(0); var _rng = getInputData(1); @@ -42,15 +44,13 @@ function Node_Path_Trim(_x, _y, _group = noone) : Node(_x, _y, _group) construct } if(!is_struct(_path) || !struct_has(_path, "getPointRatio")) - return new __vec2(); + return out; _rat = _rng[0] + _rat * (_rng[1] - _rng[0]); - return _path.getPointRatio(_rat, ind).clone(); + return _path.getPointRatio(_rat, ind, out); } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(), ind, out); } static getBoundary = function(ind = 0) { var _path = getInputData(0); diff --git a/scripts/node_path_wave/node_path_wave.gml b/scripts/node_path_wave/node_path_wave.gml index 34a1b2f45..8af87d4af 100644 --- a/scripts/node_path_wave/node_path_wave.gml +++ b/scripts/node_path_wave/node_path_wave.gml @@ -57,7 +57,9 @@ function Node_Path_Wave(_x, _y, _group = noone) : Node(_x, _y, _group) construct return _len; } - static getPointRatio = function(_rat, ind = 0) { + static getPointRatio = function(_rat, ind = 0, out = undefined) { + if(out == undefined) out = new __vec2(); else { out.x = 0; out.y = 0; } + var _path = getInputData(0); var _fre = getInputData(1); _fre = max(0.01, abs(_fre)); var _amo = getInputData(2); @@ -70,7 +72,7 @@ function Node_Path_Wave(_x, _y, _group = noone) : Node(_x, _y, _group) construct } if(!is_struct(_path) || !struct_has(_path, "getPointRatio")) - return new __vec2(); + return out; var _p0 = _path.getPointRatio(clamp(_rat - 0.001, 0, 0.999999), ind); var _p = _path.getPointRatio(_rat, ind).clone(); @@ -82,15 +84,13 @@ function Node_Path_Wave(_x, _y, _group = noone) : Node(_x, _y, _group) construct if(_smt) prg = cos((_shf + _rat * _fre) * pi * 2); else prg = (abs(frac(_shf + _rat * _fre) * 2 - 1) - 0.5) * 2; - _p.x = _p.x + lengthdir_x(prg * _amo, dir); - _p.y = _p.y + lengthdir_y(prg * _amo, dir); + out.x = _p.x + lengthdir_x(prg * _amo, dir); + out.y = _p.y + lengthdir_y(prg * _amo, dir); - return _p; + return out; } - static getPointDistance = function(_dist, ind = 0) { - return getPointRatio(_dist / getLength(), ind); - } + static getPointDistance = function(_dist, ind = 0, out = undefined) { return getPointRatio(_dist / getLength(), ind, out); } static getBoundary = function(ind = 0) { var _path = getInputData(0); diff --git a/scripts/node_registry/node_registry.gml b/scripts/node_registry/node_registry.gml index f0bccac1c..11662147c 100644 --- a/scripts/node_registry/node_registry.gml +++ b/scripts/node_registry/node_registry.gml @@ -183,6 +183,10 @@ function NodeObject(_name, _spr, _node, _create, tags = []) constructor { #regio addNodeObject(vfx, "Vortex", s_node_vfx_vortex, "Node_VFX_Vortex", [1, Node_VFX_Vortex]).hideRecent(); addNodeObject(vfx, "Turbulence", s_node_vfx_turb, "Node_VFX_Turbulence", [1, Node_VFX_Turbulence]).hideRecent(); addNodeObject(vfx, "Repel", s_node_vfx_repel, "Node_VFX_Repel", [1, Node_VFX_Repel]).hideRecent(); + addNodeObject(vfx, "Oscillate", s_node_vfx_osc, "Node_VFX_Oscillate", [1, Node_VFX_Oscillate]).hideRecent().setVersion(11560); + + ds_list_add(vfx, "Effects"); + addNodeObject(vfx, "VFX Trail", s_node_vfx_trail, "Node_VFX_Trail", [1, Node_VFX_Trail]).hideRecent().setVersion(11560); ds_list_add(vfx, "Instance control"); addNodeObject(vfx, "VFX Variable", s_node_vfx_variable, "Node_VFX_Variable", [1, Node_VFX_Variable]).hideRecent().setVersion(1120); diff --git a/sprites/s_node_vfx_osc/bbcb8f25-322d-4324-be8e-735cd9841834.png b/sprites/s_node_vfx_osc/bbcb8f25-322d-4324-be8e-735cd9841834.png new file mode 100644 index 000000000..6feb3811a Binary files /dev/null and b/sprites/s_node_vfx_osc/bbcb8f25-322d-4324-be8e-735cd9841834.png differ diff --git a/sprites/s_node_vfx_osc/layers/bbcb8f25-322d-4324-be8e-735cd9841834/a4270f72-0a04-4469-8a8b-0b6b2f7f61e8.png b/sprites/s_node_vfx_osc/layers/bbcb8f25-322d-4324-be8e-735cd9841834/a4270f72-0a04-4469-8a8b-0b6b2f7f61e8.png new file mode 100644 index 000000000..6feb3811a Binary files /dev/null and b/sprites/s_node_vfx_osc/layers/bbcb8f25-322d-4324-be8e-735cd9841834/a4270f72-0a04-4469-8a8b-0b6b2f7f61e8.png differ diff --git a/sprites/s_node_vfx_osc/s_node_vfx_osc.yy b/sprites/s_node_vfx_osc/s_node_vfx_osc.yy new file mode 100644 index 000000000..f35fd0011 --- /dev/null +++ b/sprites/s_node_vfx_osc/s_node_vfx_osc.yy @@ -0,0 +1,74 @@ +{ + "resourceType": "GMSprite", + "resourceVersion": "1.0", + "name": "s_node_vfx_osc", + "bbox_bottom": 46, + "bbox_left": 2, + "bbox_right": 61, + "bbox_top": 16, + "bboxMode": 0, + "collisionKind": 1, + "collisionTolerance": 0, + "DynamicTexturePage": false, + "edgeFiltering": false, + "For3D": false, + "frames": [ + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"bbcb8f25-322d-4324-be8e-735cd9841834",}, + ], + "gridX": 0, + "gridY": 0, + "height": 64, + "HTile": false, + "layers": [ + {"resourceType":"GMImageLayer","resourceVersion":"1.0","name":"a4270f72-0a04-4469-8a8b-0b6b2f7f61e8","blendMode":0,"displayName":"default","isLocked":false,"opacity":100.0,"visible":true,}, + ], + "nineSlice": null, + "origin": 4, + "parent": { + "name": "VFX", + "path": "folders/nodes/icons/VFX.yy", + }, + "preMultiplyAlpha": false, + "sequence": { + "resourceType": "GMSequence", + "resourceVersion": "1.4", + "name": "s_node_vfx_osc", + "autoRecord": true, + "backdropHeight": 768, + "backdropImageOpacity": 0.5, + "backdropImagePath": "", + "backdropWidth": 1366, + "backdropXOffset": 0.0, + "backdropYOffset": 0.0, + "events": {"resourceType":"KeyframeStore","resourceVersion":"1.0","Keyframes":[],}, + "eventStubScript": null, + "eventToFunction": {}, + "length": 1.0, + "lockOrigin": false, + "moments": {"resourceType":"KeyframeStore","resourceVersion":"1.0","Keyframes":[],}, + "playback": 1, + "playbackSpeed": 30.0, + "playbackSpeedType": 0, + "showBackdrop": true, + "showBackdropImage": false, + "timeUnits": 1, + "tracks": [ + {"resourceType":"GMSpriteFramesTrack","resourceVersion":"1.0","name":"frames","builtinName":0,"events":[],"inheritsTrackColour":true,"interpolation":1,"isCreationTrack":false,"keyframes":{"resourceType":"KeyframeStore","resourceVersion":"1.0","Keyframes":[ + {"resourceType":"Keyframe","resourceVersion":"1.0","Channels":{"0":{"resourceType":"SpriteFrameKeyframe","resourceVersion":"1.0","Id":{"name":"bbcb8f25-322d-4324-be8e-735cd9841834","path":"sprites/s_node_vfx_osc/s_node_vfx_osc.yy",},},},"Disabled":false,"id":"7181b459-5a9b-4c6c-9086-1ed2189e4803","IsCreationKey":false,"Key":0.0,"Length":1.0,"Stretch":false,}, + ],},"modifiers":[],"spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, + ], + "visibleRange": null, + "volume": 1.0, + "xorigin": 32, + "yorigin": 32, + }, + "swatchColours": null, + "swfPrecision": 2.525, + "textureGroupId": { + "name": "Default", + "path": "texturegroups/Default", + }, + "type": 0, + "VTile": false, + "width": 64, +} \ No newline at end of file diff --git a/sprites/s_node_vfx_trail/ec7e642d-f177-401b-8170-cd85e15f73b1.png b/sprites/s_node_vfx_trail/ec7e642d-f177-401b-8170-cd85e15f73b1.png new file mode 100644 index 000000000..6228b7332 Binary files /dev/null and b/sprites/s_node_vfx_trail/ec7e642d-f177-401b-8170-cd85e15f73b1.png differ diff --git a/sprites/s_node_vfx_trail/layers/ec7e642d-f177-401b-8170-cd85e15f73b1/4b8a939f-c4b9-4560-9f87-0e4aec9b9e1b.png b/sprites/s_node_vfx_trail/layers/ec7e642d-f177-401b-8170-cd85e15f73b1/4b8a939f-c4b9-4560-9f87-0e4aec9b9e1b.png new file mode 100644 index 000000000..6228b7332 Binary files /dev/null and b/sprites/s_node_vfx_trail/layers/ec7e642d-f177-401b-8170-cd85e15f73b1/4b8a939f-c4b9-4560-9f87-0e4aec9b9e1b.png differ diff --git a/sprites/s_node_vfx_trail/s_node_vfx_trail.yy b/sprites/s_node_vfx_trail/s_node_vfx_trail.yy new file mode 100644 index 000000000..b0b4db392 --- /dev/null +++ b/sprites/s_node_vfx_trail/s_node_vfx_trail.yy @@ -0,0 +1,74 @@ +{ + "resourceType": "GMSprite", + "resourceVersion": "1.0", + "name": "s_node_vfx_trail", + "bbox_bottom": 60, + "bbox_left": 6, + "bbox_right": 57, + "bbox_top": 6, + "bboxMode": 0, + "collisionKind": 1, + "collisionTolerance": 0, + "DynamicTexturePage": false, + "edgeFiltering": false, + "For3D": false, + "frames": [ + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"ec7e642d-f177-401b-8170-cd85e15f73b1",}, + ], + "gridX": 0, + "gridY": 0, + "height": 64, + "HTile": false, + "layers": [ + {"resourceType":"GMImageLayer","resourceVersion":"1.0","name":"4b8a939f-c4b9-4560-9f87-0e4aec9b9e1b","blendMode":0,"displayName":"default","isLocked":false,"opacity":100.0,"visible":true,}, + ], + "nineSlice": null, + "origin": 4, + "parent": { + "name": "VFX", + "path": "folders/nodes/icons/VFX.yy", + }, + "preMultiplyAlpha": false, + "sequence": { + "resourceType": "GMSequence", + "resourceVersion": "1.4", + "name": "s_node_vfx_trail", + "autoRecord": true, + "backdropHeight": 768, + "backdropImageOpacity": 0.5, + "backdropImagePath": "", + "backdropWidth": 1366, + "backdropXOffset": 0.0, + "backdropYOffset": 0.0, + "events": {"resourceType":"KeyframeStore","resourceVersion":"1.0","Keyframes":[],}, + "eventStubScript": null, + "eventToFunction": {}, + "length": 1.0, + "lockOrigin": false, + "moments": {"resourceType":"KeyframeStore","resourceVersion":"1.0","Keyframes":[],}, + "playback": 1, + "playbackSpeed": 30.0, + "playbackSpeedType": 0, + "showBackdrop": true, + "showBackdropImage": false, + "timeUnits": 1, + "tracks": [ + {"resourceType":"GMSpriteFramesTrack","resourceVersion":"1.0","name":"frames","builtinName":0,"events":[],"inheritsTrackColour":true,"interpolation":1,"isCreationTrack":false,"keyframes":{"resourceType":"KeyframeStore","resourceVersion":"1.0","Keyframes":[ + {"resourceType":"Keyframe","resourceVersion":"1.0","Channels":{"0":{"resourceType":"SpriteFrameKeyframe","resourceVersion":"1.0","Id":{"name":"ec7e642d-f177-401b-8170-cd85e15f73b1","path":"sprites/s_node_vfx_trail/s_node_vfx_trail.yy",},},},"Disabled":false,"id":"1be8543a-938a-4680-b1d6-502f8412462f","IsCreationKey":false,"Key":0.0,"Length":1.0,"Stretch":false,}, + ],},"modifiers":[],"spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, + ], + "visibleRange": null, + "volume": 1.0, + "xorigin": 32, + "yorigin": 32, + }, + "swatchColours": null, + "swfPrecision": 2.525, + "textureGroupId": { + "name": "Default", + "path": "texturegroups/Default", + }, + "type": 0, + "VTile": false, + "width": 64, +} \ No newline at end of file