diff --git a/PixelComposer.resource_order b/PixelComposer.resource_order index 17451f304..72878ba83 100644 --- a/PixelComposer.resource_order +++ b/PixelComposer.resource_order @@ -133,6 +133,8 @@ {"name":"lua","order":12,"path":"folders/nodes/data/lua.yy",}, {"name":"misc","order":10,"path":"folders/nodes/data/misc.yy",}, {"name":"MK effects","order":24,"path":"folders/nodes/data/MK effects.yy",}, + {"name":"mk flare","order":13,"path":"folders/nodes/data/MK effects/mk flare.yy",}, + {"name":"src","order":1,"path":"folders/nodes/data/MK effects/mk flare/src.yy",}, {"name":"mk sparkle","order":7,"path":"folders/nodes/data/MK effects/mk sparkle.yy",}, {"name":"src","order":1,"path":"folders/nodes/data/MK effects/mk sparkle/src.yy",}, {"name":"PCX","order":15,"path":"folders/nodes/data/PCX.yy",}, @@ -1125,7 +1127,6 @@ {"name":"sh_color_select_content","order":1,"path":"shaders/sh_color_select_content/sh_color_select_content.yy",}, {"name":"s_node_hlsl","order":32,"path":"sprites/s_node_hlsl/s_node_hlsl.yy",}, {"name":"sh_outline","order":18,"path":"shaders/sh_outline/sh_outline.yy",}, - {"name":"node_mk_flare","order":12,"path":"scripts/node_mk_flare/node_mk_flare.yy",}, {"name":"s_node_strandSim_break","order":8,"path":"sprites/s_node_strandSim_break/s_node_strandSim_break.yy",}, {"name":"s_node_scatter_point","order":4,"path":"sprites/s_node_scatter_point/s_node_scatter_point.yy",}, {"name":"Obj_FirebaseFirestore_Collection_Query_NotEqual","order":9,"path":"objects/Obj_FirebaseFirestore_Collection_Query_NotEqual/Obj_FirebaseFirestore_Collection_Query_NotEqual.yy",}, @@ -1412,6 +1413,7 @@ {"name":"s_node_path_map","order":2,"path":"sprites/s_node_path_map/s_node_path_map.yy",}, {"name":"node_iterator_filter_inline_input","order":1,"path":"scripts/node_iterator_filter_inline_input/node_iterator_filter_inline_input.yy",}, {"name":"s_node_greyscale","order":26,"path":"sprites/s_node_greyscale/s_node_greyscale.yy",}, + {"name":"s_node_mk_flare","order":11,"path":"sprites/s_node_mk_flare/s_node_mk_flare.yy",}, {"name":"sh_dilate","order":4,"path":"shaders/sh_dilate/sh_dilate.yy",}, {"name":"node_image_sequence","order":1,"path":"scripts/node_image_sequence/node_image_sequence.yy",}, {"name":"node_text_file_read","order":6,"path":"scripts/node_text_file_read/node_text_file_read.yy",}, diff --git a/PixelComposer.yyp b/PixelComposer.yyp index bc17f089e..1981c9243 100644 --- a/PixelComposer.yyp +++ b/PixelComposer.yyp @@ -161,6 +161,8 @@ {"resourceType":"GMFolder","resourceVersion":"1.0","name":"lua","folderPath":"folders/nodes/data/lua.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"misc","folderPath":"folders/nodes/data/misc.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"MK effects","folderPath":"folders/nodes/data/MK effects.yy",}, + {"resourceType":"GMFolder","resourceVersion":"1.0","name":"mk flare","folderPath":"folders/nodes/data/MK effects/mk flare.yy",}, + {"resourceType":"GMFolder","resourceVersion":"1.0","name":"src","folderPath":"folders/nodes/data/MK effects/mk flare/src.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"mk sparkle","folderPath":"folders/nodes/data/MK effects/mk sparkle.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"src","folderPath":"folders/nodes/data/MK effects/mk sparkle/src.yy",}, {"resourceType":"GMFolder","resourceVersion":"1.0","name":"PCX","folderPath":"folders/nodes/data/PCX.yy",}, @@ -577,6 +579,7 @@ {"id":{"name":"s_node_polar","path":"sprites/s_node_polar/s_node_polar.yy",},}, {"id":{"name":"complex_function","path":"scripts/complex_function/complex_function.yy",},}, {"id":{"name":"draw_set_blend_mode_ext","path":"scripts/draw_set_blend_mode_ext/draw_set_blend_mode_ext.yy",},}, + {"id":{"name":"s_flare_type","path":"sprites/s_flare_type/s_flare_type.yy",},}, {"id":{"name":"s_node_json_parse","path":"sprites/s_node_json_parse/s_node_json_parse.yy",},}, {"id":{"name":"s_node_noise_simplex","path":"sprites/s_node_noise_simplex/s_node_noise_simplex.yy",},}, {"id":{"name":"s_node_armature_sample","path":"sprites/s_node_armature_sample/s_node_armature_sample.yy",},}, @@ -1754,6 +1757,7 @@ {"id":{"name":"s_node_path_map","path":"sprites/s_node_path_map/s_node_path_map.yy",},}, {"id":{"name":"node_iterator_filter_inline_input","path":"scripts/node_iterator_filter_inline_input/node_iterator_filter_inline_input.yy",},}, {"id":{"name":"s_node_greyscale","path":"sprites/s_node_greyscale/s_node_greyscale.yy",},}, + {"id":{"name":"s_node_mk_flare","path":"sprites/s_node_mk_flare/s_node_mk_flare.yy",},}, {"id":{"name":"sh_dilate","path":"shaders/sh_dilate/sh_dilate.yy",},}, {"id":{"name":"node_image_sequence","path":"scripts/node_image_sequence/node_image_sequence.yy",},}, {"id":{"name":"node_text_file_read","path":"scripts/node_text_file_read/node_text_file_read.yy",},}, diff --git a/datafiles/data/Theme.zip b/datafiles/data/Theme.zip index 87a38cd87..e66aeb4ce 100644 Binary files a/datafiles/data/Theme.zip and b/datafiles/data/Theme.zip differ diff --git a/fonts/_f_sdf/_f_sdf.old.png b/fonts/_f_sdf/_f_sdf.old.png index 983f14b48..32d378127 100644 Binary files a/fonts/_f_sdf/_f_sdf.old.png and b/fonts/_f_sdf/_f_sdf.old.png differ diff --git a/fonts/_f_sdf/_f_sdf.png b/fonts/_f_sdf/_f_sdf.png index a38b54693..186ff45e2 100644 Binary files a/fonts/_f_sdf/_f_sdf.png and b/fonts/_f_sdf/_f_sdf.png differ diff --git a/fonts/_f_sdf_medium/_f_sdf_medium.old.png b/fonts/_f_sdf_medium/_f_sdf_medium.old.png index 7e3fd6800..dde5c4e09 100644 Binary files a/fonts/_f_sdf_medium/_f_sdf_medium.old.png and b/fonts/_f_sdf_medium/_f_sdf_medium.old.png differ diff --git a/fonts/_f_sdf_medium/_f_sdf_medium.png b/fonts/_f_sdf_medium/_f_sdf_medium.png index 4cf829f7e..fec50cddb 100644 Binary files a/fonts/_f_sdf_medium/_f_sdf_medium.png and b/fonts/_f_sdf_medium/_f_sdf_medium.png differ diff --git a/scripts/__VFX/__VFX.gml b/scripts/__VFX/__VFX.gml index bb69e8e03..629a9c019 100644 --- a/scripts/__VFX/__VFX.gml +++ b/scripts/__VFX/__VFX.gml @@ -289,9 +289,7 @@ function __part(_node) constructor { } else if(arr_type == 3) ss = array_safe_get(ss, _index); var surface = is_instanceof(ss, SurfaceAtlas)? ss.getSurface() : node.surface_cache[$ ss]; - - if(!is_surface(surface)) - return; + var _useS = is_surface(surface); var lifeRat = 1 - life / life_total; var scCurve = sct == noone? 1 : sct.get(lifeRat); @@ -299,8 +297,8 @@ function __part(_node) constructor { scy = drawsy * scCurve; var _xx, _yy; - var s_w = surface_get_width_safe(surface) * scx; - var s_h = surface_get_height_safe(surface) * scy; + var s_w = (_useS? surface_get_width(surface) : 1) * scx; + var s_h = (_useS? surface_get_height(surface) : 1) * scy; var _pp = point_rotate(-s_w / 2, -s_h / 2, 0, 0, rot); _xx = drawx + _pp[0]; @@ -324,14 +322,50 @@ function __part(_node) constructor { var x1 = _xx + s_w * 1.5; var y1 = _yy + s_h * 1.5; - if(x0 > surf_w || y0 > surf_h || x1 < 0 || y1 < 0) + if(_useS && (x0 > surf_w || y0 > surf_h || x1 < 0 || y1 < 0)) return; var cc = (col == -1)? c_white : col.eval(lifeRat); if(blend != c_white) cc = colorMultiply(blend, cc); alp_draw = alp * (alp_fade == noone? 1 : alp_fade.get(lifeRat)) * _color_get_alpha(cc); - draw_surface_ext_safe(surface, _xx, _yy, scx, scy, drawrot, cc, alp_draw); + if(_useS) draw_surface_ext(surface, _xx, _yy, scx, scy, drawrot, cc, alp_draw); + else { + if(round(ss) == 0) return; + + var _s = shader_current(); + shader_reset(); + + var ss = round(min(scx, scy)); + draw_set_color(cc); + draw_set_alpha(alp_draw); + + switch(round(ss)) { + case 0 : + case 1 : + draw_point(_xx, _yy); + break; + case 2 : + draw_point(_xx + 0, _yy + 0); + draw_point(_xx + 1, _yy + 0); + draw_point(_xx + 0, _yy + 1); + draw_point(_xx + 1, _yy + 1); + break; + case 3 : + draw_point(_xx - 1, _yy); + draw_point(_xx + 1, _yy); + draw_point(_xx, _yy + 1); + draw_point(_xx, _yy - 1); + break; + default : + draw_circle(round(_xx), round(_yy), round(ss) - 2, false); + break; + } + + draw_set_alpha(1); + + shader_set(_s); + } } #endregion static getPivot = function() { #region diff --git a/scripts/_draw_defines/_draw_defines.gml b/scripts/_draw_defines/_draw_defines.gml index 9824eac94..8418cdba5 100644 --- a/scripts/_draw_defines/_draw_defines.gml +++ b/scripts/_draw_defines/_draw_defines.gml @@ -6,6 +6,7 @@ #macro BLEND_NORMAL gpu_set_blendmode(bm_normal) #macro BLEND_ADD gpu_set_blendmode(bm_add) #macro BLEND_OVERRIDE gpu_set_blendmode_ext(bm_one, bm_zero) + //#macro BLEND_ADD_ALPHA gpu_set_blendmode_ext_sepalpha(bm_one, bm_inv_src_alpha, bm_one, bm_one) #macro BLEND_ALPHA gpu_set_blendmode_ext_sepalpha(bm_one, bm_inv_src_alpha, bm_one, bm_one) #macro BLEND_ALPHA_MULP gpu_set_blendmode_ext_sepalpha(bm_src_alpha, bm_inv_src_alpha, bm_one, bm_one) diff --git a/scripts/draw_circle_functions/draw_circle_functions.gml b/scripts/draw_circle_functions/draw_circle_functions.gml index 57dee654e..bb7a0fe3e 100644 --- a/scripts/draw_circle_functions/draw_circle_functions.gml +++ b/scripts/draw_circle_functions/draw_circle_functions.gml @@ -3,6 +3,19 @@ function draw_circle_prec(x, y, r, border, precision = 32) { #region draw_circle(x, y, r, border); } #endregion +function draw_polygon(x, y, r, sides, a = 0) { #region + draw_primitive_begin(pr_trianglelist); + for( var i = 0; i < sides; i++ ) { + var a0 = (i + 0) / sides * 360 + a; + var a1 = (i + 1) / sides * 360 + a; + + draw_vertex(x, y); + draw_vertex(x + lengthdir_x(r, a0), y + lengthdir_y(r, a0)); + draw_vertex(x + lengthdir_x(r, a1), y + lengthdir_y(r, a1)); + } + draw_primitive_end(); +} #endregion + function draw_circle_border(xx, yy, r, w) { #region var step = 32; var angle_step = 360 / step; diff --git a/scripts/draw_text_function/draw_text_function.gml b/scripts/draw_text_function/draw_text_function.gml index 52524bc84..0181f47b7 100644 --- a/scripts/draw_text_function/draw_text_function.gml +++ b/scripts/draw_text_function/draw_text_function.gml @@ -79,7 +79,7 @@ function draw_text_ext_add(_x, _y, _text, _sep, _w, scale = 1, forceCut = false) return h; } #endregion -function draw_text_bbox(bbox, text) { #region +function draw_text_bbox(bbox, text, scale = 1) { #region INLINE var ss = min(bbox.w / string_width(text), bbox.h / string_height(text)); ss = max(0.5, ss); @@ -87,7 +87,7 @@ function draw_text_bbox(bbox, text) { #region draw_set_halign(fa_center); draw_set_valign(fa_center); - draw_text_cut(bbox.xc, bbox.yc, text, bbox.w, ss); + draw_text_cut(bbox.xc, bbox.yc, text, bbox.w, ss * scale); } #endregion function draw_text_cut(x, y, str, w, scale = 1) { #region diff --git a/scripts/node_VFX_renderer/node_VFX_renderer.gml b/scripts/node_VFX_renderer/node_VFX_renderer.gml index 118c5b9e3..55e85ab7c 100644 --- a/scripts/node_VFX_renderer/node_VFX_renderer.gml +++ b/scripts/node_VFX_renderer/node_VFX_renderer.gml @@ -121,6 +121,7 @@ function Node_VFX_Renderer(_x, _y, _group = noone) : Node(_x, _y, _group) constr for(var k = 0; k < array_length(parts[j]); k++) { if(!parts[j][k].active) continue; parts[j][k].draw(_exact, surf_w, surf_h); + //if(shader_current() != sh_sample) __shader_set = false; } } diff --git a/scripts/node_midi_in/node_midi_in.gml b/scripts/node_midi_in/node_midi_in.gml index 0008c9c1d..60c7f029d 100644 --- a/scripts/node_midi_in/node_midi_in.gml +++ b/scripts/node_midi_in/node_midi_in.gml @@ -19,17 +19,106 @@ function Node_MIDI_In(_x, _y, _group = noone) : Node(_x, _y, _group) constructor inputs[| 0] = nodeValue("Input", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0) .setDisplay(VALUE_DISPLAY.enum_scroll, { data: _miniNames, update_hover: false }) .rejectArray(); - + outputs[| 0] = nodeValue("Raw Message", self, JUNCTION_CONNECT.output, VALUE_TYPE.float, []); outputs[| 1] = nodeValue("Pressing notes", self, JUNCTION_CONNECT.output, VALUE_TYPE.float, []); - outputs[| 2] = nodeValue("Note velocity", self, JUNCTION_CONNECT.output, VALUE_TYPE.struct, {}); + outputs[| 2] = nodeValue("Direct values", self, JUNCTION_CONNECT.output, VALUE_TYPE.struct, {}); - outputs[| 3] = nodeValue("Direct values", self, JUNCTION_CONNECT.output, VALUE_TYPE.struct, {}); + watcher_controllers = new Inspector_Custom_Renderer(function(_x, _y, _w, _m, _hover, _focus) { #region + var _h = ui(48); + + var bw = _w / 2 - ui(4); + var bh = ui(36); + var bx = _x; + var by = _y + ui(8); + if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, _focus, _hover) == 2) { + createNewInput(); + } + + draw_set_text(f_p1, fa_left, fa_center, COLORS._main_icon_light); + var bxc = bx + bw / 2 - (string_width("Add") + ui(64)) / 2; + var byc = by + bh / 2; + draw_sprite_ui(THEME.add, 0, bxc + ui(24), byc,,,, COLORS._main_icon_light); + draw_text(bxc + ui(48), byc, __txt("Add")); + + var bx = _x + bw + ui(8); + var amo = ds_list_size(inputs); + if(amo > 1 && buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, _focus, _hover) == 2) { + var _out = outputs[| ds_list_size(outputs) - 1]; + for( var i = 0, n = array_length(_out.value_to); i < n; i++ ) + _out.value_to[i].removeFrom(); + + array_remove(input_display_list, ds_list_size(inputs) - 1); + ds_list_delete(inputs, ds_list_size(inputs) - 1); + ds_list_delete(outputs, ds_list_size(outputs) - 1); + } + + draw_set_text(f_p1, fa_left, fa_center, COLORS._main_icon_light); + var bxc = bx + bw / 2 - (string_width("Remove") + ui(64)) / 2; + var byc = by + bh / 2; + draw_sprite_ui(THEME.minus, 0, bxc + ui(24), byc,,,, COLORS._main_icon_light, (amo > 1) * 0.5 + 0.5); + draw_set_alpha((amo > 1) * 0.5 + 0.5); + draw_text(bxc + ui(48), byc, __txt("Remove")); + draw_set_alpha(1); + + var _wx = TEXTBOX_HEIGHT + ui(16); + var _wy = by + bh + ui(8); + var _ww = _w - _wx; + var _wh = TEXTBOX_HEIGHT; + + for( var i = input_fix_len, n = ds_list_size(inputs); i < n; i++ ) { + var jun = inputs[| i]; + var _name = jun.getName(); + var wid = jun.editWidget; + var _show = jun.showValue(); + + var bs = TEXTBOX_HEIGHT; + var bx = _x; + var by = _wy; + if(buttonInstant(THEME.button_hide, bx, by, bs, bs, _m, _focus, _hover) == 2) + index_watching = index_watching == i? noone : i; + var cc = index_watching == i? COLORS._main_value_negative : COLORS._main_icon; + draw_sprite_ext(THEME.circle_16, 0, bx + bs / 2, by + bs / 2, 1, 1, 0, cc, 1); + + var param = new widgetParam(_wx, _wy, _ww, _wh, _show, jun.display_data, _m); + wid.setFocusHover(_focus, _hover); + + var hh = wid.drawParam(param) + ui(8); + + if(index_watching == i) { + draw_set_text(f_p1, fa_left, fa_center, COLORS._main_value_negative); + draw_text(_wx + ui(6), _wy + _wh / 2 + ui(2), "Waiting for MIDI input..."); + } + + _h += hh; + _wy += hh; + } + + return _h; + }); #endregion + + input_display_list = [ 0, + ["Watchers", false], watcher_controllers, + ]; + + setIsDynamicInput(1); + + static createNewInput = function() { #region + index_watching = ds_list_size(inputs); + + var _inp = nodeValue("Index", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, -1 ); + ds_list_add(inputs, _inp); + ds_list_add(outputs, nodeValue("Value", self, JUNCTION_CONNECT.output, VALUE_TYPE.integer, -1 )); + + _inp.editWidget.slidable = false; + } #endregion + + index_watching = noone; + disp_value = 0; notesPressing = []; - notesVelocity = {}; values = {}; attributes.live_update = true; @@ -57,29 +146,32 @@ function Node_MIDI_In(_x, _y, _group = noone) : Node(_x, _y, _group) constructor if(array_length(a) >= 3) { var _typ = a[0]; - + var vkey = a[1]; + var vval = a[2]; + if (_typ <= 159) { - var vnote = a[1]; - var velo = a[2]; - - if (_typ <= 143) array_remove(notesPressing, vnote); //note off - else array_push_unique(notesPressing, vnote); //note on - - notesVelocity[$ vnote] = velo; - } else if (_typ == 176) { - var vkey = a[1]; - var vval = a[2]; - - values[$ vkey] = vval; + if (_typ <= 143) array_remove(notesPressing, vkey); //note off + else array_push_unique(notesPressing, vkey); //note on + } + + values[$ vkey] = vval; + disp_value = vval; + + if(index_watching != noone) { + inputs[| index_watching].setValue(vkey); + index_watching = noone; } } - if(b) print(a); - outputs[| 0].setValue(a); outputs[| 1].setValue(notesPressing); - outputs[| 2].setValue(notesVelocity); - outputs[| 3].setValue(values); + outputs[| 2].setValue(values); + + for( var i = input_fix_len, n = ds_list_size(inputs); i < n; i++ ) { + var _ikey = inputs[| i].getValue(); + outputs[| i + 2].setName($"{_ikey} Value"); + outputs[| i + 2].setValue(struct_try_get(values, _ikey, 0)); + } } #endregion @@ -87,7 +179,21 @@ function Node_MIDI_In(_x, _y, _group = noone) : Node(_x, _y, _group) constructor static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) { #region var bbox = drawGetBbox(xx, yy, _s); - draw_sprite_fit(s_midi, 0, bbox.xc, bbox.yc, bbox.w, bbox.h); - draw_sprite_fit(s_midi, 1, bbox.xc, bbox.yc, bbox.w, bbox.h, array_empty(notesPressing)? c_white : COLORS._main_accent); + var bx = bbox.xc; + var by = bbox.y0 + bbox.h * 0.55; + + draw_sprite_fit(s_midi, 0, bx, by, bbox.w, bbox.h * 0.75); + draw_sprite_fit(s_midi, 1, bx, by, bbox.w, bbox.h * 0.75, array_empty(notesPressing)? c_white : COLORS._main_accent); + + draw_set_text(f_sdf, fa_center, fa_center, c_white); + var text = string(disp_value); + + var ss = max(0.5, _s) * 0.5; + by = bbox.y0 + bbox.h * 0.25 / 2; + + draw_set_halign(fa_center); + draw_set_valign(fa_center); + + draw_text_cut(bx, by, text, bbox.w, ss); } #endregion } \ No newline at end of file diff --git a/scripts/node_mk_brownian/node_mk_brownian.gml b/scripts/node_mk_brownian/node_mk_brownian.gml index 0ad73edf8..babac950d 100644 --- a/scripts/node_mk_brownian/node_mk_brownian.gml +++ b/scripts/node_mk_brownian/node_mk_brownian.gml @@ -34,6 +34,9 @@ function Node_MK_Brownian(_x, _y, _group = noone) : Node(_x, _y, _group) constru inputs[| 12] = nodeValue("Dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, DEF_SURF) .setDisplay(VALUE_DISPLAY.vector); + inputs[| 13] = nodeValue("Size", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ]) + .setDisplay(VALUE_DISPLAY.range, { linked : true }); + outputs[| 0] = nodeValue("Output", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone); input_display_list = [ new Inspector_Sprite(s_MKFX), 8, @@ -42,7 +45,7 @@ function Node_MK_Brownian(_x, _y, _group = noone) : Node(_x, _y, _group) constru ["Spawn", false], 3, 2, ["Movement", false], 5, 4, 9, ["Smooth turn", true, 11], 10, - ["Render", false], 6, 7, + ["Render", false], 13, 6, 7, ]; static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { @@ -91,6 +94,7 @@ function Node_MK_Brownian(_x, _y, _group = noone) : Node(_x, _y, _group) constru var _dira = getInputData(10); var _turn = getInputData(11); var _dim = getInputData(12); + var _size = getInputData(13); var _sed = _seed; @@ -107,6 +111,7 @@ function Node_MK_Brownian(_x, _y, _group = noone) : Node(_x, _y, _group) constru draw_surface_safe(_surf); BLEND_ALPHA_MULP + shader_set(sh_draw_divide); for( var i = 0; i < _amou; i++ ) { _sed += 100; @@ -117,18 +122,45 @@ function Node_MK_Brownian(_x, _y, _group = noone) : Node(_x, _y, _group) constru var _cc = _colr.eval(_lifs / TOTAL_FRAMES); var _aa = eval_curve_x(_alph, _lif / TOTAL_FRAMES); + random_set_seed(_sed + 50); + var _ss = random_range(_size[0], _size[1]); + if(_sprt == noone) { draw_set_color(_cc); draw_set_alpha(_aa); - draw_point(_pos[0], _pos[1]); + + switch(round(_ss)) { + case 0 : + case 1 : + draw_point(_pos[0], _pos[1]); + break; + case 2 : + draw_point(_pos[0], _pos[1]); + draw_point(_pos[0] + 1, _pos[1]); + draw_point(_pos[0], _pos[1] + 1); + draw_point(_pos[0] + 1, _pos[1] + 1); + break; + case 3 : + draw_point(_pos[0] - 1, _pos[1]); + draw_point(_pos[0] + 1, _pos[1]); + draw_point(_pos[0], _pos[1] + 1); + draw_point(_pos[0], _pos[1] - 1); + break; + default : + draw_circle(round(_pos[0]), round(_pos[1]), round(_ss) - 2, false); + break; + } + draw_set_alpha(1); } else { var _p = _sprt; if(is_array(_p)) _p = array_safe_get(_p, irandom(array_length(_p) - 1)); - draw_surface_ext_safe(_p, _pos[0], _pos[1], 1, 1, 0, _cc, _aa); + draw_surface_ext_safe(_p, _pos[0], _pos[1], _ss, _ss, 0, _cc, _aa); } } + shader_reset(); + BLEND_NORMAL surface_reset_target(); } #endregion diff --git a/scripts/node_mk_falls/node_mk_falls.gml b/scripts/node_mk_falls/node_mk_falls.gml index 92536558e..55ea7370e 100644 --- a/scripts/node_mk_falls/node_mk_falls.gml +++ b/scripts/node_mk_falls/node_mk_falls.gml @@ -234,7 +234,7 @@ function Node_MK_Fall(_x, _y, _group = noone) : Node(_x, _y, _group) constructor BLEND_OVERRIDE draw_surface_safe(_surf); - BLEND_NORMAL + BLEND_ALPHA_MULP shader_set(sh_draw_divide); for( var i = 0; i < _amou; i++ ) { @@ -287,6 +287,7 @@ function Node_MK_Fall(_x, _y, _group = noone) : Node(_x, _y, _group) constructor draw_set_alpha(1); } shader_reset(); + BLEND_NORMAL surface_reset_target(); } #endregion diff --git a/scripts/node_mk_flare/node_mk_flare.gml b/scripts/node_mk_flare/node_mk_flare.gml index 1f9b55043..4b5c600c3 100644 --- a/scripts/node_mk_flare/node_mk_flare.gml +++ b/scripts/node_mk_flare/node_mk_flare.gml @@ -1,48 +1,348 @@ +enum FLARE_TYPE { + circle, + ring, + star, + line, + + size +} + +function __FlarePart(_type = FLARE_TYPE.circle, _t = 0, _r = 4, _a = 0.5, _seg = 16, _seg_s = false, _blend = c_white, _shade = [ 0, 1 ], _ir = 1, _ratio = 1, _th = [ 1, 0 ]) constructor { + type = _type + t = _t + r = _r + a = _a + seg = _seg + seg_s = _seg_s + blend = _blend + shade = _shade + ir = _ir + ratio = _ratio + th = _th +} + function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) constructor { name = "MK Lens Flare"; - dimension_index = 3; inputs[| 0] = nodeValue("Background", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, noone); - inputs[| 1] = nodeValue("Origin", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ DEF_SURF_W / 2, 0 ]) - .setDisplay(VALUE_DISPLAY.vector); + inputs[| 1] = nodeValue("Origin", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0 ]) + .setDisplay(VALUE_DISPLAY.vector) + .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); - inputs[| 2] = nodeValue("Type", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0) - .setDisplay(VALUE_DISPLAY.enum_scroll, [ "Lens", "Crescent" ]); - - inputs[| 3] = nodeValue("Dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, DEF_SURF) + inputs[| 2] = nodeValue("Dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, DEF_SURF) .setDisplay(VALUE_DISPLAY.vector); - inputs[| 4] = nodeValue("Scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1) + inputs[| 3] = nodeValue("Scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1) - inputs[| 5] = nodeValue("Alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1) + inputs[| 4] = nodeValue("Alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1) .setDisplay(VALUE_DISPLAY.slider); + inputs[| 5] = nodeValue("Flares", self, JUNCTION_CONNECT.input, VALUE_TYPE.struct, [ + new __FlarePart( FLARE_TYPE.circle, 0, 8, 0.75, 16, false, , [ 0, 1 ] ), + new __FlarePart( FLARE_TYPE.circle, 0, 16, 0.5, 16, false, , [ 0, 1 ] ), + new __FlarePart( FLARE_TYPE.star, 0, 14, 0.3, 8, true, , [ 0.2, 0.8 ], 2, 0.85 ), + new __FlarePart( FLARE_TYPE.ring, 0, 6, 0.25, 16, false, , [ 0, 0.5 ],,, [ 1, 0.1 ] ), + + new __FlarePart( FLARE_TYPE.circle, 0.7, 2, 0.6, 16, false, , [ 0, 0.25 ] ), + new __FlarePart( FLARE_TYPE.circle, 0.9, 2, 0.6, 6, false, , [ 0, 0.50 ] ), + new __FlarePart( FLARE_TYPE.circle, 1.2, 0.5, 0.5, 4, false, , [ 0, 0.00 ] ), + + new __FlarePart( FLARE_TYPE.circle, 1.5, 5, 0.6, 16, false, , [ 0, 0.7 ] ), + new __FlarePart( FLARE_TYPE.circle, 1.6, 3, 0.4, 6, false, , [ 0, 0. ] ), + new __FlarePart( FLARE_TYPE.ring, 1.9, 4, 0.5, 16, false, , [ 0, 0. ],,, [ 1, 0 ] ), + new __FlarePart( FLARE_TYPE.circle, 1.9, 3, 0.5, 16, false, , [ 0, 0.5 ] ), + ]) + .setArrayDepth(1) + .setArrayDynamic(); + + inputs[| 6] = nodeValue("Focus", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ]) + .setDisplay(VALUE_DISPLAY.vector) + .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); + outputs[| 0] = nodeValue("Surface out", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone); outputs[| 1] = nodeValue("Light only", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone); + static __frame = function(_x, _y, _w, _h, _m, _hover) { + var _hv = point_in_rectangle(_m[0], _m[1], _x, _y, _x + _w, _y + _h) && _hover; + + draw_sprite_stretched_ext(THEME.timeline_node, 0, _x, _y, _w, _h, _hv? CDEF.main_black : CDEF.main_mdblack, 1); + draw_sprite_stretched_ext(THEME.timeline_node, 1, _x, _y, _w, _h, CDEF.main_dkgrey, 1); + + return _hv; + } + + flare_editing = noone; + flare_editing_prop = ""; + flare_editing_mx = 0; + flare_editing_my = 0; + flare_editing_sx = 0; + flare_editing_sy = 0; + + flare_color_editing = -1; + + flare_draw_x = 0; + flare_draw_y = 0; + + function edit_flare_color(color) { + var _flares = inputs[| 5].getValue(); + _flares[flare_color_editing].blend = color; + triggerRender(); + } + + flare_builder = new Inspector_Custom_Renderer(function(_x, _y, _w, _m, _hover, _focus) { #region + var _flares = inputs[| 5].getValue(); + var _amo = array_length(_flares); + + //print($"{_flares}: {_amo}"); + + var _fx = _x; + var _fy = _y + ui(8); + var _fh = ui(32); + var _h = (_amo + 1) * (_fh + ui(4)); + + var _ffh = _fh - ui(8); + + draw_set_text(f_p2, fa_center, fa_center, COLORS._main_text); + + if(flare_editing != noone) { + var _flare = _flares[flare_editing]; + + switch(flare_editing_prop) { + case "type" : + _flare.a = clamp(flare_editing_sx + (_m[0] - flare_editing_mx) / 64, 0, 1); + _flare.type = clamp(floor((_m[1] - flare_editing_my) / _ffh), 0, FLARE_TYPE.size - 1); + + if(_flare.type == FLARE_TYPE.ring || _flare.type == FLARE_TYPE.line) + if(!struct_has(_flare, "th")) _flare.th = [ 1, 0 ]; + else if(_flare.type == FLARE_TYPE.star) { + if(!struct_has(_flare, "ir")) _flare.ir = 1; + if(!struct_has(_flare, "ratio")) _flare.ratio = 1; + } + break; + case "t" : _flare.t = flare_editing_sx + (_m[0] - flare_editing_mx) / 64; if(abs(_flare.t - round(_flare.t * 10) / 10) < 0.02) _flare.t = round(_flare.t * 10) / 10; break; + case "r" : _flare.r = flare_editing_sx + (_m[0] - flare_editing_mx) / 64; if(abs(_flare.r - round(_flare.r)) < 0.2) _flare.r = round(_flare.r); break; + case "seg" : _flare.seg = round(flare_editing_sx + (_m[0] - flare_editing_mx) / 32); break; + case "r0" : _flare.shade[0] = clamp(flare_editing_sx + (_m[0] - flare_editing_mx) / 64, 0, 1); if(abs(_flare.shade[0] - round(_flare.shade[0] * 10) / 10) < 0.02) _flare.shade[0] = round(_flare.shade[0] * 10) / 10; break; + case "r1" : _flare.shade[1] = clamp(flare_editing_sx + (_m[0] - flare_editing_mx) / 64, 0, 1); if(abs(_flare.shade[1] - round(_flare.shade[1] * 10) / 10) < 0.02) _flare.shade[1] = round(_flare.shade[1] * 10) / 10; break; + case "th0" : _flare.th[0] = flare_editing_sx + (_m[0] - flare_editing_mx) / 64; if(abs(_flare.th[0] - round(_flare.th[0])) < 0.2) _flare.th[0] = round(_flare.th[0]); break; + case "th1" : _flare.th[1] = flare_editing_sx + (_m[0] - flare_editing_mx) / 64; if(abs(_flare.th[1] - round(_flare.th[1])) < 0.2) _flare.th[1] = round(_flare.th[1]); break; + case "ir" : _flare.ir = flare_editing_sx + (_m[0] - flare_editing_mx) / 64; if(abs(_flare.ir - round(_flare.ir )) < 0.2) _flare.ir = round(_flare.ir ); break; + } + + CURSOR = cr_size_we; + triggerRender(); + + if(mouse_release(mb_left)) + flare_editing = noone; + } + + for( var i = 0; i < _amo; i++ ) { + var _flare = _flares[i]; + var _ffx = _fx + ui(4); + var _ffy = _fy + ui(4); + var _ffw = _ffh; + + draw_sprite_stretched_ext(THEME.timeline_node, 0, _fx, _fy, _w, _fh, CDEF.main_dkblack, 1); + + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_sprite_stretched_ext(THEME.timeline_node, 0, _ffx, _ffy, _ffw * _flare.a, _ffh, CDEF.main_dkgrey, 1); + draw_sprite_ext(s_flare_type, _flare.type, _ffx + _ffh / 2, _ffy + _ffh / 2, 1, 1, 0, c_white, 1); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = "type"; + flare_editing_mx = _m[0]; + flare_editing_my = _ffy - _flare.type * _ffh; + flare_editing_sx = _flare.a; + flare_editing_sy = _flare.type; + + flare_draw_x = _ffx; + flare_draw_y = _ffy - _flare.type * _ffh; + } + _ffx += _ffw + ui(4); + + _ffw = ui(16); + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_sprite_stretched_ext(THEME.palette_mask, 1, _ffx + ui(4), _ffy + ui(4), _ffw - ui(8), _ffh - ui(8), _flare.blend, 1); + if(_hov && mouse_press(mb_left, _focus)) { + flare_color_editing = i; + + var dialog = dialogCall(o_dialog_color_selector, WIN_W / 2, WIN_H / 2); + dialog.selector.onApply = edit_flare_color; + dialog.onApply = edit_flare_color; + dialog.setDefault(_flare.blend); + } + _ffx += _ffw + ui(4); + + _ffw = ui(40); + + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_sprite_stretched_ext(THEME.timeline_node, 0, _ffx, _ffy, _ffw * clamp(_flare.t, 0., 2.) / 2, _ffh, CDEF.main_dkgrey, 1); + draw_text(_ffx + _ffw / 2, _ffy + _ffh / 2, string(_flare.t)); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = "t"; + flare_editing_mx = _m[0]; + flare_editing_sx = _flare.t; + } + _ffx += _ffw + ui(4); + + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_text(_ffx + _ffw / 2, _ffy + _ffh / 2, string(_flare.r)); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = "r"; + flare_editing_mx = _m[0]; + flare_editing_sx = _flare.r; + } + _ffx += _ffw + ui(4); + + _ffw = _ffh; + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_set_color(CDEF.main_dkgrey); + draw_polygon(_ffx + _ffw / 2, _ffy + _ffh / 2, _ffh / 2 - ui(2), _flare.seg); + + draw_set_color(COLORS._main_text); + draw_text(_ffx + _ffw / 2, _ffy + _ffh / 2, string(_flare.seg)); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = "seg"; + flare_editing_mx = _m[0]; + flare_editing_sx = _flare.seg; + } + _ffx += _ffw + ui(4); + + _ffw = ui(80); + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_sprite_stretched_ext(THEME.timeline_node, 0, _ffx + _ffw * _flare.shade[0], _ffy, _ffw * (_flare.shade[1] - _flare.shade[0]), _ffh, CDEF.main_dkgrey, 1); + draw_text(_ffx + _ffw / 4, _ffy + _ffh / 2, string(_flare.shade[0])); + draw_text(_ffx + _ffw / 4 * 3, _ffy + _ffh / 2, string(_flare.shade[1])); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = _m[0] < _ffx + _ffw / 2? "r0" : "r1"; + flare_editing_mx = _m[0]; + flare_editing_sx = _m[0] < _ffx + _ffw / 2? _flare.shade[0] : _flare.shade[1]; + } + _ffx += _ffw + ui(4); + + switch(_flare.type) { + case FLARE_TYPE.ring : + case FLARE_TYPE.line : + _ffw = ui(80); + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_text(_ffx + _ffw / 4, _ffy + _ffh / 2, string(_flare.th[0])); + draw_text(_ffx + _ffw / 4 * 3, _ffy + _ffh / 2, string(_flare.th[1])); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = _m[0] < _ffx + _ffw / 2? "th0" : "th1"; + flare_editing_mx = _m[0]; + flare_editing_sx = _m[0] < _ffx + _ffw / 2? _flare.th[0] : _flare.th[1]; + } + _ffx += _ffw + ui(4); + break; + + case FLARE_TYPE.star : + _ffw = ui(40); + var _hov = __frame(_ffx, _ffy, _ffw, _ffh, _m, _hover); + draw_text(_ffx + _ffw / 2, _ffy + _ffh / 2, string(_flare.ir)); + if(_hov && mouse_press(mb_left, _focus)) { + flare_editing = i; + flare_editing_prop = "ir"; + flare_editing_mx = _m[0]; + flare_editing_sx = _flare.ir; + } + _ffx += _ffw + ui(4); + break; + } + + _fy += _fh + ui(4); + } + + var bx = _fx; + var by = _fy; + var bs = ui(24); + + if(buttonInstant(THEME.button_hide, bx, by, bs, bs, _m, _focus, _hover, "", THEME.add_16, 0, COLORS._main_value_positive) == 2) { + array_push(_flares, new __FlarePart()); + inputs[| 5].setValue(_flares); + triggerRender(); + } + + bx += bs + ui(8); + + if(buttonInstant(THEME.button_hide, bx, by, bs, bs, _m, _focus, _hover, "", THEME.minus_16, 0, COLORS._main_value_negative) == 2) { + array_delete(_flares, array_length(_flares) - 1, 1); + inputs[| 5].setValue(_flares); + triggerRender(); + } + + if(flare_editing != noone && flare_editing_prop == "type") { + var _fdx = flare_draw_x; + var _fdy = flare_draw_y; + + var _fdw = _fh - ui(8); + var _fdh = _fdw * FLARE_TYPE.size; + + draw_sprite_stretched_ext(THEME.timeline_node, 0, _fdx, _fdy, _fdw, _fdh, CDEF.main_mdblack, 1); + draw_sprite_stretched_ext(THEME.timeline_node, 1, _fdx, _fdy, _fdw, _fdh, CDEF.main_dkgrey, 1); + + var _flare = _flares[flare_editing]; + + for( var i = 0; i < FLARE_TYPE.size; i++ ) { + var _ddx = _fdx; + var _ddy = _fdy + _fdw * i; + + if(i == _flare.type) + draw_sprite_stretched_ext(THEME.timeline_node, 0, _ddx, _ddy, _fdw, _fdw, CDEF.main_dkgrey, 1); + draw_sprite_ext(s_flare_type, i, _ddx + _fdw / 2, _ddy + _fdw / 2, 1, 1, 0, i == _flare.type? c_white : COLORS._main_icon, 1); + } + } + + return _h; + }); #endregion + input_display_list = [ new Inspector_Sprite(s_MKFX), - ["Surfaces", false], 0, 3, - ["Flare", false], 2, 1, 4, - ["Render", false], 5, + ["Surfaces", false], 0, 2, + ["Positions", false], 1, 6, + ["Flare", false], flare_builder, + ["Render", false], 3, 4, ] temp_surface = [ surface_create(1, 1) ]; - seed = seed_random(); + seed = seed_random(); flares = []; + setIsDynamicInput(1); + + static createNewInput = function() { #region + ds_list_add(inputs, nodeValue("Index", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [] ).setArrayDepth(1)); + } #endregion + ox = 0; oy = 0; cx = 0 cy = 0 + dir = 0; + dis = 0; + static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region inputs[| 1].drawOverlay(active, _x, _y, _s, _mx, _my, _snx, _sny); + inputs[| 6].drawOverlay(active, _x, _y, _s, _mx, _my, _snx, _sny); } #endregion - static flare_circle = function(_t, _r, _a, _side = 16, _angle = 0, _s0 = 0, _s1 = 0) { #region + static getDimension = function(arr = 0) { #region + var _sr = getSingleValue(0, arr); + var _dm = getSingleValue(2, arr); + + if(is_surface(_sr)) + return surface_get_dimension(_sr); + return _dm; + } #endregion + + static flare_circle = function(_t, _r, _a, _side = 16, _angle = 0, _s0 = 0, _s1 = 0, _b = c_white) { #region var _x = lerp(ox, cx, _t); var _y = lerp(oy, cy, _t); @@ -64,21 +364,19 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) draw_primitive_end(); surface_reset_shader(); - BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, c_white, _a); + BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, _b, _a); } #endregion - static flare_crescent = function(_t, _ir, _or, _a, _dist = 0, _angle = 0, _s0 = 0, _s1 = 0) { #region + static flare_crescent = function(_t, _r, _a, _side = 16, _angle = 0, _s0 = 0, _s1 = 0, _b = c_white, _ir = 0, _dist = 0) { #region var _x = lerp(ox, cx, _t); var _y = lerp(oy, cy, _t); - var _r = _or; - temp_surface[0] = surface_verify(temp_surface[0], _r * 2, _r * 2); surface_set_shader(temp_surface[0], sh_draw_grey_alpha); shader_set_f("smooth", _s0, _s1); - draw_circle_color(_r, _r, _or, c_white, c_black, false); + draw_circle_color(_r, _r, _r, c_white, c_black, false); var _rx = _r + lengthdir_x(_dist, _angle); var _ry = _r + lengthdir_y(_dist, _angle); @@ -88,31 +386,15 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) BLEND_NORMAL surface_reset_shader(); - BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, c_white, _a); + BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, _b, _a); } #endregion - static flare_blur = function(_t, _r, _a, _s0 = 0, _s1 = 1) { #region + static flare_ring = function(_t, _r, _a, _side = 16, _angle = 0, _s0 = 0, _s1 = 0, _b = c_white, _th = 1) { #region var _x = lerp(ox, cx, _t); var _y = lerp(oy, cy, _t); temp_surface[0] = surface_verify(temp_surface[0], _r * 2, _r * 2); - surface_set_shader(temp_surface[0], sh_draw_grey_alpha); - shader_set_f("smooth", _s0, _s1); - - draw_circle_color(_r - 1, _r - 1, _r, c_white, c_black, false); - surface_reset_shader(); - - BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, c_white, _a); - } #endregion - - static flare_ring = function(_t, _r, _a, _th, _s0 = 0, _s1 = 0) { #region - var _x = lerp(ox, cx, _t); - var _y = lerp(oy, cy, _t); - - temp_surface[0] = surface_verify(temp_surface[0], _r * 2, _r * 2); - - var _side = 32; var _r0 = _r - _th; var _r1 = _r - _th / 2; var _r2 = _r; @@ -122,8 +404,8 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) draw_primitive_begin(pr_trianglelist); for( var i = 0; i < _side; i++ ) { - var a0 = ((i + 0.0) / _side) * 360; - var a1 = ((i + 1.0) / _side) * 360; + var a0 = ((i + 0.0) / _side) * 360 + _angle; + var a1 = ((i + 1.0) / _side) * 360 + _angle; draw_vertex_color(_r + lengthdir_x(_r1, a0), _r + lengthdir_y(_r1, a0), c_white, 1); draw_vertex_color(_r + lengthdir_x(_r0, a0), _r + lengthdir_y(_r0, a0), c_black, 1); @@ -145,42 +427,43 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) draw_primitive_end(); surface_reset_shader(); - BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, c_white, _a); + BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, _b, _a); } #endregion - - static flare_star = function(_t, _ir, _or, _a, _amo, _rand = 1., _ang = 0) { #region + + static flare_star = function(_t, _r, _a, _side = 16, _angle = 0, _s0 = 0, _s1 = 1, _b = c_white, _ir = 0, _rt = 1) { #region var _x = lerp(ox, cx, _t); var _y = lerp(oy, cy, _t); - temp_surface[0] = surface_verify(temp_surface[0], _or * 2, _or * 2); + temp_surface[0] = surface_verify(temp_surface[0], _r * 2, _r * 2); - var cc = _or; + var cc = _r; surface_set_shader(temp_surface[0], sh_draw_grey_alpha); draw_primitive_begin(pr_trianglelist); + shader_set_f("smooth", _s0, _s1); random_set_seed(seed); - for( var i = 0; i < _amo; i++ ) { - var a0 = ((i + 0.0) / _amo) * 360 + _ang; - var a1 = ((i + random_range(0., 1.)) / _amo) * 360 + _ang; - var a2 = ((i + 1.0) / _amo) * 360 + _ang; + for( var i = 0; i < _side; i++ ) { + var a0 = ((i + 0.0) / _side) * 360 + _angle; + var a1 = ((i + random_range(0., 1.)) / _side) * 360 + _angle; + var a2 = ((i + 1.0) / _side) * 360 + _angle; draw_vertex_color(cc, cc, c_white, 1); draw_vertex_color(cc + lengthdir_x(_ir, a0), cc + lengthdir_y(_ir, a0), c_grey, 1); - draw_vertex_color(cc + lengthdir_x(_or, a1), cc + lengthdir_y(_or, a1), c_black, 1); + draw_vertex_color(cc + lengthdir_x(_r , a1), cc + lengthdir_y(_r , a1), c_black, 1); draw_vertex_color(cc, cc, c_white, 1); - draw_vertex_color(cc + lengthdir_x(_or, a1), cc + lengthdir_y(_or, a1), c_black, 1); + draw_vertex_color(cc + lengthdir_x(_r , a1), cc + lengthdir_y(_r , a1), c_black, 1); draw_vertex_color(cc + lengthdir_x(_ir, a2), cc + lengthdir_y(_ir, a2), c_grey, 1); } draw_primitive_end(); surface_reset_shader(); - BLEND_ADD draw_surface_ext(temp_surface[0], _x - _or, _y - _or, 1, 1, 0, c_white, _a); + BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, _b, _a); } #endregion - - static flare_line = function(_r, _a, _th, _dir) { #region + + static flare_line = function(_r, _a, _th, _dir, _b = c_white) { #region var _x = cx; var _y = cy; @@ -219,26 +502,25 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) draw_primitive_end(); surface_reset_shader(); - BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, c_white, _a); + BLEND_ADD draw_surface_ext(temp_surface[0], _x - _r, _y - _r, 1, 1, 0, _b, _a); } #endregion - static processData = function(_outSurf, _data, _output_index, _array_index) { + static processData = function(_outSurf, _data, _output_index, _array_index) { #region if(_output_index == 1) return flares[_array_index]; var _surf = _data[0]; var _origin = _data[1]; - var _type = _data[2]; - var _dim = _data[3]; - var _s = _data[4]; - var _a = _data[5]; + var _dim = _data[2]; + var _sca = _data[3]; + var _alp = _data[4]; + var _flares = _data[5]; + var _focus = _data[6]; var _bg = is_surface(_surf); var _sw = _bg? surface_get_width_safe(_surf) : _dim[0]; var _sh = _bg? surface_get_height_safe(_surf) : _dim[1]; - var _focus = [ _sw / 2, _sh / 2 ]; - _outSurf = surface_verify(_outSurf, _sw, _sh); flares[_array_index] = surface_verify(array_safe_get(flares, _array_index), _sw, _sh); @@ -247,40 +529,45 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cx = _focus[0]; cy = _focus[1]; - var _dir = point_direction(cx, cy, ox, oy); - var _dis = point_distance(cx, cy, ox, oy); + dir = point_direction(cx, cy, ox, oy); + dis = point_distance(cx, cy, ox, oy); var _x, _y; surface_set_target(flares[_array_index]); - draw_clear_alpha(c_white, 0); + draw_clear_alpha(c_black, 0); - switch(_type) { - case 0 : - flare_blur( 0, 10 * _s, 0.75 * _a); - flare_blur( 0, 16 * _s, 0.5 * _a); - flare_star( 0, 3 * _s, 16 * _s, 0.4 * _a, min(24, 12 * _s), 0.85, _dir); - flare_ring( 0, 6 * _s, 0.25 * _a, 1 + 0.25 * _s, 0, 0.5); + for( var i = 0, n = array_length(_flares); i < n; i++ ) { + var _flare = _flares[i]; + + var _t = _flare.t; + var _r = _flare.r; _r = is_array(_r)? _r[0] + _r[1] * _sca : _r * _sca; + var _a = _flare.a; _a = _a * _alp; + var _g = _flare.seg_s? _flare.seg * _sca : _flare.seg; + var _h = _flare.shade; + var _b = _flare.blend; + + switch(_flare.type) { + case FLARE_TYPE.circle : + flare_circle(_t, _r, _a, _g, dir, _h[0], _h[1], _b); + break; - flare_blur( 0.7, 2.0 * _s, 0.5 * _a, 0, 0.25); - flare_circle(0.9, 2.0 * _s, 0.5 * _a, 6, _dir, 0, 0.1); - flare_circle(1.2, 0.5 * _s, 0.3 * _a); - - flare_blur( 1.5, 5 * _s, 0.4 * _a, 0, 0.7); - flare_circle(1.6, 3 * _s, 0.4 * _a, 6, _dir); - flare_ring( 1.9, 4 * _s, 0.3 * _a, 1 + 0.25 * _s, 0, 0.5); - flare_blur( 1.9, 3 * _s, 0.3 * _a, 0, 0.5); - break; - case 1 : - flare_crescent(0.5, 7.2 * _s, 7.5 * _s, 0.8 * _a, -0.2 * _s, _dir, 0.15, 0.2); - flare_crescent(0.7, 4.7 * _s, 5 * _s, 0.6 * _a, -0.2 * _s, _dir, 0.15, 0.2); - - flare_circle( 1.35, 2.0 * _s, 0.6 * _a, 32, 0, 0.4, 0.6); - flare_circle( 1.5 , 3.0 * _s, 0.4 * _a, 32, 0, 0.1, 0.2); - flare_ring( 1.75, 4.0 * _s, 0.6 * _a, 0.2 * _s, 0.1, 0.2); - - flare_line(_dis * 1.0, 0.6 * _a, 1 + 0.25 * _s, _dir); - break; + case FLARE_TYPE.ring : + var _th = _flare.th; _th = is_array(_th)? _th[0] + _th[1] * _sca : _th * _sca; + flare_ring(_t, _r, _a, _g, dir, _h[0], _h[1], _b, _th); + break; + + case FLARE_TYPE.star : + var _ir = _flare.ir; _ir = is_array(_ir)? _ir[0] + _ir[1] * _sca : _ir * _sca; + var _rt = _flare.ratio; + flare_star(_t, _r, _a, _g, dir, _h[0], _h[1], _b, _ir, _rt); + break; + + case FLARE_TYPE.line : + var _th = _flare.th; _th = is_array(_th)? _th[0] + _th[1] * _sca : _th * _sca; + flare_line(_r, _a, _th, dir, _b); + break; + } } BLEND_NORMAL @@ -301,5 +588,5 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) surface_reset_target(); return _outSurf; - } + } #endregion } \ No newline at end of file diff --git a/scripts/node_mk_flare/node_mk_flare.yy b/scripts/node_mk_flare/node_mk_flare.yy index 68e83ca55..76b56d7f7 100644 --- a/scripts/node_mk_flare/node_mk_flare.yy +++ b/scripts/node_mk_flare/node_mk_flare.yy @@ -5,7 +5,7 @@ "isCompatibility": false, "isDnD": false, "parent": { - "name": "MK effects", - "path": "folders/nodes/data/MK effects.yy", + "name": "mk flare", + "path": "folders/nodes/data/MK effects/mk flare.yy", }, } \ No newline at end of file diff --git a/scripts/node_particle/node_particle.gml b/scripts/node_particle/node_particle.gml index 58a462570..2c86d7eb5 100644 --- a/scripts/node_particle/node_particle.gml +++ b/scripts/node_particle/node_particle.gml @@ -118,8 +118,10 @@ function Node_Particle(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _ } shader_set_interpolation(_outSurf); - for(var i = 0; i < attributes.part_amount; i++) + for(var i = 0; i < attributes.part_amount; i++) { if(parts[i].active) parts[i].draw(_exact, _dim[0], _dim[1]); + //if(shader_current() != sh_sample) __shader_set = false; + } surface_reset_shader(); } else if(is_array(_outSurf)) { for( var o = 0, n = array_length(_outSurf); o < n; o++ ) { @@ -134,8 +136,10 @@ function Node_Particle(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _ } shader_set_interpolation(_outSurf[o]); - for(var i = 0; i < attributes.part_amount; i++) + for(var i = 0; i < attributes.part_amount; i++) { if(parts[i].active) parts[i].draw(_exact, _dim[0], _dim[1], o); + //if(shader_current() != sh_sample) __shader_set = false; + } surface_reset_shader(); } } diff --git a/scripts/node_registry/node_registry.gml b/scripts/node_registry/node_registry.gml index 21a546d01..cc00191e7 100644 --- a/scripts/node_registry/node_registry.gml +++ b/scripts/node_registry/node_registry.gml @@ -676,6 +676,7 @@ function __initNodes() { addNodeObject(generator, "MK Brownian", s_node_mk_brownian, "Node_MK_Brownian", [1, Node_MK_Brownian]).setVersion(11630); addNodeObject(generator, "MK Fall", s_node_mk_fall, "Node_MK_Fall", [1, Node_MK_Fall], ["Leaf", "Leaves"]).setVersion(11630); addNodeObject(generator, "MK Blinker", s_node_mk_blinker, "Node_MK_Blinker", [1, Node_MK_Blinker]).setVersion(11630); + addNodeObject(generator, "MK Lens Flare", s_node_mk_flare, "Node_MK_Flare", [1, Node_MK_Flare]).setVersion(11630); //addNodeObject(generator, "MK Sparkle", s_node_mk_sparkle, "Node_MK_Sparkle", [1, Node_MK_Sparkle]).patreonExtra(); #endregion @@ -1058,8 +1059,6 @@ function __initNodes() { addNodeObject(hid, "Sort Input", s_node_sort_array, "Node_Iterator_Sort_Inline_Input", [1, Node_Iterator_Sort_Inline_Input]).hideRecent(); addNodeObject(hid, "Sort Output", s_node_sort_array, "Node_Iterator_Sort_Inline_Output", [1, Node_Iterator_Sort_Inline_Output]).hideRecent(); - addNodeObject(hid, "MK Lens Flare", s_node_mk_blinker, "Node_MK_Flare", [1, Node_MK_Flare]).setVersion(11630); - ds_list_add(hid, "DynaSurf"); addNodeObject(hid, "Input", s_node_pixel_builder, "Node_DynaSurf_In", [1, Node_DynaSurf_In]).hideRecent(); addNodeObject(hid, "Output", s_node_pixel_builder, "Node_DynaSurf_Out", [1, Node_DynaSurf_Out]).hideRecent(); diff --git a/sprites/s_flare_type/b9e57cf1-ba04-4015-8a91-dce541458529.png b/sprites/s_flare_type/b9e57cf1-ba04-4015-8a91-dce541458529.png new file mode 100644 index 000000000..32c2cac4e Binary files /dev/null and b/sprites/s_flare_type/b9e57cf1-ba04-4015-8a91-dce541458529.png differ diff --git a/sprites/s_flare_type/cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15.png b/sprites/s_flare_type/cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15.png new file mode 100644 index 000000000..e38eec200 Binary files /dev/null and b/sprites/s_flare_type/cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15.png differ diff --git a/sprites/s_flare_type/dee2a6fb-00b5-4fbe-90b8-366f2b1faf69.png b/sprites/s_flare_type/dee2a6fb-00b5-4fbe-90b8-366f2b1faf69.png new file mode 100644 index 000000000..b65c706a6 Binary files /dev/null and b/sprites/s_flare_type/dee2a6fb-00b5-4fbe-90b8-366f2b1faf69.png differ diff --git a/sprites/s_flare_type/f3a0bdf1-7e1f-422b-8e03-db9cdc600239.png b/sprites/s_flare_type/f3a0bdf1-7e1f-422b-8e03-db9cdc600239.png new file mode 100644 index 000000000..2981be290 Binary files /dev/null and b/sprites/s_flare_type/f3a0bdf1-7e1f-422b-8e03-db9cdc600239.png differ diff --git a/sprites/s_flare_type/layers/b9e57cf1-ba04-4015-8a91-dce541458529/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png b/sprites/s_flare_type/layers/b9e57cf1-ba04-4015-8a91-dce541458529/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png new file mode 100644 index 000000000..32c2cac4e Binary files /dev/null and b/sprites/s_flare_type/layers/b9e57cf1-ba04-4015-8a91-dce541458529/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png differ diff --git a/sprites/s_flare_type/layers/cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png b/sprites/s_flare_type/layers/cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png new file mode 100644 index 000000000..e38eec200 Binary files /dev/null and b/sprites/s_flare_type/layers/cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png differ diff --git a/sprites/s_flare_type/layers/dee2a6fb-00b5-4fbe-90b8-366f2b1faf69/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png b/sprites/s_flare_type/layers/dee2a6fb-00b5-4fbe-90b8-366f2b1faf69/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png new file mode 100644 index 000000000..b65c706a6 Binary files /dev/null and b/sprites/s_flare_type/layers/dee2a6fb-00b5-4fbe-90b8-366f2b1faf69/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png differ diff --git a/sprites/s_flare_type/layers/f3a0bdf1-7e1f-422b-8e03-db9cdc600239/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png b/sprites/s_flare_type/layers/f3a0bdf1-7e1f-422b-8e03-db9cdc600239/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png new file mode 100644 index 000000000..2981be290 Binary files /dev/null and b/sprites/s_flare_type/layers/f3a0bdf1-7e1f-422b-8e03-db9cdc600239/f6601d2d-96f0-4ce0-8356-e304e8d2c478.png differ diff --git a/sprites/s_flare_type/s_flare_type.yy b/sprites/s_flare_type/s_flare_type.yy new file mode 100644 index 000000000..e4d5ed4b5 --- /dev/null +++ b/sprites/s_flare_type/s_flare_type.yy @@ -0,0 +1,80 @@ +{ + "resourceType": "GMSprite", + "resourceVersion": "1.0", + "name": "s_flare_type", + "bbox_bottom": 19, + "bbox_left": 3, + "bbox_right": 19, + "bbox_top": 4, + "bboxMode": 0, + "collisionKind": 1, + "collisionTolerance": 0, + "DynamicTexturePage": false, + "edgeFiltering": false, + "For3D": false, + "frames": [ + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"dee2a6fb-00b5-4fbe-90b8-366f2b1faf69",}, + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15",}, + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"f3a0bdf1-7e1f-422b-8e03-db9cdc600239",}, + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"b9e57cf1-ba04-4015-8a91-dce541458529",}, + ], + "gridX": 0, + "gridY": 0, + "height": 24, + "HTile": false, + "layers": [ + {"resourceType":"GMImageLayer","resourceVersion":"1.0","name":"f6601d2d-96f0-4ce0-8356-e304e8d2c478","blendMode":0,"displayName":"default","isLocked":false,"opacity":100.0,"visible":true,}, + ], + "nineSlice": null, + "origin": 4, + "parent": { + "name": "src", + "path": "folders/nodes/data/MK effects/mk flare/src.yy", + }, + "preMultiplyAlpha": false, + "sequence": { + "resourceType": "GMSequence", + "resourceVersion": "1.4", + "name": "s_flare_type", + "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": 4.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":"dee2a6fb-00b5-4fbe-90b8-366f2b1faf69","path":"sprites/s_flare_type/s_flare_type.yy",},},},"Disabled":false,"id":"a13b9564-ffb9-4476-a7d2-47f91b2b6a7c","IsCreationKey":false,"Key":0.0,"Length":1.0,"Stretch":false,}, + {"resourceType":"Keyframe","resourceVersion":"1.0","Channels":{"0":{"resourceType":"SpriteFrameKeyframe","resourceVersion":"1.0","Id":{"name":"cf6cb0da-2dd8-4a37-ac8c-3f9f078dfc15","path":"sprites/s_flare_type/s_flare_type.yy",},},},"Disabled":false,"id":"0532656c-9f90-4426-b453-be56fa84783f","IsCreationKey":false,"Key":1.0,"Length":1.0,"Stretch":false,}, + {"resourceType":"Keyframe","resourceVersion":"1.0","Channels":{"0":{"resourceType":"SpriteFrameKeyframe","resourceVersion":"1.0","Id":{"name":"f3a0bdf1-7e1f-422b-8e03-db9cdc600239","path":"sprites/s_flare_type/s_flare_type.yy",},},},"Disabled":false,"id":"44ea9dc6-076d-4abe-935e-65a7d5290b74","IsCreationKey":false,"Key":2.0,"Length":1.0,"Stretch":false,}, + {"resourceType":"Keyframe","resourceVersion":"1.0","Channels":{"0":{"resourceType":"SpriteFrameKeyframe","resourceVersion":"1.0","Id":{"name":"b9e57cf1-ba04-4015-8a91-dce541458529","path":"sprites/s_flare_type/s_flare_type.yy",},},},"Disabled":false,"id":"01802d32-8a27-4283-a1f5-8999e269120c","IsCreationKey":false,"Key":3.0,"Length":1.0,"Stretch":false,}, + ],},"modifiers":[],"spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, + ], + "visibleRange": null, + "volume": 1.0, + "xorigin": 12, + "yorigin": 12, + }, + "swatchColours": null, + "swfPrecision": 2.525, + "textureGroupId": { + "name": "Default", + "path": "texturegroups/Default", + }, + "type": 0, + "VTile": false, + "width": 24, +} \ No newline at end of file diff --git a/sprites/s_node_midi/4cb84541-aed1-4c49-919e-9930cb00b245.png b/sprites/s_node_midi/4cb84541-aed1-4c49-919e-9930cb00b245.png new file mode 100644 index 000000000..545f91cd4 Binary files /dev/null and b/sprites/s_node_midi/4cb84541-aed1-4c49-919e-9930cb00b245.png differ diff --git a/sprites/s_node_midi/b60d962d-74ac-46be-893b-537591f21bd4.png b/sprites/s_node_midi/b60d962d-74ac-46be-893b-537591f21bd4.png deleted file mode 100644 index 637fcd37a..000000000 Binary files a/sprites/s_node_midi/b60d962d-74ac-46be-893b-537591f21bd4.png and /dev/null differ diff --git a/sprites/s_node_midi/layers/4cb84541-aed1-4c49-919e-9930cb00b245/fe7e2a10-0cdb-42f4-8859-832519c72df7.png b/sprites/s_node_midi/layers/4cb84541-aed1-4c49-919e-9930cb00b245/fe7e2a10-0cdb-42f4-8859-832519c72df7.png new file mode 100644 index 000000000..545f91cd4 Binary files /dev/null and b/sprites/s_node_midi/layers/4cb84541-aed1-4c49-919e-9930cb00b245/fe7e2a10-0cdb-42f4-8859-832519c72df7.png differ diff --git a/sprites/s_node_midi/layers/b60d962d-74ac-46be-893b-537591f21bd4/a0236e25-d479-4e8d-b08a-2fe40e1cde9a.png b/sprites/s_node_midi/layers/b60d962d-74ac-46be-893b-537591f21bd4/a0236e25-d479-4e8d-b08a-2fe40e1cde9a.png deleted file mode 100644 index 637fcd37a..000000000 Binary files a/sprites/s_node_midi/layers/b60d962d-74ac-46be-893b-537591f21bd4/a0236e25-d479-4e8d-b08a-2fe40e1cde9a.png and /dev/null differ diff --git a/sprites/s_node_midi/s_node_midi.yy b/sprites/s_node_midi/s_node_midi.yy index 7783652a8..1426181c7 100644 --- a/sprites/s_node_midi/s_node_midi.yy +++ b/sprites/s_node_midi/s_node_midi.yy @@ -2,10 +2,10 @@ "resourceType": "GMSprite", "resourceVersion": "1.0", "name": "s_node_midi", - "bbox_bottom": 62, - "bbox_left": 1, - "bbox_right": 62, - "bbox_top": 1, + "bbox_bottom": 63, + "bbox_left": 0, + "bbox_right": 63, + "bbox_top": 0, "bboxMode": 0, "collisionKind": 1, "collisionTolerance": 0, @@ -13,14 +13,14 @@ "edgeFiltering": false, "For3D": false, "frames": [ - {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"b60d962d-74ac-46be-893b-537591f21bd4",}, + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"4cb84541-aed1-4c49-919e-9930cb00b245",}, ], "gridX": 0, "gridY": 0, "height": 64, "HTile": false, "layers": [ - {"resourceType":"GMImageLayer","resourceVersion":"1.0","name":"a0236e25-d479-4e8d-b08a-2fe40e1cde9a","blendMode":0,"displayName":"default","isLocked":false,"opacity":100.0,"visible":true,}, + {"resourceType":"GMImageLayer","resourceVersion":"1.0","name":"fe7e2a10-0cdb-42f4-8859-832519c72df7","blendMode":0,"displayName":"default","isLocked":false,"opacity":100.0,"visible":true,}, ], "nineSlice": null, "origin": 4, @@ -54,7 +54,7 @@ "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":"b60d962d-74ac-46be-893b-537591f21bd4","path":"sprites/s_node_midi/s_node_midi.yy",},},},"Disabled":false,"id":"a82898be-930f-4c4c-bbce-dcd75a9fc4b1","IsCreationKey":false,"Key":0.0,"Length":1.0,"Stretch":false,}, + {"resourceType":"Keyframe","resourceVersion":"1.0","Channels":{"0":{"resourceType":"SpriteFrameKeyframe","resourceVersion":"1.0","Id":{"name":"4cb84541-aed1-4c49-919e-9930cb00b245","path":"sprites/s_node_midi/s_node_midi.yy",},},},"Disabled":false,"id":"3c186466-017f-48dd-925e-c23c84406a48","IsCreationKey":false,"Key":0.0,"Length":1.0,"Stretch":false,}, ],},"modifiers":[],"spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, ], "visibleRange": null, diff --git a/sprites/s_node_mk_flare/e0c48424-1139-4a6f-89f6-4b1a21e21fb8.png b/sprites/s_node_mk_flare/e0c48424-1139-4a6f-89f6-4b1a21e21fb8.png new file mode 100644 index 000000000..9bef4e778 Binary files /dev/null and b/sprites/s_node_mk_flare/e0c48424-1139-4a6f-89f6-4b1a21e21fb8.png differ diff --git a/sprites/s_node_mk_flare/layers/e0c48424-1139-4a6f-89f6-4b1a21e21fb8/9b66d8df-cf27-4bf7-831b-5361fefc7132.png b/sprites/s_node_mk_flare/layers/e0c48424-1139-4a6f-89f6-4b1a21e21fb8/9b66d8df-cf27-4bf7-831b-5361fefc7132.png new file mode 100644 index 000000000..9bef4e778 Binary files /dev/null and b/sprites/s_node_mk_flare/layers/e0c48424-1139-4a6f-89f6-4b1a21e21fb8/9b66d8df-cf27-4bf7-831b-5361fefc7132.png differ diff --git a/sprites/s_node_mk_flare/s_node_mk_flare.yy b/sprites/s_node_mk_flare/s_node_mk_flare.yy new file mode 100644 index 000000000..a64065e8c --- /dev/null +++ b/sprites/s_node_mk_flare/s_node_mk_flare.yy @@ -0,0 +1,74 @@ +{ + "resourceType": "GMSprite", + "resourceVersion": "1.0", + "name": "s_node_mk_flare", + "bbox_bottom": 63, + "bbox_left": 0, + "bbox_right": 63, + "bbox_top": 0, + "bboxMode": 0, + "collisionKind": 1, + "collisionTolerance": 0, + "DynamicTexturePage": false, + "edgeFiltering": false, + "For3D": false, + "frames": [ + {"resourceType":"GMSpriteFrame","resourceVersion":"1.1","name":"e0c48424-1139-4a6f-89f6-4b1a21e21fb8",}, + ], + "gridX": 0, + "gridY": 0, + "height": 64, + "HTile": false, + "layers": [ + {"resourceType":"GMImageLayer","resourceVersion":"1.0","name":"9b66d8df-cf27-4bf7-831b-5361fefc7132","blendMode":0,"displayName":"default","isLocked":false,"opacity":100.0,"visible":true,}, + ], + "nineSlice": null, + "origin": 4, + "parent": { + "name": "MK effects", + "path": "folders/nodes/icons/MK effects.yy", + }, + "preMultiplyAlpha": false, + "sequence": { + "resourceType": "GMSequence", + "resourceVersion": "1.4", + "name": "s_node_mk_flare", + "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":"e0c48424-1139-4a6f-89f6-4b1a21e21fb8","path":"sprites/s_node_mk_flare/s_node_mk_flare.yy",},},},"Disabled":false,"id":"10b2ab6d-8e9f-4dbc-813e-88abe0b8f176","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