diff --git a/PixelComposer.resource_order b/PixelComposer.resource_order index 6c5b5bee7..5b51e44eb 100644 --- a/PixelComposer.resource_order +++ b/PixelComposer.resource_order @@ -1871,6 +1871,7 @@ {"name":"s_folder_add","order":66,"path":"sprites/s_folder_add/s_folder_add.yy",}, {"name":"s_folder_content","order":67,"path":"sprites/s_folder_content/s_folder_content.yy",}, {"name":"s_frame_range","order":68,"path":"sprites/s_frame_range/s_frame_range.yy",}, + {"name":"s_gear_16","order":230,"path":"sprites/s_gear_16/s_gear_16.yy",}, {"name":"s_gear_24","order":69,"path":"sprites/s_gear_24/s_gear_24.yy",}, {"name":"s_gizmo","order":4,"path":"sprites/s_gizmo/s_gizmo.yy",}, {"name":"s_grad_blend","order":70,"path":"sprites/s_grad_blend/s_grad_blend.yy",}, diff --git a/PixelComposer.yyp b/PixelComposer.yyp index e199af594..7859cfab8 100644 --- a/PixelComposer.yyp +++ b/PixelComposer.yyp @@ -2577,6 +2577,7 @@ {"id":{"name":"s_folder_content","path":"sprites/s_folder_content/s_folder_content.yy",},}, {"id":{"name":"s_frame_range","path":"sprites/s_frame_range/s_frame_range.yy",},}, {"id":{"name":"s_fx_pixel","path":"sprites/s_fx_pixel/s_fx_pixel.yy",},}, + {"id":{"name":"s_gear_16","path":"sprites/s_gear_16/s_gear_16.yy",},}, {"id":{"name":"s_gear_24","path":"sprites/s_gear_24/s_gear_24.yy",},}, {"id":{"name":"s_gizmo","path":"sprites/s_gizmo/s_gizmo.yy",},}, {"id":{"name":"s_grad_blend","path":"sprites/s_grad_blend/s_grad_blend.yy",},}, diff --git a/datafiles/data/Theme.zip b/datafiles/data/Theme.zip index c05957c84..ff451f474 100644 Binary files a/datafiles/data/Theme.zip and b/datafiles/data/Theme.zip differ diff --git a/objects/_p_dialog/Create_0.gml b/objects/_p_dialog/Create_0.gml index 7468e6bed..d477d45e3 100644 --- a/objects/_p_dialog/Create_0.gml +++ b/objects/_p_dialog/Create_0.gml @@ -6,7 +6,10 @@ #region data on_top = false; - with(_p_dialog) { if(on_top) continue; other.depth = min(depth - 1, other.depth); } + with(_p_dialog) { + if(on_top) continue; + other.depth = min(depth - 1, other.depth); + } ds_list_add(DIALOGS, self); diff --git a/objects/o_dialog_command_palette/Create_0.gml b/objects/o_dialog_command_palette/Create_0.gml index 23096647b..6dd36f8fd 100644 --- a/objects/o_dialog_command_palette/Create_0.gml +++ b/objects/o_dialog_command_palette/Create_0.gml @@ -103,7 +103,7 @@ event_inherited(); if(mouse_press(mb_right)) { selecting_hotkey = _key; - var _loadKey = string_to_var($"{_key.context}.{_key.name}"); + var _loadKey = _key.full_name(); var context_menu_settings = [ _loadKey, menuItem("Edit hotkey", function() /*=>*/ { diff --git a/objects/o_dialog_menubox/Destroy_0.gml b/objects/o_dialog_menubox/Destroy_0.gml index 129f53c96..2b5930258 100644 --- a/objects/o_dialog_menubox/Destroy_0.gml +++ b/objects/o_dialog_menubox/Destroy_0.gml @@ -3,5 +3,6 @@ event_inherited(); for( var i = 0, n = array_length(children); i < n; i++ ) instance_destroy(children[i]); -if(instance_number(o_dialog_menubox) == 1) - FOCUS = FOCUS_BEFORE; \ No newline at end of file +// print(FOCUS); +// if(instance_number(o_dialog_menubox) == 1) +// FOCUS = FOCUS_BEFORE; \ No newline at end of file diff --git a/objects/o_dialog_menubox/Draw_64.gml b/objects/o_dialog_menubox/Draw_64.gml index 197c058c5..9533dbdf1 100644 --- a/objects/o_dialog_menubox/Draw_64.gml +++ b/objects/o_dialog_menubox/Draw_64.gml @@ -88,7 +88,7 @@ if(!ready) exit; }; selecting_menu = _menuItem; - var _loadKey = string_to_var($"{_key.context}.{_key.name}"); + var _loadKey = _key.full_name(); var context_menu_settings = [ _loadKey, diff --git a/objects/o_dialog_panel/Draw_64.gml b/objects/o_dialog_panel/Draw_64.gml index ba2cfb34d..b421a91f7 100644 --- a/objects/o_dialog_panel/Draw_64.gml +++ b/objects/o_dialog_panel/Draw_64.gml @@ -100,11 +100,11 @@ if !ready exit; instance_destroy(); } else if(mouse_press(mb_right)) { menuCall("panel_window_menu", [ - menuItemAction(__txt("Move"), function() { - content.dragSurface = surface_clone(panel); + menuItem(__txt("Move"), function() { + content.dragSurface = surface_clone(panel); o_main.panel_dragging = content; - content.in_dialog = false; - panel_mouse = 1; + content.in_dialog = false; + panel_mouse = 1; instance_destroy(); }), diff --git a/objects/o_dialog_preference/Create_0.gml b/objects/o_dialog_preference/Create_0.gml index dbb081790..71573dda9 100644 --- a/objects/o_dialog_preference/Create_0.gml +++ b/objects/o_dialog_preference/Create_0.gml @@ -12,17 +12,27 @@ event_inherited(); should_restart = false; #endregion -#region resize +#region size dialog_resizable = true; dialog_w_min = ui(640); dialog_h_min = ui(480); + panel_width = dialog_w - ui(padding + padding) - page_width; + panel_height = dialog_h - ui(title_height + padding); + + hotkey_cont_h = ui(0); + hotkey_height = panel_height - hotkey_cont_h - ui(32); + onResize = function() /*=>*/ { - sp_page.resize(page_width - ui(4), dialog_h - ui(title_height + padding)); + panel_width = dialog_w - ui(padding + padding) - page_width; + panel_height = dialog_h - ui(title_height + padding); + hotkey_height = panel_height - hotkey_cont_h - ui(32); - sp_pref.resize( dialog_w - ui(padding + padding) - page_width, dialog_h - ui(title_height + padding)); - sp_hotkey.resize(dialog_w - ui(padding + padding) - page_width, dialog_h - ui(title_height + padding)); - sp_colors.resize(dialog_w - ui(padding + padding) - page_width, dialog_h - (title_height + ui(padding + 40))); + sp_page.resize(page_width - ui(4), panel_height); + + sp_pref.resize( panel_width, panel_height); + sp_hotkey.resize(panel_width, hotkey_height); + sp_colors.resize(panel_width, panel_height - ui(40)); } #endregion @@ -37,7 +47,7 @@ event_inherited(); section_current = ""; sections = array_create(array_length(page)); - sp_page = new scrollPane(page_width - ui(4), dialog_h - ui(title_height + padding), function(_y, _m, _r) { + sp_page = new scrollPane(page_width - ui(4), panel_height, function(_y, _m, _r) { draw_clear_alpha(COLORS.panel_bg_clear, 1); var ww = sp_page.surface_w; var hh = 0; @@ -403,6 +413,18 @@ event_inherited(); new checkBox(function() /*=>*/ { PREFERENCES.panel_graph_group_require_shift = !PREFERENCES.panel_graph_group_require_shift; PREF_SAVE(); }) )); + ds_list_add(pref_appr, new __Panel_Linear_Setting_Item_Preference( + __txtx("pref_use_alt", "Use ALT for"), + "alt_picker", + new buttonGroup([ "Pan", "Color Picker" ], function(val) /*=>*/ { PREFERENCES.alt_picker = val; PREF_SAVE(); }) + )); + + ds_list_add(pref_appr, new __Panel_Linear_Setting_Item( + __txtx("pref_pan_key", "Panning key"), + new scrollBox([ "Middle Mouse", "Mouse 4", "Mouse 5" ], function(val) /*=>*/ { PREFERENCES.pan_mouse_key = val + 3; PREF_SAVE(); }), + function() /*=>*/ { return PREFERENCES.pan_mouse_key - 3; }, + )); + ds_list_add(pref_appr, __txt("Preview")); ////////////////////////////////////////////////////////////////////// Preview ds_list_add(pref_appr, new __Panel_Linear_Setting_Item_Preference( @@ -524,7 +546,7 @@ event_inherited(); }, false); sb_theme.align = fa_left; - sp_colors = new scrollPane(dialog_w - ui(padding + padding) - page_width, dialog_h - (title_height + ui(padding) + ui(40)), function(_y, _m, _r) { + sp_colors = new scrollPane(panel_width, panel_height - ui(40), function(_y, _m, _r) { draw_clear_alpha(COLORS.panel_bg_clear, 0); var hh = 0; var th = line_get_height(f_p0); @@ -616,121 +638,108 @@ event_inherited(); #endregion #region hotkey - pref_hot = ds_list_create(); - ds_list_add(pref_hot, [ - __txtx("pref_use_alt", "Use ALT for"), - "alt_picker", - new buttonGroup([ "Pan", "Color Picker" ], function(val) /*=>*/ { - PREFERENCES.alt_picker = val; - PREF_SAVE(); - }) - ]); + hk_editing = noone; + hotkeyContext = []; + hotkeyArray = []; - ds_list_add(pref_hot, [ - __txtx("pref_pan_key", "Panning key"), - function() /*=>*/ { return PREFERENCES.pan_mouse_key - 3; }, - new scrollBox([ "Middle Mouse", "Mouse 4", "Mouse 5" ], function(val) /*=>*/ { - PREFERENCES.pan_mouse_key = val + 3; - PREF_SAVE(); - }) - ]); + for(var j = 0; j < ds_list_size(HOTKEY_CONTEXT); j++) { + var ctx = HOTKEY_CONTEXT[| j]; + var _lst = []; + + var ll = HOTKEYS[? ctx]; + for(var i = 0; i < ds_list_size(ll); i++) + array_push(_lst, ll[| i]); + + array_push(hotkeyContext, { context: ctx, list: _lst }); + + var _title = ctx == ""? "Global" : ctx; + _title = string_replace_all(_title, "_", " "); + array_push(hotkeyArray, _title); + } - hk_editing = noone; - - sp_hotkey = new scrollPane(dialog_w - ui(padding + padding) - page_width, dialog_h - ui(title_height + padding), function(_y, _m) { - draw_clear_alpha(COLORS.panel_bg_clear, 0); - var padd = ui(8); - var hh = ui(8); - var currGroup = noone; - var x1 = sp_hotkey.surface_w; - var key_x1 = x1 - ui(32); - var modified = false; + var keys = struct_get_names(HOTKEYS_CUSTOM); + for( var i = 0, n = array_length(keys); i < n; i++ ) { + var ctx = keys[i]; - draw_set_text(f_p0, fa_left, fa_top); + var hotkey = HOTKEYS_CUSTOM[$ ctx]; + var hks = struct_get_names(hotkey); + var _lst = []; - var yy = _y + ui(8); - var th = line_get_height(f_p0); - var ind = 0; - var sect = []; - var psect = ""; - - for( var i = 0, n = ds_list_size(pref_hot); i < n; i++ ) { - var _pref = pref_hot[| i]; + for (var j = 0, m = array_length(hks); j < m; j++) { + var _n = hks[j]; + var _k = hotkey[$ _n]; - var _yy = yy + hh; - var name = _pref[0]; - var val = _pref[1]; - val = is_method(val)? val() : PREFERENCES[$ val]; + _k.context = ctx; + _k.name = _n; - if(search_text != "" && string_pos(string_lower(search_text), string_lower(name)) == 0) - continue; - - if(ind++ % 2 == 0) - draw_sprite_stretched_ext(THEME.ui_panel_bg, 0, 0, _yy - padd, sp_hotkey.surface_w, th + padd * 2, COLORS.dialog_preference_prop_bg, 1); - - draw_set_text(f_p0, fa_left, fa_top, COLORS._main_text); - draw_text_add(ui(24), _yy, _pref[0]); - - _pref[2].setFocusHover(sFOCUS, sHOVER && sp_hotkey.hover); - - var widget_w = ui(240); - var widget_h = th + (padd - ui(4)) * 2; - - var widget_x = x1 - ui(4) - widget_w; - var widget_y = _yy - ui(4); - - var params = new widgetParam(widget_x, widget_y, widget_w, widget_h, val, {}, _m, sp_hotkey.x, sp_hotkey.y); - var _th = _pref[2].drawParam(params) ?? 0; - if(_pref[2].inBBOX(_m)) sp_hotkey.hover_content = true; - - hh += _th + padd + ui(8); + array_push(_lst, _k); } - th = line_get_height(f_p1); - ind = 0; + array_push(hotkeyContext, { context: ctx, list: _lst }); - var _hov = sHOVER && sp_hotkey.hover; + var _title = ctx == ""? "Global" : ctx; + _title = string_replace_all(_title, "_", " "); + array_push(hotkeyArray, _title); + } + + hk_page = 0; + hk_scroll = new scrollBox(hotkeyArray, function(val) /*=>*/ { hk_page = val; }); + hk_scroll.align = fa_left; + + sp_hotkey = new scrollPane(panel_width, hotkey_height, function(_y, _m) { + draw_clear_alpha(COLORS.panel_bg_clear, 0); + draw_set_text(f_p2, fa_left, fa_top); - for(var j = 0; j < ds_list_size(HOTKEY_CONTEXT); j++) { - var ll = HOTKEYS[? HOTKEY_CONTEXT[| j]]; + var padd = ui(6); + var hh = 0; + var currGroup = noone; + + var _ww = sp_hotkey.surface_w; + var key_x1 = _ww - ui(32); + var yy = _y + ui(8); + + var ind = 0; + var sect = []; + var psect = ""; + var th = line_get_height(); + var _hov = sHOVER && sp_hotkey.hover; + var modified = false; + + // for (var i = 0, n = array_length(hotkeyContext); i < n; i++) { + // var _ctxObj = hotkeyContext[i]; + var _ctxObj = hotkeyContext[hk_page]; + var _cntx = _ctxObj.context; + var _list = _ctxObj.list; + var _yy = yy + hh; - for(var i = 0; i < ds_list_size(ll); i++) { - var key = ll[| i]; - var group = key.context; - var name = __txt(key.name); - var pkey = key.key; - var modi = key.modi; + // var _grlab = _cntx == ""? __txt("Global") : _cntx; + // draw_set_text(f_p1, fa_left, fa_top, COLORS._main_text_sub); + // draw_text_add(ui(8), _yy, _grlab); + + // array_push(sect, [ _grlab, sp_hotkey, hh + ui(12) ]); + // if(_yy >= 0 && section_current == "") + // section_current = psect; + // psect = _grlab; + + ind = 0; + // hh += string_height("l") + ui(8); + + for (var j = 0, m = array_length(_list); j < m; j++) { - var dkey = key.dKey; - var dmod = key.dModi; - var _yy = yy + hh; + var key = _list[j]; + var name = __txt(key.name); if(search_text != "" && string_pos(string_lower(search_text), string_lower(name)) == 0) continue; - if(group != currGroup) { - if(group != "") hh += ui(12); - - var _grp = group == ""? __txt("Global") : group; - draw_set_text(f_p0b, fa_left, fa_top, COLORS._main_text_sub); - draw_text_add(ui(8), _yy, _grp); - - array_push(sect, [ _grp, sp_hotkey, hh + ui(12) ]); - if(_yy >= 0 && section_current == "") - section_current = psect; - psect = _grp; - - ind = 0; - hh += string_height("l") + ui(16); - currGroup = group; - } - + var pkey = key.key; + var modi = key.modi; var _yy = yy + hh; var _lb_y = _yy; - if(ind++ % 2 == 0) draw_sprite_stretched_ext(THEME.ui_panel_bg, 0, 0, _yy - padd, sp_hotkey.surface_w, th + padd * 2, COLORS.dialog_preference_prop_bg, 1); + if(ind++ % 2 == 0) draw_sprite_stretched_ext(THEME.ui_panel_bg, 0, 0, _yy - padd, _ww, th + padd * 2, COLORS.dialog_preference_prop_bg, 1); - draw_set_text(f_p1, fa_left, fa_top, COLORS._main_text); + draw_set_text(f_p2, fa_left, fa_top, COLORS._main_text); draw_text_add(ui(24), _lb_y, name); var dk = key_get_name(key.key, key.modi); @@ -738,9 +747,9 @@ event_inherited(); var tx = key_x1 - ui(24); var bx = tx - kw - ui(8); - var by = _yy - ui(4); + var by = _yy - ui(3); var bw = kw + ui(16); - var bh = th + ui(8); + var bh = th + ui(6); var cc = c_white; if(hk_editing == key) { @@ -751,7 +760,7 @@ event_inherited(); if(_hov && point_in_rectangle(_m[0], _m[1], bx, by, bx + bw, by + bh)) { draw_sprite_stretched_ext(THEME.ui_panel, 1, bx, by, bw, bh, CDEF.main_ltgrey); sp_hotkey.hover_content = true; - cc = CDEF.main_ltgrey; + cc = CDEF.main_white; if(mouse_press(mb_left, sFOCUS)) { hk_editing = key; @@ -760,98 +769,18 @@ event_inherited(); } else { draw_sprite_stretched_ext(THEME.ui_panel, 1, bx, by, bw, bh, CDEF.main_dkgrey, 1); - cc = COLORS._main_text_sub; + cc = CDEF.main_ltgrey; } } - draw_set_text(f_p1, fa_right, fa_top, cc); + draw_set_text(f_p2, fa_right, fa_top, cc); draw_text_add(tx, _lb_y, dk); - if(key.key != dkey || key.modi != dmod) { - modified = true; - var bx = x1 - ui(32); - var by = _yy; - var b = buttonInstant(THEME.button_hide, bx, by, ui(24), ui(24), _m, sFOCUS, sHOVER && sp_hotkey.hover, __txt("Reset"), THEME.refresh_16); - if(b) sp_hotkey.hover_content = true; - if(b == 2) { - key.key = dkey; - key.modi = dmod; - - PREF_SAVE(); - } - } - - hh += th + padd * 2; - } - } - - draw_set_text(f_p0b, fa_left, fa_top, COLORS._main_text_sub); - draw_text_add(ui(8), yy + hh, "Nodes"); - array_push(sect, [ "Nodes", sp_hotkey, hh + ui(12) ]); - hh += string_height("l") + ui(16); - - var keys = struct_get_names(HOTKEYS_CUSTOM); - for( var i = 0, n = array_length(keys); i < n; i++ ) { - var _key = keys[i]; - var hotkeys = struct_get_names(HOTKEYS_CUSTOM[$ _key]); - var _key_t = string_title(string_replace(_key, "Node_", "")); - var _yy = yy + hh; - - draw_set_text(f_p0b, fa_left, fa_top, COLORS._main_text_sub); - draw_text_add(ui(8), _yy, _key_t); - array_push(sect, [ "- " + _key_t, sp_hotkey, hh + ui(12) ]); - - if(_yy >= 0 && section_current == "") - section_current = psect; - psect = "- " + _key_t; - hh += string_height("l") + ui(16); - ind = 0; - - for( var j = 0, m = array_length(hotkeys); j < m; j++ ) { - var _hotkey = hotkeys[j]; - var hotkey = HOTKEYS_CUSTOM[$ _key][$ _hotkey]; - - var name = __txt(_hotkey); - var pkey = hotkey.getName(); - var _yy = yy + hh; - - if(ind++ % 2 == 0) - draw_sprite_stretched_ext(THEME.ui_panel_bg, 0, 0, _yy - padd, sp_hotkey.surface_w, th + padd * 2, COLORS.dialog_preference_prop_bg, 1); - - var _lb_y = _yy; - draw_set_text(f_p1, fa_left, fa_top, COLORS._main_text); - draw_text_add(ui(24), _lb_y, name); - - var kw = string_width(pkey); - var bx = key_x1 - ui(40) - kw; - var key = hotkey; - - if(hk_editing == key) { - draw_sprite_stretched(THEME.button_hide, 2, key_x1 - ui(40) - kw, _yy, kw + ui(32), th); - - } else { - var bx = key_x1 - ui(40) - kw; - var by = _yy; - var b = buttonInstant(THEME.button_hide, bx, by, kw + ui(32), th, _m, sFOCUS, sHOVER && sp_hotkey.hover) - - if(b) sp_hotkey.hover_content = true; - if(b == 2) { - hk_editing = key; - keyboard_lastchar = key.key; - } - } - - var cc = (hotkey.key == "")? COLORS._main_text_sub : COLORS._main_text; - if(hk_editing == key) cc = COLORS._main_text_accent; - - draw_set_text(f_p1, fa_right, fa_top, cc); - draw_text_add(key_x1 - ui(24), _lb_y, pkey); - if(key.key != key.dKey || key.modi != key.dModi) { modified = true; - var bx = x1 - ui(32); - var by = _yy; - var b = buttonInstant(THEME.button_hide, bx, by, ui(24), ui(24), _m, sFOCUS, sHOVER && sp_hotkey.hover, __txt("Reset"), THEME.refresh_16) + var bx = x1 - ui(32); + var by = _yy + th / 2 - ui(12); + var b = buttonInstant(THEME.button_hide, bx, by, ui(24), ui(24), _m, sFOCUS, _hov, __txt("Reset"), THEME.refresh_16); if(b) sp_hotkey.hover_content = true; if(b == 2) { @@ -864,19 +793,19 @@ event_inherited(); hh += th + padd * 2; } - } + // } + // sections[page_current] = sect; if(hk_editing != noone) hotkey_editing(hk_editing); - sections[page_current] = sect; - return hh; + return hh + ui(32); }) #endregion #region scrollpane current_list = pref_global; - sp_pref = new scrollPane(dialog_w - ui(padding + padding) - page_width, dialog_h - ui(title_height + padding), function(_y, _m, _r) { + sp_pref = new scrollPane(panel_width, panel_height, function(_y, _m, _r) { draw_clear_alpha(COLORS.panel_bg_clear, 0); var hh = 0; var th = TEXTBOX_HEIGHT; diff --git a/objects/o_dialog_preference/Draw_64.gml b/objects/o_dialog_preference/Draw_64.gml index bba15050b..6f7b07158 100644 --- a/objects/o_dialog_preference/Draw_64.gml +++ b/objects/o_dialog_preference/Draw_64.gml @@ -96,7 +96,14 @@ if !ready exit; if(mouse_press(mb_left, sFOCUS)) hk_editing = noone; + var _ppy = py + hotkey_cont_h; + + hk_scroll.font = f_p2; + hk_scroll.setFocusHover(sFOCUS, sHOVER); + hk_scroll.draw(px, _ppy, ui(200), ui(24), hk_page); + sp_hotkey.setFocusHover(sFOCUS, sHOVER); - sp_hotkey.draw(px, py); + sp_hotkey.draw(px, _ppy + ui(32)); + } #endregion \ No newline at end of file diff --git a/objects/o_dialog_splash/Create_0.gml b/objects/o_dialog_splash/Create_0.gml index 470da97ce..c08a27657 100644 --- a/objects/o_dialog_splash/Create_0.gml +++ b/objects/o_dialog_splash/Create_0.gml @@ -243,8 +243,6 @@ event_inherited(); if(mouse_press(mb_left, sFOCUS)) { LOAD_PATH(_project.path, true); PROJECT.thumbnail = array_safe_get_fast(_project.spr_path, 0); - - if(PROJECT.meta.file_id) PROJECT.meta.steam = FILE_STEAM_TYPE.steamOpen; instance_destroy(); } } diff --git a/scripts/__node_3d_combine/__node_3d_combine.gml b/scripts/__node_3d_combine/__node_3d_combine.gml index 58b9931e2..d6c2df184 100644 --- a/scripts/__node_3d_combine/__node_3d_combine.gml +++ b/scripts/__node_3d_combine/__node_3d_combine.gml @@ -4,20 +4,20 @@ function __Node_3D_Combine(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[0] = nodeValue_Dimension(self) .rejectArray(); - inputs[1] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]) + inputs[1] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]) .rejectArray(); - inputs[2] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]) + inputs[2] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]) .rejectArray(); - inputs[3] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]) + inputs[3] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]) .rejectArray(); - inputs[4] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[4] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference) .rejectArray(); - inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]) + inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]) .rejectArray(); inputs[6] = nodeValue_Rotation("Light direction", self, 0) diff --git a/scripts/__node_3d_displace/__node_3d_displace.gml b/scripts/__node_3d_displace/__node_3d_displace.gml index 194c9f241..e889c0f9f 100644 --- a/scripts/__node_3d_displace/__node_3d_displace.gml +++ b/scripts/__node_3d_displace/__node_3d_displace.gml @@ -4,16 +4,16 @@ function __Node_3D_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[1] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); - inputs[2] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[3] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); - inputs[4] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[4] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef( function() { return getInputData(0); }, VALUE_UNIT.reference); - inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[6] = nodeValue_Rotation("Light direction", self, 0); diff --git a/scripts/__node_3d_extrude/__node_3d_extrude.gml b/scripts/__node_3d_extrude/__node_3d_extrude.gml index d49802613..f2b1ce520 100644 --- a/scripts/__node_3d_extrude/__node_3d_extrude.gml +++ b/scripts/__node_3d_extrude/__node_3d_extrude.gml @@ -6,18 +6,18 @@ function __Node_3D_Extrude(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[1] = nodeValue_Dimension(self); - inputs[2] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Object rotation", self, [ 0, 180, 0 ]); + inputs[3] = nodeValue_Vec3("Object rotation", self, [ 0, 180, 0 ]); - inputs[4] = nodeValue_Vector("Object scale", self, [ 1, 1, 0.1 ]); + inputs[4] = nodeValue_Vec3("Object scale", self, [ 1, 1, 0.1 ]); - inputs[5] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[5] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef( function() { return getInputData(1); }, VALUE_UNIT.reference); - inputs[6] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); + inputs[6] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); - inputs[7] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[7] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[8] = nodeValue_Trigger("Manual generate", self, false ) .setDisplay(VALUE_DISPLAY.button, { name: "Generate", UI : true, onClick: function() { generateMesh(); doUpdate(); } }); diff --git a/scripts/__node_3d_obj/__node_3d_obj.gml b/scripts/__node_3d_obj/__node_3d_obj.gml index 8171e4b37..2069e718b 100644 --- a/scripts/__node_3d_obj/__node_3d_obj.gml +++ b/scripts/__node_3d_obj/__node_3d_obj.gml @@ -13,12 +13,12 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo inputs[2] = nodeValue_Dimension(self); - inputs[3] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[3] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference); - inputs[4] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); + inputs[4] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); - inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[6] = nodeValue_Rotation("Light direction", self, 0) .rejectArray(); @@ -37,14 +37,14 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo inputs[10] = nodeValue_Color("Ambient color", self, c_grey) .rejectArray(); - inputs[11] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[11] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); inputs[12] = nodeValue_Bool("Flip UV", self, true, "Flip UV axis, can be use to fix some texture mapping error.") .rejectArray(); - inputs[13] = nodeValue_Vector("Object rotation", self, [ 0, 0, 180 ]); + inputs[13] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 180 ]); - inputs[14] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[14] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); inputs[15] = nodeValue_Enum_Button("Projection", self, 0, [ "Orthographic", "Perspective" ]) .rejectArray(); diff --git a/scripts/__node_3d_object/__node_3d_object.gml b/scripts/__node_3d_object/__node_3d_object.gml index 41fb9b5c3..d44f04e2c 100644 --- a/scripts/__node_3d_object/__node_3d_object.gml +++ b/scripts/__node_3d_object/__node_3d_object.gml @@ -8,13 +8,13 @@ function Node_3D_Object(_x, _y, _group = noone) : Node_3D(_x, _y, _group) constr preview_channel = 0; apply_anchor = false; - inputs[0] = nodeValue_Vector("Position", self, [ 0, 0, 0 ], { linkable: false }); + inputs[0] = nodeValue_Vec3("Position", self, [ 0, 0, 0 ], { linkable: false }); inputs[1] = nodeValue_Quaternion("Rotation", self, [ 0, 0, 0, 1 ]); - inputs[2] = nodeValue_Vector("Scale", self, [ 1, 1, 1 ]); + inputs[2] = nodeValue_Vec3("Scale", self, [ 1, 1, 1 ]); - inputs[3] = nodeValue_Vector("Anchor", self, [ 0, 0, 0 ], { + inputs[3] = nodeValue_Vec3("Anchor", self, [ 0, 0, 0 ], { linkable: false, side_button : button(function() { apply_anchor = !apply_anchor; triggerRender(); }) .setIcon(THEME.icon_3d_anchor, [ function() /*=>*/ {return apply_anchor} ], c_white) diff --git a/scripts/__node_3d_plane/__node_3d_plane.gml b/scripts/__node_3d_plane/__node_3d_plane.gml index fa8f37559..fd93dcf7b 100644 --- a/scripts/__node_3d_plane/__node_3d_plane.gml +++ b/scripts/__node_3d_plane/__node_3d_plane.gml @@ -4,21 +4,21 @@ function __Node_3D_Plane(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[1] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); - inputs[2] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[3] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[4] = nodeValue_Enum_Scroll("Output dimension", self, OUTPUT_SCALING.same_as_input, [ "Same as input", "Constant", "Relative to input" ]) .rejectArray(); - inputs[5] = nodeValue_Vector("Constant dimension", self, DEF_SURF); + inputs[5] = nodeValue_Vec2("Constant dimension", self, DEF_SURF); - inputs[6] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[6] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); - inputs[7] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[7] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); inputs[8] = nodeValue_Enum_Button("Projection", self, 0, [ "Orthographic", "Perspective" ]) .rejectArray(); @@ -26,9 +26,9 @@ function __Node_3D_Plane(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[9] = nodeValue_Float("Field of view", self, 60) .setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 0.1 ] }); - inputs[10] = nodeValue_Vector("Texture scale", self, [ 1, 1 ]); + inputs[10] = nodeValue_Vec2("Texture scale", self, [ 1, 1 ]); - inputs[11] = nodeValue_Vector("Texture shift", self, [ 0, 0 ]); + inputs[11] = nodeValue_Vec2("Texture shift", self, [ 0, 0 ]); inputs[12] = nodeValue_Int("Subdiviion", self, 1) diff --git a/scripts/__node_3d_prim_cone/__node_3d_prim_cone.gml b/scripts/__node_3d_prim_cone/__node_3d_prim_cone.gml index b212009ee..699ed32ab 100644 --- a/scripts/__node_3d_prim_cone/__node_3d_prim_cone.gml +++ b/scripts/__node_3d_prim_cone/__node_3d_prim_cone.gml @@ -4,14 +4,14 @@ function __Node_3D_Cone(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[1] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); - inputs[2] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[3] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); - inputs[4] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[4] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); inputs[5] = nodeValue_Rotation("Light direction", self, 0); @@ -24,9 +24,9 @@ function __Node_3D_Cone(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[8] = nodeValue_Color("Light color", self, c_white); inputs[9] = nodeValue_Color("Ambient color", self, c_grey); - inputs[10] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[10] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[11] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[11] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); inputs[12] = nodeValue_Enum_Button("Projection", self, 0, [ "Orthographic", "Perspective" ]) .rejectArray(); diff --git a/scripts/__node_3d_prim_cube/__node_3d_prim_cube.gml b/scripts/__node_3d_prim_cube/__node_3d_prim_cube.gml index 925beefeb..e09009325 100644 --- a/scripts/__node_3d_prim_cube/__node_3d_prim_cube.gml +++ b/scripts/__node_3d_prim_cube/__node_3d_prim_cube.gml @@ -7,12 +7,12 @@ function __Node_3D_Cube(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Dimension(self); - inputs[2] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[2] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); - inputs[3] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); + inputs[3] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); - inputs[4] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[4] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[5] = nodeValue_Bool("Textures per face", self, false); @@ -23,7 +23,7 @@ function __Node_3D_Cube(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[10] = nodeValue_Surface("Textures 4", self).setVisible(false); inputs[11] = nodeValue_Surface("Textures 5", self).setVisible(false); - inputs[12] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[12] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); inputs[13] = nodeValue_Rotation("Light direction", self, 0); @@ -37,9 +37,9 @@ function __Node_3D_Cube(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[17] = nodeValue_Color("Ambient color", self, c_grey); - inputs[18] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[18] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[19] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[19] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); inputs[20] = nodeValue_Enum_Button("Projection", self, 0, [ "Orthographic", "Perspective" ]) .rejectArray(); diff --git a/scripts/__node_3d_prim_cylinder/__node_3d_prim_cylinder.gml b/scripts/__node_3d_prim_cylinder/__node_3d_prim_cylinder.gml index 501f185b9..fc8525e2f 100644 --- a/scripts/__node_3d_prim_cylinder/__node_3d_prim_cylinder.gml +++ b/scripts/__node_3d_prim_cylinder/__node_3d_prim_cylinder.gml @@ -9,18 +9,18 @@ function __Node_3D_Cylinder(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr inputs[2] = nodeValue_Dimension(self); - inputs[3] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[3] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); - inputs[4] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); + inputs[4] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); - inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[6] = nodeValue_Surface("Textures top", self); inputs[7] = nodeValue_Surface("Textures bottom", self); inputs[8] = nodeValue_Surface("Textures side", self); - inputs[9] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[9] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); inputs[10] = nodeValue_Rotation("Light direction", self, 0); @@ -33,9 +33,9 @@ function __Node_3D_Cylinder(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr inputs[13] = nodeValue_Color("Light color", self, c_white); inputs[14] = nodeValue_Color("Ambient color", self, c_grey); - inputs[15] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[15] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[16] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[16] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); inputs[17] = nodeValue_Enum_Button("Projection", self, 0, [ "Orthographic", "Perspective" ]) .rejectArray(); diff --git a/scripts/__node_3d_prim_sphere/__node_3d_prim_sphere.gml b/scripts/__node_3d_prim_sphere/__node_3d_prim_sphere.gml index 6d89b6006..7a53bf97d 100644 --- a/scripts/__node_3d_prim_sphere/__node_3d_prim_sphere.gml +++ b/scripts/__node_3d_prim_sphere/__node_3d_prim_sphere.gml @@ -3,21 +3,21 @@ function __Node_3D_Sphere(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou batch_output = false; dimension_index = 1; - inputs[0] = nodeValue_Vector("Subdivisions", self, [8, 4]) + inputs[0] = nodeValue_Vec2("Subdivisions", self, [8, 4]) .setTooltip("Amount of polygon in X and Y axis."); inputs[1] = nodeValue_Dimension(self); - inputs[2] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[2] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); - inputs[3] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); + inputs[3] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); - inputs[4] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[4] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[5] = nodeValue_Surface("Textures", self); - inputs[6] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[6] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); inputs[7] = nodeValue_Rotation("Light direction", self, 0); @@ -30,9 +30,9 @@ function __Node_3D_Sphere(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[10] = nodeValue_Color("Light color", self, c_white); inputs[11] = nodeValue_Color("Ambient color", self, c_grey); - inputs[12] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[12] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[13] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[13] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); inputs[14] = nodeValue_Enum_Button("Projection", self, 0, [ "Orthographic", "Perspective" ]) .rejectArray(); diff --git a/scripts/__node_3d_render/__node_3d_render.gml b/scripts/__node_3d_render/__node_3d_render.gml index 450cc5244..94fb6e706 100644 --- a/scripts/__node_3d_render/__node_3d_render.gml +++ b/scripts/__node_3d_render/__node_3d_render.gml @@ -3,12 +3,12 @@ // inputs[2] = nodeValue_Dimension(self); -// inputs[3] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) +// inputs[3] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) // .setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference); -// inputs[4] = nodeValue_Vector("Render rotation", self, [ 0, 0, 0 ]); +// inputs[4] = nodeValue_Vec3("Render rotation", self, [ 0, 0, 0 ]); -// inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); +// inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); // inputs[6] = nodeValue_Float("Light direction", self, 0) // .setDisplay(VALUE_DISPLAY.rotation) diff --git a/scripts/__node_3d_repeat/__node_3d_repeat.gml b/scripts/__node_3d_repeat/__node_3d_repeat.gml index 43a3f099a..cf1209358 100644 --- a/scripts/__node_3d_repeat/__node_3d_repeat.gml +++ b/scripts/__node_3d_repeat/__node_3d_repeat.gml @@ -3,16 +3,16 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[1] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); - inputs[2] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[3] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); - inputs[4] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[4] = nodeValue_Vec3("Render position", self, [ 0.5, 0.5 ]) .setUnitRef( function() { return getInputData(0); }, VALUE_UNIT.reference); - inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[6] = nodeValue_Rotation("Light direction", self, 0); @@ -31,11 +31,11 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru inputs[12] = nodeValue_Int("Repeat", self, 1, "Amount of copies to be generated."); - inputs[13] = nodeValue_Vector("Repeat position", self, [ 1, 0, 0 ]); + inputs[13] = nodeValue_Vec3("Repeat position", self, [ 1, 0, 0 ]); - inputs[14] = nodeValue_Vector("Repeat rotation", self, [ 0, 0, 0 ]); + inputs[14] = nodeValue_Vec3("Repeat rotation", self, [ 0, 0, 0 ]); - inputs[15] = nodeValue_Vector("Repeat scale", self, [ 1, 1, 1 ]); + inputs[15] = nodeValue_Vec3("Repeat scale", self, [ 1, 1, 1 ]); inputs[16] = nodeValue_Enum_Button("Repeat pattern", self, 0, [ "Linear", "Circular" ]) .rejectArray(); diff --git a/scripts/__node_3d_transform/__node_3d_transform.gml b/scripts/__node_3d_transform/__node_3d_transform.gml index 0b9f0c2b6..c76672a16 100644 --- a/scripts/__node_3d_transform/__node_3d_transform.gml +++ b/scripts/__node_3d_transform/__node_3d_transform.gml @@ -4,16 +4,16 @@ function __Node_3D_Transform(_x, _y, _group = noone) : Node_Processor(_x, _y, _g inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Object position", self, [ 0, 0, 0 ]); + inputs[1] = nodeValue_Vec3("Object position", self, [ 0, 0, 0 ]); - inputs[2] = nodeValue_Vector("Object rotation", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Object rotation", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Object scale", self, [ 1, 1, 1 ]); + inputs[3] = nodeValue_Vec3("Object scale", self, [ 1, 1, 1 ]); - inputs[4] = nodeValue_Vector("Render position", self, [ 0.5, 0.5 ]) + inputs[4] = nodeValue_Vec2("Render position", self, [ 0.5, 0.5 ]) .setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference); - inputs[5] = nodeValue_Vector("Render scale", self, [ 1, 1 ]); + inputs[5] = nodeValue_Vec2("Render scale", self, [ 1, 1 ]); inputs[6] = nodeValue_Rotation("Light direction", self, 0); diff --git a/scripts/__node_VFX_effector/__node_VFX_effector.gml b/scripts/__node_VFX_effector/__node_VFX_effector.gml index a4931c275..3c8d99207 100644 --- a/scripts/__node_VFX_effector/__node_VFX_effector.gml +++ b/scripts/__node_VFX_effector/__node_VFX_effector.gml @@ -32,7 +32,7 @@ function Node_VFX_effector(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[3] = nodeValue_Float("Falloff distance", self, 4 ) .rejectArray(); - inputs[4] = nodeValue_Vector("Effect Vector", self, [ -1, 0 ] ) + inputs[4] = nodeValue_Vec2("Effect Vector", self, [ -1, 0 ] ) .rejectArray(); inputs[5] = nodeValue_Float("Strength", self, 1 ) diff --git a/scripts/_node_VFX_spawner/_node_VFX_spawner.gml b/scripts/_node_VFX_spawner/_node_VFX_spawner.gml index 634456df6..7bb1a02e5 100644 --- a/scripts/_node_VFX_spawner/_node_VFX_spawner.gml +++ b/scripts/_node_VFX_spawner/_node_VFX_spawner.gml @@ -43,7 +43,7 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co inputs[19] = nodeValue_Range("Gravity", self, [ 0, 0 ] , { linked : true }); - inputs[20] = nodeValue_Vector("Direction wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); + inputs[20] = nodeValue_Vec2("Direction wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); inputs[21] = nodeValue_Bool("Loop", self, true ); @@ -95,11 +95,11 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co inputs[40] = nodeValue_Float("Bounce friction", self, 0.1, "Apply horizontal friction once particle stop bouncing." ) .setDisplay(VALUE_DISPLAY.slider); - inputs[41] = nodeValue_Vector("Position wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); + inputs[41] = nodeValue_Vec2("Position wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); - inputs[42] = nodeValue_Vector("Rotation wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); + inputs[42] = nodeValue_Vec2("Rotation wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); - inputs[43] = nodeValue_Vector("Scale wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); + inputs[43] = nodeValue_Vec2("Scale wiggle", self, [ 0, 0 ] , { label: [ "Amplitude", "Period" ], linkable: false, per_line: true }); inputs[44] = nodeValue_Trigger("Spawn", self, false ) .setDisplay(VALUE_DISPLAY.button, { name: "Trigger" }); @@ -164,7 +164,7 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co for( var i = 0; i < attributes.part_amount; i++ ) parts[i] = new __part(self); - static spawn = function(_time = CURRENT_FRAME, _pos = -1) { #region + static spawn = function(_time = CURRENT_FRAME, _pos = -1) { var _inSurf = getInputData( 0); var _spawn_amount = getInputData( 2); @@ -306,13 +306,13 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co parts_runner = safe_mod(parts_runner + 1, attributes.part_amount); } - } #endregion + } static onSpawn = function(_time, part) {} static updateParticleForward = function() {} - static getSurfaceCache = function() { #region + static getSurfaceCache = function() { var surfs = getInputData(0); if(array_empty(surfs)) return; @@ -333,9 +333,9 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co surface_cache[$ surfs[i]] = surface_clone(_s); } - } #endregion + } - function reset() { #region + function reset() { getInputs(0); var keys = variable_struct_get_names(surface_cache); @@ -377,13 +377,13 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co #endregion render(); - } #endregion + } - static resetSeed = function() { #region + static resetSeed = function() { seed = getInputData(32); - } #endregion + } - function checkPartPool() { #region + function checkPartPool() { var _part_amo = attributes.part_amount; var _curr_amo = array_length(parts); @@ -393,9 +393,9 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co } else if(_part_amo < _curr_amo) { array_resize(parts, _part_amo); } - } #endregion + } - static runVFX = function(_time = CURRENT_FRAME, _render = true) { #region + static runVFX = function(_time = CURRENT_FRAME, _render = true) { var _spawn_delay = inputs[1].getValue(_time); var _spawn_type = inputs[16].getValue(_time); var _spawn_active = inputs[27].getValue(_time); @@ -425,11 +425,11 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co if(!_render) return; render(_time); - } #endregion + } static onStep = function() {} - static step = function() { #region + static step = function() { var _inSurf = getInputData(0); var _dist = getInputData(4); var _scatt = getInputData(24); @@ -471,9 +471,9 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co } onStep(); - } #endregion + } - static drawOverlay = function(hover, active, _x, _y, _s, _mx, _my, _snx, _sny) { #region + static drawOverlay = function(hover, active, _x, _y, _s, _mx, _my, _snx, _sny) { var _spr = getInputData(0); if(array_empty(_spr)) return; if(is_array(_spr)) @@ -484,17 +484,17 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co inputs[3].drawOverlay(hover, active, _x, _y, _s, _mx, _my, _snx, _sny, _flag); if(onDrawOverlay != -1) onDrawOverlay(active, _x, _y, _s, _mx, _my); - } #endregion + } static onDrawOverlay = -1; - static update = function(frame = CURRENT_FRAME) { #region + static update = function(frame = CURRENT_FRAME) { var _resetSeed = getInputData(48); if(_resetSeed) resetSeed(); checkPartPool(); onUpdate(frame); - } #endregion + } static onUpdate = function(frame = CURRENT_FRAME) {} @@ -504,14 +504,14 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co static onPartStep = noone; static onPartDestroy = noone; - static doSerialize = function(_map) { #region + static doSerialize = function(_map) { _map.part_base_length = input_len; - } #endregion + } - static postDeserialize = function() { #region + static postDeserialize = function() { var _tlen = struct_try_get(load_map, "part_base_length", 40); for( var i = _tlen; i < input_len; i++ ) array_insert(load_map.inputs, i, noone); - } #endregion + } } \ No newline at end of file diff --git a/scripts/_node_strand_affector/_node_strand_affector.gml b/scripts/_node_strand_affector/_node_strand_affector.gml index 6f1389436..704d8b38a 100644 --- a/scripts/_node_strand_affector/_node_strand_affector.gml +++ b/scripts/_node_strand_affector/_node_strand_affector.gml @@ -45,7 +45,7 @@ function _Node_Strand_Affector(_x, _y, _group = noone) : Node(_x, _y, _group) co inputs[1] = nodeValue_Enum_Scroll("Shape", self, 0, [ "Point", "Band" ]); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0 ]); inputs[3] = nodeValue_Float("Range", self, 4); diff --git a/scripts/dialog_management/dialog_management.gml b/scripts/dialog_management/dialog_management.gml index b15ba03f0..748ac1670 100644 --- a/scripts/dialog_management/dialog_management.gml +++ b/scripts/dialog_management/dialog_management.gml @@ -2,7 +2,7 @@ function dialogCall(_dia, _x = noone, _y = noone, param = {}, create = false) { if(_x == noone) _x = WIN_SW / 2; if(_y == noone) _y = WIN_SH / 2; - var dia = !create && instance_exists(_dia)? instance_find(_dia, 0) : instance_create_depth(_x, _y, 0, _dia, param); + var dia = (!create && instance_exists(_dia))? instance_find(_dia, 0) : instance_create_depth(_x, _y, 0, _dia, param); dia.x = _x; dia.y = _y; diff --git a/scripts/function_register/function_register.gml b/scripts/function_register/function_register.gml index 1d638c1db..6bde8f40c 100644 --- a/scripts/function_register/function_register.gml +++ b/scripts/function_register/function_register.gml @@ -56,6 +56,14 @@ function functionObject(_context, _name, _key, _mod, _action) constructor { return self; } + static setMenuAlt = function(_name, _id, _spr = noone, shelf = false) { + menu = menuItemAction(__txt(_name), action, _spr); + if(shelf) menu.setIsShelf(); + MENU_ITEMS[$ _id] = menu; + + return self; + } + static setMenu = function(_id, _spr = noone, shelf = false) { menu = menuItemAction(__txt(name), action, _spr); if(shelf) menu.setIsShelf(); diff --git a/scripts/globals/globals.gml b/scripts/globals/globals.gml index 5fb9bc713..41af05d05 100644 --- a/scripts/globals/globals.gml +++ b/scripts/globals/globals.gml @@ -39,7 +39,7 @@ LATEST_VERSION = 11700; VERSION = 11790; SAVE_VERSION = 11700; - VERSION_STRING = "1.17.10.004"; + VERSION_STRING = "1.17.10.005"; BUILD_NUMBER = 11790; HOTKEYS = ds_map_create(); diff --git a/scripts/globalvar_drawer/globalvar_drawer.gml b/scripts/globalvar_drawer/globalvar_drawer.gml index 5f0da1b9e..9630d22b4 100644 --- a/scripts/globalvar_drawer/globalvar_drawer.gml +++ b/scripts/globalvar_drawer/globalvar_drawer.gml @@ -14,6 +14,7 @@ function globalvar_viewer_draw(xx, yy, ww, _m, focus, hover, _scrollPane, rx, ry var chov = false; var _node = PROJECT.globalNode; + var _font = viewMode == INSP_VIEW_MODE.spacious? f_p0 : f_p2; if(var_editing) { var del = noone; @@ -29,35 +30,38 @@ function globalvar_viewer_draw(xx, yy, ww, _m, focus, hover, _scrollPane, rx, ry var _ins = var_drag_insert; var_drag_insert = _len; - var _hov = hover && (var_dragging == noone); - var _foc = focus && (var_dragging == noone); + var _hov = hover && (var_dragging == noone); + var _foc = focus && (var_dragging == noone); + var _wd_h = viewMode == INSP_VIEW_MODE.spacious? ui(32) : ui(24); + var _pd_h = viewMode == INSP_VIEW_MODE.spacious? ui(4) : ui(2) + var _dgs = ui(24); + var _dgh = _dgs / 2; - var_drag_shift = lerp_float(var_drag_shift, (var_dragging != noone) * 48, 4); + var_drag_shift = lerp_float(var_drag_shift, (var_dragging != noone) * -16, 4); for( var j = 0; j < _len; j++ ) { var _inpu = _node.inputs[j]; var _edit = _inpu.editor; - var _wd_x = wd_x + (var_drag_disp == j) * var_drag_shift; - var wd_h = ui(32); if(var_dragging != noone && _m[1] < yy && var_drag_insert == _len) - var_drag_insert = j > var_dragging? j : j - 1; + var_drag_insert = max(0, j > var_dragging? j : j - 1); 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); + // 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, 2); + + yy += _pd_h; + hh += _pd_h; } if(var_dragging == noone) { 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))) { + var by = yy + _wd_h / 2; + + if(hover && point_in_rectangle(_m[0], _m[1], bx - _dgh, by - _dgh, bx + _dgh, by + _dgh)) { chov = true; - draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, bx - ui(12), by - ui(12), ui(24), ui(24), COLORS._main_icon_light, 1); + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, bx - _dgh, by - _dgh, _dgs, _dgs, COLORS._main_icon_light, 1); if(mouse_press(mb_left, _foc)) { var_drag_disp = j; @@ -65,33 +69,38 @@ function globalvar_viewer_draw(xx, yy, ww, _m, focus, hover, _scrollPane, rx, ry var_drag_insert = j; } } else - draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, bx - ui(12), by - ui(12), ui(24), ui(24), COLORS._main_icon_light, 0.75); + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, bx - _dgh, by - _dgh, _dgs, _dgs, 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(_foc, _hov); - _edit.sc_type.setFocusHover(_foc, _hov); - _edit.sc_disp.setFocusHover(_foc, _hov); + + _edit.tb_name.setFocusHover(_foc, _hov); _edit.tb_name.font = _font; + _edit.sc_type.setFocusHover(_foc, _hov); _edit.sc_type.font = _font; + _edit.sc_disp.setFocusHover(_foc, _hov); _edit.sc_disp.font = _font; if(_foc) _edit.tb_name.register(_scrollPane); - _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, _foc, _hov,, THEME.icon_delete,, COLORS._main_value_negative) == 2) + var _wd_xx = _wd_x + ui(32); + var _wd_ww = wd_w - _wd_h - ui(32 + 4); + + _edit.tb_name.draw(_wd_xx, yy, _wd_ww, _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, _foc, _hov,, THEME.icon_delete,, COLORS._main_value_negative) == 2) del = j; - yy += wd_h + ui(8); - hh += wd_h + ui(8); + yy += _wd_h + _pd_h * 2; + hh += _wd_h + _pd_h * 2; + + var _wd_ww = (wd_w - ui(32)) / 2 - ui(2); + + _edit.sc_type.draw(_wd_xx, yy, _wd_ww, _wd_h, _edit.val_type_name[_edit.type_index], _m, rx, ry); + _edit.sc_disp.draw(_wd_xx + _wd_ww + ui(4), yy, _wd_ww, _wd_h, _edit.sc_disp.data_list[_edit.disp_index], _m, rx, ry); - _edit.sc_type.draw(_wd_x, yy, wd_w / 2 - ui(2), wd_h, _edit.val_type_name[_edit.type_index], _m, rx, ry); - _edit.sc_disp.draw(_wd_x + wd_w / 2 + ui(2), yy, wd_w / 2 - ui(2), wd_h, _edit.sc_disp.data_list[_edit.disp_index], _m, rx, ry); + yy += _wd_h + _pd_h; + hh += _wd_h + _pd_h; - yy += wd_h + ui(4); - hh += wd_h + ui(4); + var wdh = _inpu.editor.draw(_wd_x, yy, wd_w, _m, _foc, _hov); - var wd_h = _inpu.editor.draw(_wd_x, yy, wd_w, _m, _foc, _hov); - - yy += wd_h + ui(4); - hh += wd_h + ui(4); + yy += wdh + _pd_h; + hh += wdh + _pd_h; } if(var_dragging != noone) { diff --git a/scripts/hotkey_data/hotkey_data.gml b/scripts/hotkey_data/hotkey_data.gml index bcb9ba14f..82ad644c6 100644 --- a/scripts/hotkey_data/hotkey_data.gml +++ b/scripts/hotkey_data/hotkey_data.gml @@ -3,74 +3,74 @@ globalvar HOTKEYS_CUSTOM; function __initHotKey() { HOTKEYS_CUSTOM = { "Node_Canvas": { - "Selection": new hotkeySimple("S"), - "Magic Selection": new hotkeySimple("W"), - "Pencil": new hotkeySimple("B"), - "Eraser": new hotkeySimple("E"), - "Rectangle": new hotkeySimple("N"), - "Ellipse": new hotkeySimple("M"), - "Iso Cube": new hotkeySimple(""), - "Curve": new hotkeySimple(""), - "Freeform": new hotkeySimple("Q"), - "Fill": new hotkeySimple("G"), + "Selection": new hotkeySimple("S"), + "Magic Selection": new hotkeySimple("W"), + "Pencil": new hotkeySimple("B"), + "Eraser": new hotkeySimple("E"), + "Rectangle": new hotkeySimple("N"), + "Ellipse": new hotkeySimple("M"), + "Iso Cube": new hotkeySimple(""), + "Curve": new hotkeySimple(""), + "Freeform": new hotkeySimple("Q"), + "Fill": new hotkeySimple("G"), - "Outline": new hotkeySimple("O", MOD_KEY.alt), - "Extrude": new hotkeySimple("E", MOD_KEY.alt), - "Inset": new hotkeySimple("I", MOD_KEY.alt), - "Skew": new hotkeySimple("S", MOD_KEY.alt), - "Corner": new hotkeySimple("C", MOD_KEY.alt), + "Outline": new hotkeySimple("O", MOD_KEY.alt), + "Extrude": new hotkeySimple("E", MOD_KEY.alt), + "Inset": new hotkeySimple("I", MOD_KEY.alt), + "Skew": new hotkeySimple("S", MOD_KEY.alt), + "Corner": new hotkeySimple("C", MOD_KEY.alt), }, "Node_Mesh_Warp": { - "Edit control point": new hotkeySimple("V"), - "Pin mesh": new hotkeySimple("P"), - "Mesh edit": new hotkeySimple("M"), - "Anchor remove": new hotkeySimple("E"), + "Edit control point": new hotkeySimple("V"), + "Pin mesh": new hotkeySimple("P"), + "Mesh edit": new hotkeySimple("M"), + "Anchor remove": new hotkeySimple("E"), }, "Node_Armature": { - "Move": new hotkeySimple("V"), - "Scale": new hotkeySimple("S"), - "Add bones": new hotkeySimple("A"), - "Remove bones": new hotkeySimple("E"), - "Detach bones": new hotkeySimple("D"), - "IK": new hotkeySimple("K"), + "Move": new hotkeySimple("V"), + "Scale": new hotkeySimple("S"), + "Add bones": new hotkeySimple("A"), + "Remove bones": new hotkeySimple("E"), + "Detach bones": new hotkeySimple("D"), + "IK": new hotkeySimple("K"), }, "Node_Path": { - "Transform": new hotkeySimple("T"), - "Anchor add / remove": new hotkeySimple("A"), - "Edit Control point": new hotkeySimple("C"), - "Draw path": new hotkeySimple("B"), - "Rectangle path": new hotkeySimple("N"), - "Circle path": new hotkeySimple("M"), + "Transform": new hotkeySimple("T"), + "Anchor add / remove": new hotkeySimple("A"), + "Edit Control point": new hotkeySimple("C"), + "Draw path": new hotkeySimple("B"), + "Rectangle path": new hotkeySimple("N"), + "Circle path": new hotkeySimple("M"), }, "Node_Rigid_Object": { - "Mesh edit": new hotkeySimple("A"), - "Anchor remove": new hotkeySimple("E"), + "Mesh edit": new hotkeySimple("A"), + "Anchor remove": new hotkeySimple("E"), }, "Node_Strand_Create": { - "Push": new hotkeySimple("P"), - "Comb": new hotkeySimple("C"), - "Stretch": new hotkeySimple("S"), - "Shorten": new hotkeySimple("D"), - "Grab": new hotkeySimple("G"), + "Push": new hotkeySimple("P"), + "Comb": new hotkeySimple("C"), + "Stretch": new hotkeySimple("S"), + "Shorten": new hotkeySimple("D"), + "Grab": new hotkeySimple("G"), }, "Node_Path_Anchor": { - "Adjust control point": new hotkeySimple("A"), + "Adjust control point": new hotkeySimple("A"), }, "Node_3D_Object": { - "Transform": new hotkeySimple("G"), - "Rotate": new hotkeySimple("R"), - "Scale": new hotkeySimple("S"), + "Transform": new hotkeySimple("G"), + "Rotate": new hotkeySimple("R"), + "Scale": new hotkeySimple("S"), }, "Node_3D_Camera": { - "Move Target": new hotkeySimple("T"), + "Move Target": new hotkeySimple("T"), }, }; @@ -122,8 +122,10 @@ function hotkeyObject(_context, _name, _key, _mod = MOD_KEY.none, _action = noon modi = is_struct(ll)? ll.modi : ll[3]; } + static full_name = function() { return string_to_var(context == ""? $"global.{name}" : $"{context}.{name}"); } + var _loadKey = $"{context}_{name}"; - if(struct_has(HOTKEYS_DATA, _loadKey)) + if(struct_has(HOTKEYS_DATA, _loadKey)) deserialize(HOTKEYS_DATA[$ _loadKey]); } diff --git a/scripts/load_function/load_function.gml b/scripts/load_function/load_function.gml index 599941114..3e467191d 100644 --- a/scripts/load_function/load_function.gml +++ b/scripts/load_function/load_function.gml @@ -71,7 +71,7 @@ function LOAD_PATH(path, readonly = false, safe_mode = false) { PROJECT.safeMode = safe_mode; if(!IS_CMD) setFocus(PANEL_GRAPH.panel); - if(PROJECT.meta.file_id) PROJECT.meta.steam = FILE_STEAM_TYPE.steamOpen; + if(PROJECT.meta.author_steam_id) PROJECT.meta.steam = FILE_STEAM_TYPE.steamOpen; return PROJECT; } diff --git a/scripts/meta_data/meta_data.gml b/scripts/meta_data/meta_data.gml index 276e0750a..854536bbf 100644 --- a/scripts/meta_data/meta_data.gml +++ b/scripts/meta_data/meta_data.gml @@ -22,6 +22,7 @@ function MetaDataManager() constructor { contact = ""; alias = ""; type = FILE_TYPE.collection; + author_steam_id = 0; file_id = 0; tags = []; diff --git a/scripts/node_2d_light/node_2d_light.gml b/scripts/node_2d_light/node_2d_light.gml index 8773d98f4..dc575eae4 100644 --- a/scripts/node_2d_light/node_2d_light.gml +++ b/scripts/node_2d_light/node_2d_light.gml @@ -22,7 +22,7 @@ function Node_2D_light(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) new scrollItem("Line asymmetric", s_node_2d_light_shape, 2), new scrollItem("Spot", s_node_2d_light_shape, 3), ]); - inputs[2] = nodeValue_Vector("Center", self, [ 16, 16 ]) + inputs[2] = nodeValue_Vec2("Center", self, [ 16, 16 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[3] = nodeValue_Float("Range", self, 16); @@ -32,9 +32,9 @@ function Node_2D_light(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[5] = nodeValue_Color("Color", self, c_white); - inputs[6] = nodeValue_Vector("Start", self, [ 16, 16 ]); + inputs[6] = nodeValue_Vec2("Start", self, [ 16, 16 ]); - inputs[7] = nodeValue_Vector("Finish", self, [ 32, 16 ]); + inputs[7] = nodeValue_Vec2("Finish", self, [ 32, 16 ]); inputs[8] = nodeValue_Int("Sweep", self, 15) .setDisplay(VALUE_DISPLAY.slider, { range: [-80, 80, 0.1] }); diff --git a/scripts/node_3d_camera/node_3d_camera.gml b/scripts/node_3d_camera/node_3d_camera.gml index d34500f2e..8e0514492 100644 --- a/scripts/node_3d_camera/node_3d_camera.gml +++ b/scripts/node_3d_camera/node_3d_camera.gml @@ -21,7 +21,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group) inputs[in_d3d + 0] = nodeValue_Int("FOV", self, 60 ) .setDisplay(VALUE_DISPLAY.slider, { range: [ 10, 90, 0.1 ] }); - inputs[in_d3d + 1] = nodeValue_Vector("Clipping Distance", self, [ 1, 10 ] ); + inputs[in_d3d + 1] = nodeValue_Vec2("Clipping Distance", self, [ 1, 10 ] ); inputs[in_d3d + 2] = nodeValue_Dimension(self); @@ -41,7 +41,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group) inputs[in_d3d + 9] = nodeValue_Enum_Scroll("Postioning Mode", self, 2, [ "Position + Rotation", "Position + Lookat", "Lookat + Rotation" ] ); - inputs[in_d3d + 10] = nodeValue_Vector("Lookat Position", self, [ 0, 0, 0 ] ); + inputs[in_d3d + 10] = nodeValue_Vec3("Lookat Position", self, [ 0, 0, 0 ] ); inputs[in_d3d + 11] = nodeValue_Rotation("Roll", self, 0); diff --git a/scripts/node_3d_depth/node_3d_depth.gml b/scripts/node_3d_depth/node_3d_depth.gml index e29608d1f..1a6b0c0cf 100644 --- a/scripts/node_3d_depth/node_3d_depth.gml +++ b/scripts/node_3d_depth/node_3d_depth.gml @@ -5,7 +5,7 @@ function Node_3D_Depth(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Surface("Depth", self); - inputs[2] = nodeValue_Vector("Rotation", self, [0, 0, 0] ); + inputs[2] = nodeValue_Vec3("Rotation", self, [0, 0, 0] ); outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_3d_instancer/node_3d_instancer.gml b/scripts/node_3d_instancer/node_3d_instancer.gml index d49883d23..7c240f866 100644 --- a/scripts/node_3d_instancer/node_3d_instancer.gml +++ b/scripts/node_3d_instancer/node_3d_instancer.gml @@ -3,7 +3,7 @@ function Node_3D_Instancer(_x, _y, _group = noone) : Node_3D_Modifier(_x, _y, _g inputs[in_mesh + 0] = nodeValue_Int("Amounts", self, 1); - inputs[in_mesh + 1] = nodeValue_Vector("Positions", self, [ 0, 0, 0 ]) + inputs[in_mesh + 1] = nodeValue_Vec3("Positions", self, [ 0, 0, 0 ]) .setArrayDepth(1); static processData = function(_output, _data, _output_index, _array_index = 0) { diff --git a/scripts/node_3d_mesh_path_extrude/node_3d_mesh_path_extrude.gml b/scripts/node_3d_mesh_path_extrude/node_3d_mesh_path_extrude.gml index 719a02842..416cef53b 100644 --- a/scripts/node_3d_mesh_path_extrude/node_3d_mesh_path_extrude.gml +++ b/scripts/node_3d_mesh_path_extrude/node_3d_mesh_path_extrude.gml @@ -27,7 +27,7 @@ function Node_3D_Mesh_Path_Extrude(_x, _y, _group = noone) : Node_3D_Mesh(_x, _y inputs[in_mesh + 8] = nodeValue("Radius Over Path", self, JUNCTION_CONNECT.input, VALUE_TYPE.curve, CURVE_DEF_11 ); - inputs[in_mesh + 9] = nodeValue_Vector("Texture Scale", self, [ 1, 1 ] ); + inputs[in_mesh + 9] = nodeValue_Vec2("Texture Scale", self, [ 1, 1 ] ); inputs[in_mesh + 10] = nodeValue_Bool("Loop", self, false ); diff --git a/scripts/node_3d_mesh_stack_slice/node_3d_mesh_stack_slice.gml b/scripts/node_3d_mesh_stack_slice/node_3d_mesh_stack_slice.gml index edd85e4c5..4ce79c35b 100644 --- a/scripts/node_3d_mesh_stack_slice/node_3d_mesh_stack_slice.gml +++ b/scripts/node_3d_mesh_stack_slice/node_3d_mesh_stack_slice.gml @@ -4,13 +4,13 @@ function Node_3D_Mesh_Stack_Slice(_x, _y, _group = noone) : Node(_x, _y, _group) inputs[0] = nodeValue_D3Mesh("Mesh", self, noone) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Output Dimension", self, [ 16, 16 ]); + inputs[1] = nodeValue_Vec2("Output Dimension", self, [ 16, 16 ]); inputs[2] = nodeValue_Float("Scale", self, 1); inputs[3] = nodeValue_Int("Slices", self, 4); - inputs[4] = nodeValue_Vector("BBOX Padding", self, [ 0, 0, 0 ]); + inputs[4] = nodeValue_Vec3("BBOX Padding", self, [ 0, 0, 0 ]); outputs[0] = nodeValue_Output("Outputs", self, VALUE_TYPE.surface, []) .setArrayDepth(1); diff --git a/scripts/node_3d_point_affector/node_3d_point_affector.gml b/scripts/node_3d_point_affector/node_3d_point_affector.gml index 6346714e4..156ece34e 100644 --- a/scripts/node_3d_point_affector/node_3d_point_affector.gml +++ b/scripts/node_3d_point_affector/node_3d_point_affector.gml @@ -5,12 +5,12 @@ function Node_3D_Point_Affector(_x, _y, _group = noone) : Node_3D_Object(_x, _y, gizmo_plane = [ new __3dGizmoPlaneFalloff(,, 0.75) ]; gizmo_object = noone; - inputs[in_d3d + 0] = nodeValue_Vector("Points", self, [ 0, 0, 0 ]) + inputs[in_d3d + 0] = nodeValue_Vec3("Points", self, [ 0, 0, 0 ]) .setVisible(true, true); - inputs[in_d3d + 1] = nodeValue_Vector("Initial value", self, [ 0, 0, 0 ]); + inputs[in_d3d + 1] = nodeValue_Vec3("Initial value", self, [ 0, 0, 0 ]); - inputs[in_d3d + 2] = nodeValue_Vector("Final value", self, [ 0, 0, 0 ]); + inputs[in_d3d + 2] = nodeValue_Vec3("Final value", self, [ 0, 0, 0 ]); inputs[in_d3d + 3] = nodeValue_Float("Falloff distance", self, 0.5); diff --git a/scripts/node_3d_repeat/node_3d_repeat.gml b/scripts/node_3d_repeat/node_3d_repeat.gml index f77dd6d82..47f35a703 100644 --- a/scripts/node_3d_repeat/node_3d_repeat.gml +++ b/scripts/node_3d_repeat/node_3d_repeat.gml @@ -10,17 +10,17 @@ function Node_3D_Repeat(_x, _y, _group = noone) : Node_3D(_x, _y, _group) constr inputs[2] = nodeValue_Int("Amount", self, 1 ); - inputs[3] = nodeValue_Vector("Starting Position", self, [ 0, 0, 0 ] ); + inputs[3] = nodeValue_Vec3("Starting Position", self, [ 0, 0, 0 ] ); inputs[4] = nodeValue_Quaternion("Starting Rotation", self, [ 0, 0, 0, 1 ] ); - inputs[5] = nodeValue_Vector("Starting Scale", self, [ 1, 1, 1 ] ); + inputs[5] = nodeValue_Vec3("Starting Scale", self, [ 1, 1, 1 ] ); - inputs[6] = nodeValue_Vector("Shift Position", self, [ 0, 0, 0 ] ); + inputs[6] = nodeValue_Vec3("Shift Position", self, [ 0, 0, 0 ] ); inputs[7] = nodeValue_Quaternion("Shift Rotation", self, [ 0, 0, 0, 1 ] ); - inputs[8] = nodeValue_Vector("Shift Scale", self, [ 0, 0, 0 ] ); + inputs[8] = nodeValue_Vec3("Shift Scale", self, [ 0, 0, 0 ] ); inputs[9] = nodeValue_Float("Positions", self, [] ) .setArrayDepth(2); diff --git a/scripts/node_3dsurf/node_3dsurf.gml b/scripts/node_3dsurf/node_3dsurf.gml index 03304452d..0941b81df 100644 --- a/scripts/node_3dsurf/node_3dsurf.gml +++ b/scripts/node_3dsurf/node_3dsurf.gml @@ -6,7 +6,7 @@ function Node_3DSurf(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[0] = nodeValue_D3Scene("Scene", self, noone) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Base Dimension", self, DEF_SURF); + inputs[1] = nodeValue_Vec2("Base Dimension", self, DEF_SURF); inputs[2] = nodeValue_Float("Vertical Angle", self, 45 ) .setDisplay(VALUE_DISPLAY.slider, { range: [0, 90, 0.1] }); diff --git a/scripts/node_FLIP_apply_force/node_FLIP_apply_force.gml b/scripts/node_FLIP_apply_force/node_FLIP_apply_force.gml index 7b1d790da..01156f835 100644 --- a/scripts/node_FLIP_apply_force/node_FLIP_apply_force.gml +++ b/scripts/node_FLIP_apply_force/node_FLIP_apply_force.gml @@ -25,7 +25,7 @@ function Node_FLIP_Apply_Force(_x, _y, _group = noone) : Node(_x, _y, _group) co inputs[0] = nodeValue_Fdomain("Domain", self, noone ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(); }); inputs[2] = nodeValue_Float("Radius", self, 4 ) @@ -33,7 +33,7 @@ function Node_FLIP_Apply_Force(_x, _y, _group = noone) : Node(_x, _y, _group) co inputs[3] = nodeValue_Enum_Scroll("Shape", self, 0 , [ new scrollItem("Circle", s_node_shape_circle, 0), new scrollItem("Rectangle", s_node_shape_rectangle, 0), ]); - inputs[4] = nodeValue_Vector("Size", self, [ 4, 4 ] ); + inputs[4] = nodeValue_Vec2("Size", self, [ 4, 4 ] ); inputs[5] = nodeValue_Surface("Texture", self) diff --git a/scripts/node_FLIP_apply_velocity/node_FLIP_apply_velocity.gml b/scripts/node_FLIP_apply_velocity/node_FLIP_apply_velocity.gml index 2670bb32a..65d459ac3 100644 --- a/scripts/node_FLIP_apply_velocity/node_FLIP_apply_velocity.gml +++ b/scripts/node_FLIP_apply_velocity/node_FLIP_apply_velocity.gml @@ -9,17 +9,17 @@ function Node_FLIP_Apply_Velocity(_x, _y, _group = noone) : Node(_x, _y, _group) inputs[0] = nodeValue_Fdomain("Domain", self, noone ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(); }); inputs[2] = nodeValue_Float("Radius", self, 4 ) .setDisplay(VALUE_DISPLAY.slider, { range: [1, 16, 0.1] }); - inputs[3] = nodeValue_Vector("Velocity", self, [ 0, 0 ] ); + inputs[3] = nodeValue_Vec2("Velocity", self, [ 0, 0 ] ); inputs[4] = nodeValue_Enum_Scroll("Shape", self, 0 , [ new scrollItem("Circle", s_node_shape_circle, 0), new scrollItem("Rectangle", s_node_shape_rectangle, 0) ]); - inputs[5] = nodeValue_Vector("Size", self, [ 4, 4 ] ); + inputs[5] = nodeValue_Vec2("Size", self, [ 4, 4 ] ); input_display_list = [ 0, ["Velocity", false], 4, 1, 2, 5, 3, diff --git a/scripts/node_FLIP_destroy/node_FLIP_destroy.gml b/scripts/node_FLIP_destroy/node_FLIP_destroy.gml index 9dc1181c6..b87448c27 100644 --- a/scripts/node_FLIP_destroy/node_FLIP_destroy.gml +++ b/scripts/node_FLIP_destroy/node_FLIP_destroy.gml @@ -9,7 +9,7 @@ function Node_FLIP_Destroy(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[0] = nodeValue_Fdomain("Domain", self, noone ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(); }); inputs[2] = nodeValue_Enum_Scroll("Shape", self, 0 , [ new scrollItem("Circle", s_node_shape_circle, 0), new scrollItem("Rectangle", s_node_shape_rectangle, 0), ]); @@ -17,7 +17,7 @@ function Node_FLIP_Destroy(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[3] = nodeValue_Float("Radius", self, 4 ) .setDisplay(VALUE_DISPLAY.slider, { range: [1, 16, 0.1] }); - inputs[4] = nodeValue_Vector("Size", self, [ 4, 4 ] ); + inputs[4] = nodeValue_Vec2("Size", self, [ 4, 4 ] ); inputs[5] = nodeValue_Float("Ratio", self, 1 ) .setDisplay(VALUE_DISPLAY.slider); diff --git a/scripts/node_FLIP_repel/node_FLIP_repel.gml b/scripts/node_FLIP_repel/node_FLIP_repel.gml index e8488da83..a1ad1829a 100644 --- a/scripts/node_FLIP_repel/node_FLIP_repel.gml +++ b/scripts/node_FLIP_repel/node_FLIP_repel.gml @@ -9,7 +9,7 @@ function Node_FLIP_Repel(_x, _y, _group = noone) : Node(_x, _y, _group) construc inputs[0] = nodeValue_Fdomain("Domain", self, noone ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(); }); inputs[2] = nodeValue_Float("Radius", self, 4 ); diff --git a/scripts/node_FLIP_spawner/node_FLIP_spawner.gml b/scripts/node_FLIP_spawner/node_FLIP_spawner.gml index 932179c56..6eb5f8489 100644 --- a/scripts/node_FLIP_spawner/node_FLIP_spawner.gml +++ b/scripts/node_FLIP_spawner/node_FLIP_spawner.gml @@ -11,7 +11,7 @@ function Node_FLIP_Spawner(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[1] = nodeValue_Enum_Scroll("Spawn Shape", self, 0 , [ new scrollItem("Circle", s_node_shape_circle, 0), new scrollItem("Rectangle", s_node_shape_rectangle, 0), "Surface" ]); - inputs[2] = nodeValue_Vector("Spawn Position", self, [ 0.5, 0.25 ] ) + inputs[2] = nodeValue_Vec2("Spawn Position", self, [ 0.5, 0.25 ] ) .setUnitRef(function(index) { return getDimension(); }, VALUE_UNIT.reference); inputs[3] = nodeValue_Enum_Button("Spawn Type", self, 0 , [ "Stream", "Splash" ]); @@ -37,7 +37,7 @@ function Node_FLIP_Spawner(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[12] = nodeValue_Int("Spawn Duration", self, 1 ); - inputs[13] = nodeValue_Vector("Spawn Szie", self, [ 2, 2 ] ); + inputs[13] = nodeValue_Vec2("Spawn Szie", self, [ 2, 2 ] ); input_display_list = [ 0, 9, ["Spawner", false], 1, 7, 8, 13, 2, 3, 4, 12, 5, diff --git a/scripts/node_FLIP_vortex/node_FLIP_vortex.gml b/scripts/node_FLIP_vortex/node_FLIP_vortex.gml index 5846c4327..4553b09ce 100644 --- a/scripts/node_FLIP_vortex/node_FLIP_vortex.gml +++ b/scripts/node_FLIP_vortex/node_FLIP_vortex.gml @@ -9,7 +9,7 @@ function Node_FLIP_Vortex(_x, _y, _group = noone) : Node(_x, _y, _group) constru inputs[0] = nodeValue_Fdomain("Domain", self, noone ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(); }); inputs[2] = nodeValue_Float("Radius", self, 4 ); diff --git a/scripts/node_VFX_renderer/node_VFX_renderer.gml b/scripts/node_VFX_renderer/node_VFX_renderer.gml index 2b971aa1b..877bd7e8c 100644 --- a/scripts/node_VFX_renderer/node_VFX_renderer.gml +++ b/scripts/node_VFX_renderer/node_VFX_renderer.gml @@ -6,7 +6,7 @@ function Node_VFX_Renderer(_x, _y, _group = noone) : Node(_x, _y, _group) constr manual_ungroupable = false; - inputs[0] = nodeValue_Vector("Output dimension", self, DEF_SURF ); + inputs[0] = nodeValue_Vec2("Output dimension", self, DEF_SURF ); inputs[1] = nodeValue_Bool("Round position", self, true, "Round position to the closest integer value to avoid jittering.") .rejectArray(); diff --git a/scripts/node_VFX_renderer_output/node_VFX_renderer_output.gml b/scripts/node_VFX_renderer_output/node_VFX_renderer_output.gml index 36e1762e9..fdc34b120 100644 --- a/scripts/node_VFX_renderer_output/node_VFX_renderer_output.gml +++ b/scripts/node_VFX_renderer_output/node_VFX_renderer_output.gml @@ -7,7 +7,7 @@ function Node_VFX_Renderer_Output(_x, _y, _group = noone) : Node_Group_Output(_x manual_ungroupable = false; previewable = true; - inputs[0] = nodeValue_Vector("Output dimension", self, DEF_SURF); + inputs[0] = nodeValue_Vec2("Output dimension", self, DEF_SURF); inputs[1] = nodeValue_Bool("Round position", self, true, "Round position to the closest integer value to avoid jittering.") .rejectArray(); diff --git a/scripts/node_VFX_triangulate/node_VFX_triangulate.gml b/scripts/node_VFX_triangulate/node_VFX_triangulate.gml index defd76e6d..3133f66ec 100644 --- a/scripts/node_VFX_triangulate/node_VFX_triangulate.gml +++ b/scripts/node_VFX_triangulate/node_VFX_triangulate.gml @@ -14,7 +14,7 @@ function Node_VFX_Triangulate(_x, _y, _group = noone) : Node(_x, _y, _group) con manual_ungroupable = false; - inputs[0] = nodeValue_Vector("Output dimension", self, DEF_SURF ); + inputs[0] = nodeValue_Vec2("Output dimension", self, DEF_SURF ); inputs[1] = nodeValue_Particle("Particles", self, -1 ) .setVisible(true, true); diff --git a/scripts/node_active_canvas/node_active_canvas.gml b/scripts/node_active_canvas/node_active_canvas.gml index acd48e1ab..e5d64860a 100644 --- a/scripts/node_active_canvas/node_active_canvas.gml +++ b/scripts/node_active_canvas/node_active_canvas.gml @@ -5,11 +5,11 @@ function Node_Active_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) const inputs[1] = nodeValue_Surface("Texture", self); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0 ] ); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0 ] ); inputs[3] = nodeValue_Rotation("Rotation", self, 0); - inputs[4] = nodeValue_Vector("Scale", self, [ 1, 1 ] ); + inputs[4] = nodeValue_Vec2("Scale", self, [ 1, 1 ] ); inputs[5] = nodeValue_Color("Color", self, c_white ); diff --git a/scripts/node_area/node_area.gml b/scripts/node_area/node_area.gml index b8f2cd382..f9b1aa9b5 100644 --- a/scripts/node_area/node_area.gml +++ b/scripts/node_area/node_area.gml @@ -3,10 +3,10 @@ function Node_Area(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons color = COLORS.node_blend_number; setDimension(96, 48); - inputs[0] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[0] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Span", self, [ 16, 16 ] ) + inputs[1] = nodeValue_Vec2("Span", self, [ 16, 16 ] ) .setVisible(true, true); inputs[2] = nodeValue_Enum_Scroll("Shape", self, AREA_SHAPE.rectangle, [ diff --git a/scripts/node_armature_bind/node_armature_bind.gml b/scripts/node_armature_bind/node_armature_bind.gml index a4fb23807..00e6a2ec1 100644 --- a/scripts/node_armature_bind/node_armature_bind.gml +++ b/scripts/node_armature_bind/node_armature_bind.gml @@ -22,7 +22,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr .setVisible(true, true) .setArrayDepth(1); - inputs[3] = nodeValue_Vector("Bone transform", self, [ 0, 0 ]); + inputs[3] = nodeValue_Vec2("Bone transform", self, [ 0, 0 ]); inputs[4] = nodeValue_Float("Bone scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0.1, 2, 0.01 ] }); diff --git a/scripts/node_atlas_set/node_atlas_set.gml b/scripts/node_atlas_set/node_atlas_set.gml index 62194cf38..751f315ab 100644 --- a/scripts/node_atlas_set/node_atlas_set.gml +++ b/scripts/node_atlas_set/node_atlas_set.gml @@ -7,11 +7,11 @@ function Node_Atlas_Set(_x, _y, _group = noone) : Node(_x, _y, _group) construct inputs[1] = nodeValue_Surface("Surface", self); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0 ]); inputs[3] = nodeValue_Rotation("Rotation", self, 0); - inputs[4] = nodeValue_Vector("Scale", self, [ 0, 0 ]); + inputs[4] = nodeValue_Vec2("Scale", self, [ 0, 0 ]); inputs[5] = nodeValue_Color("Blend", self, c_white); diff --git a/scripts/node_bevel/node_bevel.gml b/scripts/node_bevel/node_bevel.gml index 9985e3a0f..08705b483 100644 --- a/scripts/node_bevel/node_bevel.gml +++ b/scripts/node_bevel/node_bevel.gml @@ -6,9 +6,9 @@ function Node_Bevel(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[1] = nodeValue_Int("Height", self, 4) .setMappable(11); - inputs[2] = nodeValue_Vector("Shift", self, [ 0, 0 ]); + inputs[2] = nodeValue_Vec2("Shift", self, [ 0, 0 ]); - inputs[3] = nodeValue_Vector("Scale", self, [ 1, 1 ] ); + inputs[3] = nodeValue_Vec2("Scale", self, [ 1, 1 ] ); inputs[4] = nodeValue_Enum_Scroll("Slope", self, 0, [ new scrollItem("Linear", s_node_curve, 2), new scrollItem("Smooth", s_node_curve, 4), diff --git a/scripts/node_blend/node_blend.gml b/scripts/node_blend/node_blend.gml index a96a99b4e..9cf4d01e5 100644 --- a/scripts/node_blend/node_blend.gml +++ b/scripts/node_blend/node_blend.gml @@ -49,7 +49,7 @@ function Node_Blend(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[6] = nodeValue_Enum_Scroll("Output dimension", self, 0, [ "Background", "Forground", "Mask", "Maximum", "Constant" ]) .rejectArray(); - inputs[7] = nodeValue_Vector("Constant dimension", self, DEF_SURF); + inputs[7] = nodeValue_Vec2("Constant dimension", self, DEF_SURF); inputs[8] = nodeValue_Bool("Active", self, true); active_index = 8; @@ -67,7 +67,7 @@ function Node_Blend(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[13] = nodeValue_Float("Mask feather", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [1, 16, 0.1] }); - inputs[14] = nodeValue_Vector("Position", self, [ 0.5, 0.5 ]); + inputs[14] = nodeValue_Vec2("Position", self, [ 0.5, 0.5 ]); outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_bloom/node_bloom.gml b/scripts/node_bloom/node_bloom.gml index 81882725b..633d84ecc 100644 --- a/scripts/node_bloom/node_bloom.gml +++ b/scripts/node_bloom/node_bloom.gml @@ -32,7 +32,7 @@ function Node_Bloom(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[13] = nodeValue_Enum_Scroll("Types", self, 0, [ "Gaussian", "Zoom" ]); - inputs[14] = nodeValue_Vector("Zoom Origin", self, [ 0.5, 0.5 ]) + inputs[14] = nodeValue_Vec2("Zoom Origin", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); input_display_list = [ 7, 8, diff --git a/scripts/node_blur_radial/node_blur_radial.gml b/scripts/node_blur_radial/node_blur_radial.gml index 779451f5b..2fd863ce0 100644 --- a/scripts/node_blur_radial/node_blur_radial.gml +++ b/scripts/node_blur_radial/node_blur_radial.gml @@ -6,7 +6,7 @@ function Node_Blur_Radial(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[1] = nodeValue_Rotation("Strength", self, 45) .setMappable(10); - inputs[2] = nodeValue_Vector("Center", self, [ 0.5, 0.5 ]) + inputs[2] = nodeValue_Vec2("Center", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[3] = nodeValue_Enum_Scroll("Oversample mode", self, 0, [ "Empty", "Clamp", "Repeat" ]) diff --git a/scripts/node_blur_zoom/node_blur_zoom.gml b/scripts/node_blur_zoom/node_blur_zoom.gml index c2075a8d0..4fb2dec26 100644 --- a/scripts/node_blur_zoom/node_blur_zoom.gml +++ b/scripts/node_blur_zoom/node_blur_zoom.gml @@ -6,7 +6,7 @@ function Node_Blur_Zoom(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Float("Strength", self, 0.2) .setMappable(12); - inputs[2] = nodeValue_Vector("Center", self, [ 0.5, 0.5 ]) + inputs[2] = nodeValue_Vec2("Center", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[3] = nodeValue_Enum_Scroll("Oversample mode", self, 0, [ "Empty", "Clamp", "Repeat" ]) diff --git a/scripts/node_box_pattern/node_box_pattern.gml b/scripts/node_box_pattern/node_box_pattern.gml index 4724a21d6..3c2e34a9c 100644 --- a/scripts/node_box_pattern/node_box_pattern.gml +++ b/scripts/node_box_pattern/node_box_pattern.gml @@ -10,7 +10,7 @@ function Node_Box_Pattern(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[2] = nodeValue_Rotation("Angle", self, 0) .setMappable(7); - inputs[3] = nodeValue_Vector("Position", self, [0, 0] ) + inputs[3] = nodeValue_Vec2("Position", self, [0, 0] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[4] = nodeValue_Color("Color 1", self, c_white); diff --git a/scripts/node_camera/node_camera.gml b/scripts/node_camera/node_camera.gml index f89f76a4f..7a3706936 100644 --- a/scripts/node_camera/node_camera.gml +++ b/scripts/node_camera/node_camera.gml @@ -38,7 +38,7 @@ function Node_Camera(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[index + 1] = nodeValue_Enum_Button($"Positioning {_s}", self, false, [ "Space", "Camera" ]); - inputs[index + 2] = nodeValue_Vector($"Position {_s}", self, [ 0, 0 ] ) + inputs[index + 2] = nodeValue_Vec2($"Position {_s}", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[index + 3] = nodeValue_Enum_Scroll($"Oversample {_s}", self, 0, [ new scrollItem("Empty ", s_node_camera_repeat, 0), @@ -46,7 +46,7 @@ function Node_Camera(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co new scrollItem("Repeat X", s_node_camera_repeat, 2), new scrollItem("Repeat Y", s_node_camera_repeat, 3), ]); - inputs[index + 4] = nodeValue_Vector($"Parallax {_s}", self, [ 0, 0 ]); + inputs[index + 4] = nodeValue_Vec2($"Parallax {_s}", self, [ 0, 0 ]); inputs[index + 5] = nodeValue($"Depth {_s}", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0); diff --git a/scripts/node_canvas/node_canvas.gml b/scripts/node_canvas/node_canvas.gml index cfe9f7f81..4de11a580 100644 --- a/scripts/node_canvas/node_canvas.gml +++ b/scripts/node_canvas/node_canvas.gml @@ -50,6 +50,7 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor frame_renderer_x = 0; frame_renderer_x_to = 0; frame_renderer_x_max = 0; + _selecting_frame = noone; frame_renderer_content = surface_create(1, 1); frame_renderer = new Inspector_Custom_Renderer(function(_x, _y, _w, _m, _hover, _focus, _full = true, _fx = frame_renderer_x) { #region frame_renderer @@ -120,11 +121,18 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor if(mouse_press(mb_left, _focus)) _del = i; + } else if(point_in_rectangle(_msx, _msy, _sx, _sy, _sx + _ssw, _sy + _ssh)) { - _del_a = 0; - + draw_sprite_stretched_add(THEME.s_box_r2, 1, _sx, _sy, _ssw, _ssh, c_white, .2); if(mouse_press(mb_left, _focus)) setFrame(i); + + if(mouse_press(mb_right, _focus)) { + _selecting_frame = i; + menuCall("node_canvas_frame", [ + menuItem(__txt("Delete"), function() /*=>*/ { removeFrame(_selecting_frame); }, THEME.cross) + ]); + } } if(_del_a != noone) { @@ -1259,9 +1267,11 @@ function timelineItemNode_Canvas(node) : timelineItemNode(node) constructor { } } - if(!_hov && _chv) { - var _fr = round((_msx - _x) / _s); - if(_fr < 1 || _fr > TOTAL_FRAMES) return _hov; + var _fr = round((_msx - _x) / _s); + if(_fr < 1 || _fr > TOTAL_FRAMES) return _hov; + + var _frAdd = _fr - node.attributes.frames; + if(!_hov && _chv && _frAdd < 16) { _rx = _x + _fr * _s; _rx0 = _rx - _h / 2; diff --git a/scripts/node_caustic/node_caustic.gml b/scripts/node_caustic/node_caustic.gml index 89d37f7ca..cccc7f642 100644 --- a/scripts/node_caustic/node_caustic.gml +++ b/scripts/node_caustic/node_caustic.gml @@ -2,11 +2,11 @@ function Node_Caustic(_x, _y, _group = noone) : Node_Shader_Generator(_x, _y, _g name = "Caustic"; shader = sh_water_caustic; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]); addShaderProp(SHADER_UNIFORM.float, "scale"); inputs[3] = nodeValue_Float("Seed", self, seed_random(6)) diff --git a/scripts/node_cellular/node_cellular.gml b/scripts/node_cellular/node_cellular.gml index 10626f0ea..561062b79 100644 --- a/scripts/node_cellular/node_cellular.gml +++ b/scripts/node_cellular/node_cellular.gml @@ -3,7 +3,7 @@ function Node_Cellular(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2]) + inputs[1] = nodeValue_Vec2("Position", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2]) .setUnitRef(function(index) { return getDimension(index); }); inputs[2] = nodeValue_Float("Scale", self, 4) diff --git a/scripts/node_checker/node_checker.gml b/scripts/node_checker/node_checker.gml index 4ba35400d..74d5fd0e4 100644 --- a/scripts/node_checker/node_checker.gml +++ b/scripts/node_checker/node_checker.gml @@ -10,7 +10,7 @@ function Node_Checker(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c inputs[2] = nodeValue_Rotation("Angle", self, 0) .setMappable(7); - inputs[3] = nodeValue_Vector("Position", self, [0, 0] ) + inputs[3] = nodeValue_Vec2("Position", self, [0, 0] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[4] = nodeValue_Color("Color 1", self, c_white); diff --git a/scripts/node_chromatic_aberration/node_chromatic_aberration.gml b/scripts/node_chromatic_aberration/node_chromatic_aberration.gml index c4d4d033b..402878759 100644 --- a/scripts/node_chromatic_aberration/node_chromatic_aberration.gml +++ b/scripts/node_chromatic_aberration/node_chromatic_aberration.gml @@ -3,7 +3,7 @@ function Node_Chromatic_Aberration(_x, _y, _group = noone) : Node_Processor(_x, inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Center", self, [ 0.5, 0.5 ]) + inputs[1] = nodeValue_Vec2("Center", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[2] = nodeValue_Float("Strength", self, 1) diff --git a/scripts/node_composite/node_composite.gml b/scripts/node_composite/node_composite.gml index 68e980ef1..13e3f5d2e 100644 --- a/scripts/node_composite/node_composite.gml +++ b/scripts/node_composite/node_composite.gml @@ -415,12 +415,12 @@ function Node_Composite(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[index + 0] = nodeValue_Surface($"Surface {_s}", self, noone); inputs[index + 0].hover_effect = 0; - inputs[index + 1] = nodeValue_Vector($"Position {_s}", self, [ 0, 0 ] ) + inputs[index + 1] = nodeValue_Vec2($"Position {_s}", self, [ 0, 0 ] ) .setUnitRef(function(index) { return [ overlay_w, overlay_h ]; }); inputs[index + 2] = nodeValue_Rotation($"Rotation {_s}", self, 0); - inputs[index + 3] = nodeValue_Vector($"Scale {_s}", self, [ 1, 1 ] ); + inputs[index + 3] = nodeValue_Vec2($"Scale {_s}", self, [ 1, 1 ] ); inputs[index + 4] = nodeValue_Enum_Scroll($"Blend {_s}", self, 0, BLEND_TYPES ); diff --git a/scripts/node_crop/node_crop.gml b/scripts/node_crop/node_crop.gml index 4949f3a5b..d42b69e0d 100644 --- a/scripts/node_crop/node_crop.gml +++ b/scripts/node_crop/node_crop.gml @@ -12,9 +12,9 @@ function Node_Crop(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[3] = nodeValue_Enum_Scroll("Aspect Ratio", self, 0, [ "None", "Manual", "1:1", "3:2", "4:3", "16:9" ]); - inputs[4] = nodeValue_Vector("Ratio", self, [ 1, 1 ]); + inputs[4] = nodeValue_Vec2("Ratio", self, [ 1, 1 ]); - inputs[5] = nodeValue_Vector("Center", self, [ .5, .5 ]) + inputs[5] = nodeValue_Vec2("Center", self, [ .5, .5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[6] = nodeValue_Float("Width", self, 8 ); diff --git a/scripts/node_data/node_data.gml b/scripts/node_data/node_data.gml index 9ffb810fe..732006594 100644 --- a/scripts/node_data/node_data.gml +++ b/scripts/node_data/node_data.gml @@ -932,10 +932,13 @@ function Node(_x, _y, _group = noone) : __Node_Base(_x, _y) constructor { if(!rendered) return true; force_requeue = false; - for(var i = 0; i < input_list_size; i++) - if(inputs[i].isActiveDynamic(frame)) return true; + __temp_frame = frame; + return array_any(inputs, function(inp) /*=>*/ {return inp.isActiveDynamic(__temp_frame)}); - return false; + // for(var i = 0; i < input_list_size; i++) + // if(inputs[i].isActiveDynamic(frame)) return true; + + // return false; } static triggerRender = function(resetSelf = true) { diff --git a/scripts/node_dilate/node_dilate.gml b/scripts/node_dilate/node_dilate.gml index eebeb87c5..15c4e4c1f 100644 --- a/scripts/node_dilate/node_dilate.gml +++ b/scripts/node_dilate/node_dilate.gml @@ -3,7 +3,7 @@ function Node_Dilate(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Center", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Center", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[2] = nodeValue_Float("Strength", self, 1) diff --git a/scripts/node_displace/node_displace.gml b/scripts/node_displace/node_displace.gml index a1c045057..5d12dac57 100644 --- a/scripts/node_displace/node_displace.gml +++ b/scripts/node_displace/node_displace.gml @@ -5,7 +5,7 @@ function Node_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Surface("Displace map", self); - inputs[2] = nodeValue_Vector("Position", self, [ 1, 0 ] ) + inputs[2] = nodeValue_Vec2("Position", self, [ 1, 0 ] ) .setTooltip("Vector to displace pixel by.") .setUnitRef(function(index) { return getDimension(index); }); diff --git a/scripts/node_display_image/node_display_image.gml b/scripts/node_display_image/node_display_image.gml index 38a9351b8..86e065462 100644 --- a/scripts/node_display_image/node_display_image.gml +++ b/scripts/node_display_image/node_display_image.gml @@ -31,10 +31,10 @@ function Node_Display_Image(_x, _y, _group = noone) : Node(_x, _y, _group) const .setDisplay(VALUE_DISPLAY.path_load, { filter: "image|*.png;*.jpg" }) .rejectArray(); - inputs[1] = nodeValue_Vector("Position", self, [ x, y ]) + inputs[1] = nodeValue_Vec2("Position", self, [ x, y ]) .rejectArray(); - inputs[2] = nodeValue_Vector("Scale", self, [ 1, 1 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 1, 1 ]) .rejectArray(); inputs[3] = nodeValue_Bool("Smooth transform", self, true) diff --git a/scripts/node_display_text/node_display_text.gml b/scripts/node_display_text/node_display_text.gml index f3f467736..8ea928f4a 100644 --- a/scripts/node_display_text/node_display_text.gml +++ b/scripts/node_display_text/node_display_text.gml @@ -32,7 +32,7 @@ function Node_Display_Text(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[4] = nodeValue_Float("Line width", self, -1) .rejectArray(); - inputs[5] = nodeValue_Vector("Position", self, [ x, y ]) + inputs[5] = nodeValue_Vec2("Position", self, [ x, y ]) .rejectArray(); inputs[6] = nodeValue_Float("Line height", self, 0) diff --git a/scripts/node_flood_fill/node_flood_fill.gml b/scripts/node_flood_fill/node_flood_fill.gml index 26e489e1a..bdc26fdbb 100644 --- a/scripts/node_flood_fill/node_flood_fill.gml +++ b/scripts/node_flood_fill/node_flood_fill.gml @@ -11,7 +11,7 @@ function Node_Flood_Fill(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[3] = nodeValue_Bool("Active", self, true); active_index = 3; - inputs[4] = nodeValue_Vector("Position", self, [ 1, 1 ]); + inputs[4] = nodeValue_Vec2("Position", self, [ 1, 1 ]); inputs[5] = nodeValue_Color("Colors", self, cola(c_black) ); diff --git a/scripts/node_flow_noise/node_flow_noise.gml b/scripts/node_flow_noise/node_flow_noise.gml index e491ab703..84877ca09 100644 --- a/scripts/node_flow_noise/node_flow_noise.gml +++ b/scripts/node_flow_noise/node_flow_noise.gml @@ -2,11 +2,11 @@ function Node_Flow_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x, _y, name = "Flow Noise"; shader = sh_noise_flow; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 2, 2 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 2, 2 ]); addShaderProp(SHADER_UNIFORM.float, "scale"); inputs[3] = nodeValue_Float("Progress", self, 0) diff --git a/scripts/node_fn_wave_table/node_fn_wave_table.gml b/scripts/node_fn_wave_table/node_fn_wave_table.gml index f33075515..f04d2616f 100644 --- a/scripts/node_fn_wave_table/node_fn_wave_table.gml +++ b/scripts/node_fn_wave_table/node_fn_wave_table.gml @@ -4,7 +4,7 @@ function Node_Fn_WaveTable(_x, _y, _group = noone) : Node_Fn(_x, _y, _group) con inputs[inl + 0] = nodeValue_Float("Pattern", self, 0 ) .setDisplay(VALUE_DISPLAY.slider, { range: [0, 3, 0.01] }); - inputs[inl + 1] = nodeValue_Vector("Range", self, [ 0, 1 ]); + inputs[inl + 1] = nodeValue_Vec2("Range", self, [ 0, 1 ]); inputs[inl + 2] = nodeValue_Float("Frequency", self, 2 ) .setDisplay(VALUE_DISPLAY.slider, { range: [1, 8, 0.01] }); diff --git a/scripts/node_fn_wiggler/node_fn_wiggler.gml b/scripts/node_fn_wiggler/node_fn_wiggler.gml index a673bef78..0ebf31c4f 100644 --- a/scripts/node_fn_wiggler/node_fn_wiggler.gml +++ b/scripts/node_fn_wiggler/node_fn_wiggler.gml @@ -1,7 +1,7 @@ function Node_Wiggler(_x, _y, _group = noone) : Node_Fn(_x, _y, _group) constructor { name = "Wiggler"; - inputs[inl + 0] = nodeValue_Vector("Range", self, [ 0, 1 ]); + inputs[inl + 0] = nodeValue_Vec2("Range", self, [ 0, 1 ]); inputs[inl + 1] = nodeValue_Int("Frequency", self, 4 ) .setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 0.1] }); diff --git a/scripts/node_fold_noise/node_fold_noise.gml b/scripts/node_fold_noise/node_fold_noise.gml index 821c88dec..c4c9c7714 100644 --- a/scripts/node_fold_noise/node_fold_noise.gml +++ b/scripts/node_fold_noise/node_fold_noise.gml @@ -2,11 +2,11 @@ function Node_Fold_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x, _y, name = "Fold Noise"; shader = sh_noise_fold; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 2, 2 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 2, 2 ]); addShaderProp(SHADER_UNIFORM.float, "scale"); inputs[3] = nodeValue_Int("Iteration", self, 2) diff --git a/scripts/node_frame/node_frame.gml b/scripts/node_frame/node_frame.gml index 117580be8..d3db77e7c 100644 --- a/scripts/node_frame/node_frame.gml +++ b/scripts/node_frame/node_frame.gml @@ -34,7 +34,7 @@ function Node_Frame(_x, _y, _group = noone) : Node(_x, _y, _group) constructor { draw_y1 = 0; - inputs[0] = nodeValue_Vector("Size", self, [ 240, 160 ] ) + inputs[0] = nodeValue_Vec2("Size", self, [ 240, 160 ] ) .rejectArray(); inputs[1] = nodeValue_Color("Color", self, cola(c_white) ) diff --git a/scripts/node_gabor_noise/node_gabor_noise.gml b/scripts/node_gabor_noise/node_gabor_noise.gml index 9112492c0..57b472d65 100644 --- a/scripts/node_gabor_noise/node_gabor_noise.gml +++ b/scripts/node_gabor_noise/node_gabor_noise.gml @@ -2,11 +2,11 @@ function Node_Gabor_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x, _y name = "Gabor Noise"; shader = sh_noise_gabor; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]) .setMappable(8); addShaderProp(SHADER_UNIFORM.float, "scale"); @@ -24,7 +24,7 @@ function Node_Gabor_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x, _y .setMappable(10); addShaderProp(SHADER_UNIFORM.float, "sharpness"); - inputs[6] = nodeValue_Vector("Augment", self, [ 11, 31 ]); + inputs[6] = nodeValue_Vec2("Augment", self, [ 11, 31 ]); addShaderProp(SHADER_UNIFORM.float, "augment"); inputs[7] = nodeValue_Rotation("Phase", self, 0) diff --git a/scripts/node_gradient/node_gradient.gml b/scripts/node_gradient/node_gradient.gml index b00a95298..bcf3c991e 100644 --- a/scripts/node_gradient/node_gradient.gml +++ b/scripts/node_gradient/node_gradient.gml @@ -20,7 +20,7 @@ function Node_Gradient(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) .setDisplay(VALUE_DISPLAY.slider, { range: [-2, 2, 0.01] }) .setMappable(12); - inputs[6] = nodeValue_Vector("Center", self, [ 0.5, 0.5 ]) + inputs[6] = nodeValue_Vec2("Center", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[7] = nodeValue_Enum_Button("Loop", self, 0, [ "None", "Loop", "Pingpong" ]); diff --git a/scripts/node_gradient_points/node_gradient_points.gml b/scripts/node_gradient_points/node_gradient_points.gml index 841ee9ca5..d26b541f2 100644 --- a/scripts/node_gradient_points/node_gradient_points.gml +++ b/scripts/node_gradient_points/node_gradient_points.gml @@ -3,19 +3,19 @@ function Node_Gradient_Points(_x, _y, _group = noone) : Node_Processor(_x, _y, _ inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Center 1", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Center 1", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[2] = nodeValue_Color("Color 1", self, c_white ); - inputs[3] = nodeValue_Vector("Center 2", self, [ DEF_SURF_W, 0 ] ) + inputs[3] = nodeValue_Vec2("Center 2", self, [ DEF_SURF_W, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[4] = nodeValue_Color("Color 2", self, c_white ); - inputs[5] = nodeValue_Vector("Center 3", self, [ 0, DEF_SURF_H ] ) + inputs[5] = nodeValue_Vec2("Center 3", self, [ 0, DEF_SURF_H ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[6] = nodeValue_Color("Color 3", self, c_white ); - inputs[7] = nodeValue_Vector("Center 4", self, DEF_SURF , { useGlobal : false }) + inputs[7] = nodeValue_Vec2("Center 4", self, DEF_SURF , { useGlobal : false }) .setUnitRef(function(index) { return getDimension(index); }); inputs[8] = nodeValue_Color("Color 4", self, c_white ); diff --git a/scripts/node_graph_preview/node_graph_preview.gml b/scripts/node_graph_preview/node_graph_preview.gml index 467ce797b..214f5d530 100644 --- a/scripts/node_graph_preview/node_graph_preview.gml +++ b/scripts/node_graph_preview/node_graph_preview.gml @@ -5,7 +5,7 @@ function Node_Graph_Preview(_x, _y, _group = noone) : Node(_x, _y, _group) const inputs[0] = nodeValue_Surface("Surface", self) .rejectArray(); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .rejectArray(); inputs[2] = nodeValue_Float("Scale", self, 1) diff --git a/scripts/node_grid/node_grid.gml b/scripts/node_grid/node_grid.gml index e3a08c393..38d628130 100644 --- a/scripts/node_grid/node_grid.gml +++ b/scripts/node_grid/node_grid.gml @@ -3,10 +3,10 @@ function Node_Grid(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Grid Size", self, [ 8, 8 ]) + inputs[2] = nodeValue_Vec2("Grid Size", self, [ 8, 8 ]) .setMappable(13); inputs[3] = nodeValue_Float("Gap", self, 0.2) diff --git a/scripts/node_grid_hex/node_grid_hex.gml b/scripts/node_grid_hex/node_grid_hex.gml index 7d847e081..c3f13beb9 100644 --- a/scripts/node_grid_hex/node_grid_hex.gml +++ b/scripts/node_grid_hex/node_grid_hex.gml @@ -3,10 +3,10 @@ function Node_Grid_Hex(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 2, 2 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 2, 2 ]) .setMappable(11); inputs[3] = nodeValue_Rotation("Angle", self, 0) diff --git a/scripts/node_grid_noise/node_grid_noise.gml b/scripts/node_grid_noise/node_grid_noise.gml index bc8dd89d9..cf1eb7afb 100644 --- a/scripts/node_grid_noise/node_grid_noise.gml +++ b/scripts/node_grid_noise/node_grid_noise.gml @@ -3,10 +3,10 @@ function Node_Grid_Noise(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 8, 8 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 8, 8 ]); inputs[3] = nodeValue_Float("Seed", self, seed_random(6)) .setDisplay(VALUE_DISPLAY._default, { side_button : button(function() { randomize(); inputs[3].setValue(seed_random(6)); }).setIcon(THEME.icon_random, 0, COLORS._main_icon) }); diff --git a/scripts/node_grid_pentagonal/node_grid_pentagonal.gml b/scripts/node_grid_pentagonal/node_grid_pentagonal.gml index ecd8fb3ab..d2becd15b 100644 --- a/scripts/node_grid_pentagonal/node_grid_pentagonal.gml +++ b/scripts/node_grid_pentagonal/node_grid_pentagonal.gml @@ -3,10 +3,10 @@ function Node_Grid_Pentagonal(_x, _y, _group = noone) : Node_Processor(_x, _y, _ inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]) .setMappable(11); inputs[3] = nodeValue_Float("Gap", self, 0.1) diff --git a/scripts/node_grid_tri/node_grid_tri.gml b/scripts/node_grid_tri/node_grid_tri.gml index cbd60a707..03ab287a2 100644 --- a/scripts/node_grid_tri/node_grid_tri.gml +++ b/scripts/node_grid_tri/node_grid_tri.gml @@ -3,10 +3,10 @@ function Node_Grid_Tri(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 2, 2 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 2, 2 ]) .setMappable(11); inputs[3] = nodeValue_Float("Gap", self, 0.1) diff --git a/scripts/node_herringbone_tile/node_herringbone_tile.gml b/scripts/node_herringbone_tile/node_herringbone_tile.gml index 7e13ae92e..dc9c41fa9 100644 --- a/scripts/node_herringbone_tile/node_herringbone_tile.gml +++ b/scripts/node_herringbone_tile/node_herringbone_tile.gml @@ -3,10 +3,10 @@ function Node_Herringbone_Tile(_x, _y, _group = noone) : Node_Processor(_x, _y, inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]) .setMappable(11); inputs[3] = nodeValue_Rotation("Angle", self, 0) diff --git a/scripts/node_honey_noise/node_honey_noise.gml b/scripts/node_honey_noise/node_honey_noise.gml index 98ad0f7cd..90360bf15 100644 --- a/scripts/node_honey_noise/node_honey_noise.gml +++ b/scripts/node_honey_noise/node_honey_noise.gml @@ -2,11 +2,11 @@ function Node_Honeycomb_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x name = "Honeycomb Noise"; shader = sh_noise_honey; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 2, 2 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 2, 2 ]); addShaderProp(SHADER_UNIFORM.float, "scale"); inputs[3] = nodeValue_Rotation("Rotation", self, 0); diff --git a/scripts/node_image_grid/node_image_grid.gml b/scripts/node_image_grid/node_image_grid.gml index 03f2ace25..3a14371aa 100644 --- a/scripts/node_image_grid/node_image_grid.gml +++ b/scripts/node_image_grid/node_image_grid.gml @@ -9,7 +9,7 @@ function Node_Image_Grid(_x, _y, _group = noone) : Node(_x, _y, _group) construc .setValidator(VV_min(1)) .rejectArray(); - inputs[2] = nodeValue_Vector("Spacing", self, [ 0, 0 ]) + inputs[2] = nodeValue_Vec2("Spacing", self, [ 0, 0 ]) .rejectArray(); inputs[3] = nodeValue_Padding("Padding", self, [ 0, 0, 0, 0 ]) diff --git a/scripts/node_image_sheet/node_image_sheet.gml b/scripts/node_image_sheet/node_image_sheet.gml index f92cc48db..a8f409408 100644 --- a/scripts/node_image_sheet/node_image_sheet.gml +++ b/scripts/node_image_sheet/node_image_sheet.gml @@ -3,14 +3,14 @@ function Node_Image_Sheet(_x, _y, _group = noone) : Node(_x, _y, _group) constru inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Sprite size", self, [ 32, 32 ]); + inputs[1] = nodeValue_Vec2("Sprite size", self, [ 32, 32 ]); inputs[2] = nodeValue_Int("Row", self, 1); //unused - inputs[3] = nodeValue_Vector("Amount", self, [ 1, 1 ]); + inputs[3] = nodeValue_Vec2("Amount", self, [ 1, 1 ]); - inputs[4] = nodeValue_Vector("Offset", self, [ 0, 0 ]); + inputs[4] = nodeValue_Vec2("Offset", self, [ 0, 0 ]); - inputs[5] = nodeValue_Vector("Spacing", self, [ 0, 0 ]); + inputs[5] = nodeValue_Vec2("Spacing", self, [ 0, 0 ]); inputs[6] = nodeValue_Padding("Padding", self, [0, 0, 0, 0]); diff --git a/scripts/node_line/node_line.gml b/scripts/node_line/node_line.gml index 2b7427afc..3e88bbbf9 100644 --- a/scripts/node_line/node_line.gml +++ b/scripts/node_line/node_line.gml @@ -8,7 +8,7 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[2] = nodeValue_Int("Segment", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 0.1] }); - inputs[3] = nodeValue_Vector("Width", self, [ 2, 2 ]); + inputs[3] = nodeValue_Vec2("Width", self, [ 2, 2 ]); inputs[4] = nodeValue_Float("Wiggle", self, 0) .setDisplay(VALUE_DISPLAY.slider, { range: [0, 16, 0.01] }); @@ -48,11 +48,11 @@ function Node_Line(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[20] = nodeValue_Float("Segment length", self, 4); - inputs[21] = nodeValue_Vector("Texture position", self, [ 0, 0 ]); + inputs[21] = nodeValue_Vec2("Texture position", self, [ 0, 0 ]); inputs[22] = nodeValue_Rotation("Texture Rotation", self, 0); - inputs[23] = nodeValue_Vector("Texture scale", self, [ 1, 1 ]); + inputs[23] = nodeValue_Vec2("Texture scale", self, [ 1, 1 ]); inputs[24] = nodeValue_Gradient("Random Blend", self, new gradientObject(cola(c_white))); diff --git a/scripts/node_lua_surface/node_lua_surface.gml b/scripts/node_lua_surface/node_lua_surface.gml index 059f08e3e..de98c6df8 100644 --- a/scripts/node_lua_surface/node_lua_surface.gml +++ b/scripts/node_lua_surface/node_lua_surface.gml @@ -5,7 +5,7 @@ function Node_Lua_Surface(_x, _y, _group = noone) : Node(_x, _y, _group) constru inputs[0] = nodeValue_Text("Function name", self, "render" + string(irandom_range(100000, 999999))); - inputs[1] = nodeValue_Vector("Output dimension", self, DEF_SURF); + inputs[1] = nodeValue_Vec2("Output dimension", self, DEF_SURF); inputs[2] = nodeValue_Text("Lua code", self, "", o_dialog_lua_reference) .setDisplay(VALUE_DISPLAY.codeLUA); diff --git a/scripts/node_mesh_transform/node_mesh_transform.gml b/scripts/node_mesh_transform/node_mesh_transform.gml index 401999231..4ace9322b 100644 --- a/scripts/node_mesh_transform/node_mesh_transform.gml +++ b/scripts/node_mesh_transform/node_mesh_transform.gml @@ -5,13 +5,13 @@ function Node_Mesh_Transform(_x, _y, _group = noone) : Node(_x, _y, _group) cons inputs[0] = nodeValue("Mesh", self, JUNCTION_CONNECT.input, VALUE_TYPE.mesh, noone) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]); inputs[2] = nodeValue_Rotation("Rotation", self, 0); - inputs[3] = nodeValue_Vector("Scale", self, [ 1, 1 ]); + inputs[3] = nodeValue_Vec2("Scale", self, [ 1, 1 ]); - inputs[4] = nodeValue_Vector("Anchor", self, [ 0, 0 ]); + inputs[4] = nodeValue_Vec2("Anchor", self, [ 0, 0 ]); outputs[0] = nodeValue_Output("Mesh", self, VALUE_TYPE.mesh, noone); diff --git a/scripts/node_mirror/node_mirror.gml b/scripts/node_mirror/node_mirror.gml index a80746d72..41ee02edf 100644 --- a/scripts/node_mirror/node_mirror.gml +++ b/scripts/node_mirror/node_mirror.gml @@ -4,7 +4,7 @@ function Node_Mirror(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Position", self, [ 0.5, 0.5 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[2] = nodeValue_Rotation("Angle", self, 0); diff --git a/scripts/node_mk_cable/node_mk_cable.gml b/scripts/node_mk_cable/node_mk_cable.gml index 52a185f95..ce74c395e 100644 --- a/scripts/node_mk_cable/node_mk_cable.gml +++ b/scripts/node_mk_cable/node_mk_cable.gml @@ -3,9 +3,9 @@ function Node_MK_Cable(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Point 1", self, [ 0, 0 ]); + inputs[1] = nodeValue_Vec2("Point 1", self, [ 0, 0 ]); - inputs[2] = nodeValue_Vector("Point 2", self, [ 16, 16 ]); + inputs[2] = nodeValue_Vec2("Point 2", self, [ 16, 16 ]); input_display_list = [ new Inspector_Sprite(s_MKFX), 0, ["Saber", false], 1, 2, diff --git a/scripts/node_mk_fall/node_mk_fall.gml b/scripts/node_mk_fall/node_mk_fall.gml index e098b433e..f99fd7843 100644 --- a/scripts/node_mk_fall/node_mk_fall.gml +++ b/scripts/node_mk_fall/node_mk_fall.gml @@ -21,13 +21,13 @@ function Node_MK_Fall(_x, _y, _group = noone) : Node(_x, _y, _group) constructor inputs[8] = nodeValue_Range("Swing frequency", self, [ 1, 1 ], { linked : true }); - inputs[9] = nodeValue_Vector("Size", self, [ 4, 2 ]); + inputs[9] = nodeValue_Vec2("Size", self, [ 4, 2 ]); inputs[10] = nodeValue_Range("Speed", self, [ 1, 1 ], { linked : true }); inputs[11] = nodeValue_Range("X Momentum", self, [ 0, 0 ], { linked : true }); - inputs[12] = nodeValue_Vector("Wind", self, [ 0, 0 ]); + inputs[12] = nodeValue_Vec2("Wind", self, [ 0, 0 ]); inputs[13] = nodeValue_Gradient("Color", self, new gradientObject(cola(c_white))) diff --git a/scripts/node_mk_flag/node_mk_flag.gml b/scripts/node_mk_flag/node_mk_flag.gml index 666c9cc00..ee8c379fc 100644 --- a/scripts/node_mk_flag/node_mk_flag.gml +++ b/scripts/node_mk_flag/node_mk_flag.gml @@ -6,7 +6,7 @@ function Node_MK_Flag(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c inputs[1] = nodeValue_Surface("Texture", self); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0 ]); inputs[3] = nodeValue_Enum_Button("Pin side", self, 0, [ "Left", "Right", "Up", "Down" ]); diff --git a/scripts/node_mk_flare/node_mk_flare.gml b/scripts/node_mk_flare/node_mk_flare.gml index bdbf1a91a..1ba3bf484 100644 --- a/scripts/node_mk_flare/node_mk_flare.gml +++ b/scripts/node_mk_flare/node_mk_flare.gml @@ -27,7 +27,7 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Surface("Background", self); - inputs[1] = nodeValue_Vector("Origin", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Origin", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[2] = nodeValue_Dimension(self); @@ -55,7 +55,7 @@ function Node_MK_Flare(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) .setArrayDepth(1) .setArrayDynamic(); - inputs[6] = nodeValue_Vector("Focus", self, [ 0.5, 0.5 ]) + inputs[6] = nodeValue_Vec2("Focus", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_mk_fracture/node_mk_fracture.gml b/scripts/node_mk_fracture/node_mk_fracture.gml index 638aa8f11..74f6a564a 100644 --- a/scripts/node_mk_fracture/node_mk_fracture.gml +++ b/scripts/node_mk_fracture/node_mk_fracture.gml @@ -3,7 +3,7 @@ function Node_MK_Fracture(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Subdivision", self, [ 4, 4 ]); + inputs[1] = nodeValue_Vec2("Subdivision", self, [ 4, 4 ]); inputs[2] = nodeValue_Float("Progress", self, 0.5) .setDisplay(VALUE_DISPLAY.slider) @@ -11,7 +11,7 @@ function Node_MK_Fracture(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[3] = nodeValueMap("Progress map", self); - inputs[4] = nodeValue_Vector("Movement", self, [ 0, 0 ]) + inputs[4] = nodeValue_Vec2("Movement", self, [ 0, 0 ]) .setMappable(9, true); inputs[5] = nodeValue_Rotation("Rotation", self, 180) diff --git a/scripts/node_mk_gridballs/node_mk_gridballs.gml b/scripts/node_mk_gridballs/node_mk_gridballs.gml index c37ce5a00..99ca1cabf 100644 --- a/scripts/node_mk_gridballs/node_mk_gridballs.gml +++ b/scripts/node_mk_gridballs/node_mk_gridballs.gml @@ -5,7 +5,7 @@ function Node_MK_GridBalls(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[1] = nodeValue_Dimension(self); - inputs[2] = nodeValue_Vector("Amount", self, [ 4, 4 ]); + inputs[2] = nodeValue_Vec2("Amount", self, [ 4, 4 ]); inputs[3] = nodeValue_Rotation("Light", self, 0); @@ -19,7 +19,7 @@ function Node_MK_GridBalls(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[7] = nodeValue_Rotation("Scatter direction", self, 0); - inputs[8] = nodeValue_Vector("Shift", self, [ 0, 0 ]); + inputs[8] = nodeValue_Vec2("Shift", self, [ 0, 0 ]); inputs[9] = nodeValue_Float("Stretch", self, 0); diff --git a/scripts/node_mk_gridflip/node_mk_gridflip.gml b/scripts/node_mk_gridflip/node_mk_gridflip.gml index fd32e246d..6e948bd81 100644 --- a/scripts/node_mk_gridflip/node_mk_gridflip.gml +++ b/scripts/node_mk_gridflip/node_mk_gridflip.gml @@ -5,7 +5,7 @@ function Node_MK_GridFlip(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[1] = nodeValue_Dimension(self); - inputs[2] = nodeValue_Vector("Amount", self, [ 4, 4 ]); + inputs[2] = nodeValue_Vec2("Amount", self, [ 4, 4 ]); inputs[3] = nodeValue_Int("Seed", self, seed_random(6)) .setDisplay(VALUE_DISPLAY._default, { side_button : button(function() { randomize(); inputs[3].setValue(seed_random(6)); }).setIcon(THEME.icon_random, 0, COLORS._main_icon) }); diff --git a/scripts/node_mk_saber/node_mk_saber.gml b/scripts/node_mk_saber/node_mk_saber.gml index 44c62bc07..83956632f 100644 --- a/scripts/node_mk_saber/node_mk_saber.gml +++ b/scripts/node_mk_saber/node_mk_saber.gml @@ -3,9 +3,9 @@ function Node_MK_Saber(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Point 1", self, [ 0, 0 ]); + inputs[1] = nodeValue_Vec2("Point 1", self, [ 0, 0 ]); - inputs[2] = nodeValue_Vector("Point 2", self, [ 16, 16 ]); + inputs[2] = nodeValue_Vec2("Point 2", self, [ 16, 16 ]); inputs[3] = nodeValue_Int("Thickness", self, 2) diff --git a/scripts/node_monitor_capture/node_monitor_capture.gml b/scripts/node_monitor_capture/node_monitor_capture.gml index 084eba5f3..90bef47e0 100644 --- a/scripts/node_monitor_capture/node_monitor_capture.gml +++ b/scripts/node_monitor_capture/node_monitor_capture.gml @@ -8,7 +8,7 @@ function Node_Monitor_Capture(_x, _y, _group = noone) : Node(_x, _y, _group) con inputs[1] = nodeValue_Enum_Scroll("Monitor", self, 0, array_create_ext(array_length(monitors), function(ind) { return monitors[ind][9]; })); - inputs[2] = nodeValue_Vector("Region", self, [ 0, 0, display_get_width(), display_get_height() ]); + inputs[2] = nodeValue_Vec4("Region", self, [ 0, 0, display_get_width(), display_get_height() ]); outputs[0] = nodeValue_Output("GUI", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_move_point/node_move_point.gml b/scripts/node_move_point/node_move_point.gml index b2fca5781..6cf576e11 100644 --- a/scripts/node_move_point/node_move_point.gml +++ b/scripts/node_move_point/node_move_point.gml @@ -4,12 +4,12 @@ function Node_Move_Point(_x, _y, _group = noone) : Node_Processor(_x, _y, _group setDimension(96, 48); - inputs[0] = nodeValue_Vector("Point", self, [ 0, 0, ]) + inputs[0] = nodeValue_Vec2("Point", self, [ 0, 0, ]) .setVisible(true, true); inputs[1] = nodeValue_Enum_Scroll("Mode", self, 0, [ "XY Shift", "Direction + Distance" ]); - inputs[2] = nodeValue_Vector("Shift", self, [ 0, 0 ]); + inputs[2] = nodeValue_Vec2("Shift", self, [ 0, 0 ]); inputs[3] = nodeValue_Rotation("Direction", self, 0); diff --git a/scripts/node_noise_aniso/node_noise_aniso.gml b/scripts/node_noise_aniso/node_noise_aniso.gml index cef7aee2a..bed0af4b1 100644 --- a/scripts/node_noise_aniso/node_noise_aniso.gml +++ b/scripts/node_noise_aniso/node_noise_aniso.gml @@ -9,7 +9,7 @@ function Node_Noise_Aniso(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[2] = nodeValue_Float("Seed", self, seed_random(6)) .setDisplay(VALUE_DISPLAY._default, { side_button : button(function() { randomize(); inputs[2].setValue(seed_random(6)); }).setIcon(THEME.icon_random, 0, COLORS._main_icon) }); - inputs[3] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[3] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[4] = nodeValue_Rotation("Rotation", self, 0) diff --git a/scripts/node_noise_cristal/node_noise_cristal.gml b/scripts/node_noise_cristal/node_noise_cristal.gml index 28ab69a58..5c8fcb178 100644 --- a/scripts/node_noise_cristal/node_noise_cristal.gml +++ b/scripts/node_noise_cristal/node_noise_cristal.gml @@ -2,10 +2,10 @@ function Node_Noise_Cristal(_x, _y, _group = noone) : Node_Shader_Generator(_x, name = "Cristal Noise"; shader = sh_noise_cristal; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ] ); + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ] ); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 1, 1 ] ); + inputs[2] = nodeValue_Vec2("Scale", self, [ 1, 1 ] ); addShaderProp(SHADER_UNIFORM.float, "scale"); inputs[3] = nodeValue_Float("Seed", self, seed_random(6)) diff --git a/scripts/node_noise_fbm/node_noise_fbm.gml b/scripts/node_noise_fbm/node_noise_fbm.gml index 12ca08c09..30c0948ad 100644 --- a/scripts/node_noise_fbm/node_noise_fbm.gml +++ b/scripts/node_noise_fbm/node_noise_fbm.gml @@ -6,9 +6,9 @@ function Node_Noise_FBM(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Float("Seed", self, seed_random(6)) .setDisplay(VALUE_DISPLAY._default, { side_button : button(function() { randomize(); inputs[1].setValue(seed_random(6)); }).setIcon(THEME.icon_random, 0, COLORS._main_icon) }); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0 ]); - inputs[3] = nodeValue_Vector("Scale", self, [ 4, 4 ]); + inputs[3] = nodeValue_Vec2("Scale", self, [ 4, 4 ]); inputs[4] = nodeValue_Int("Iteration", self, 4); diff --git a/scripts/node_noise_hex/node_noise_hex.gml b/scripts/node_noise_hex/node_noise_hex.gml index d1aab63d0..b4282f517 100644 --- a/scripts/node_noise_hex/node_noise_hex.gml +++ b/scripts/node_noise_hex/node_noise_hex.gml @@ -16,9 +16,9 @@ function Node_Noise_Hex(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Float("Seed", self, seed_random(6)) .setDisplay(VALUE_DISPLAY._default, { side_button : button(function() { randomize(); inputs[1].setValue(seed_random(6)); }).setIcon(THEME.icon_random, 0, COLORS._main_icon) }); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0] ); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0] ); - inputs[3] = nodeValue_Vector("Scale", self, [ 8, 8 ] ); + inputs[3] = nodeValue_Vec2("Scale", self, [ 8, 8 ] ); inputs[4] = nodeValue_Surface("Texture sample", self); diff --git a/scripts/node_noise_simplex/node_noise_simplex.gml b/scripts/node_noise_simplex/node_noise_simplex.gml index 6db446680..141029d71 100644 --- a/scripts/node_noise_simplex/node_noise_simplex.gml +++ b/scripts/node_noise_simplex/node_noise_simplex.gml @@ -3,9 +3,9 @@ function Node_Noise_Simplex(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0, 0 ] ); + inputs[1] = nodeValue_Vec3("Position", self, [ 0, 0, 0 ] ); - inputs[2] = nodeValue_Vector("Scale", self, [ 1, 1 ] ) + inputs[2] = nodeValue_Vec2("Scale", self, [ 1, 1 ] ) .setMappable(8); inputs[3] = nodeValue_Int("Iteration", self, 1 ) diff --git a/scripts/node_noise_strand/node_noise_strand.gml b/scripts/node_noise_strand/node_noise_strand.gml index 1d1825fea..003bb7e7f 100644 --- a/scripts/node_noise_strand/node_noise_strand.gml +++ b/scripts/node_noise_strand/node_noise_strand.gml @@ -2,7 +2,7 @@ function Node_Noise_Strand(_x, _y, _group = noone) : Node_Shader_Generator(_x, _ name = "Strand Noise"; shader = sh_noise_strand; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); diff --git a/scripts/node_noise_tri/node_noise_tri.gml b/scripts/node_noise_tri/node_noise_tri.gml index 963a945ff..001452fd4 100644 --- a/scripts/node_noise_tri/node_noise_tri.gml +++ b/scripts/node_noise_tri/node_noise_tri.gml @@ -16,9 +16,9 @@ function Node_Noise_Tri(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[1] = nodeValue_Float("Seed", self, seed_random(6)) .setDisplay(VALUE_DISPLAY._default, { side_button : button(function() { randomize(); inputs[1].setValue(seed_random(6)); }).setIcon(THEME.icon_random, 0, COLORS._main_icon) }); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0] ); + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0] ); - inputs[3] = nodeValue_Vector("Scale", self, [ 4, 4 ] ); + inputs[3] = nodeValue_Vec2("Scale", self, [ 4, 4 ] ); inputs[4] = nodeValue_Surface("Texture sample", self); diff --git a/scripts/node_normal_light/node_normal_light.gml b/scripts/node_normal_light/node_normal_light.gml index 2a254665a..6bddcbab0 100644 --- a/scripts/node_normal_light/node_normal_light.gml +++ b/scripts/node_normal_light/node_normal_light.gml @@ -9,7 +9,7 @@ function Node_Normal_Light(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[3] = nodeValue_Color("Ambient", self, c_black); - inputs[4] = nodeValue_Vector("Light position", self, [ 0, 0 ]) + inputs[4] = nodeValue_Vec2("Light position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[5] = nodeValue_Float("Light range", self, 16); diff --git a/scripts/node_padding/node_padding.gml b/scripts/node_padding/node_padding.gml index e2b23ed47..7c40ccd09 100644 --- a/scripts/node_padding/node_padding.gml +++ b/scripts/node_padding/node_padding.gml @@ -16,7 +16,7 @@ function Node_Padding(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c inputs[5] = nodeValue_Enum_Button("Pad mode", self, 0, [ "Pad out", "Pad to size" ]); - inputs[6] = nodeValue_Vector("Target dimension", self, DEF_SURF) + inputs[6] = nodeValue_Vec2("Target dimension", self, DEF_SURF) inputs[7] = nodeValue_Enum_Button("Horizontal alignment", self, 0 , [ THEME.inspector_surface_halign, THEME.inspector_surface_halign, THEME.inspector_surface_halign]); diff --git a/scripts/node_particle/node_particle.gml b/scripts/node_particle/node_particle.gml index b30b055a4..bf9a7805f 100644 --- a/scripts/node_particle/node_particle.gml +++ b/scripts/node_particle/node_particle.gml @@ -2,13 +2,12 @@ function Node_Particle(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _ name = "Particle"; use_cache = CACHE_USE.auto; - onSurfaceSize = function() { return getInputData(input_len, DEF_SURF); }; + onSurfaceSize = function() { + var _inp = getInputData(input_len, DEF_SURF); + return [ _inp[0], _inp[1] ]; + }; - inputs[3] = nodeValue_Area("Spawn area", self, DEF_AREA_REF, { onSurfaceSize } ) - .rejectArray() - .setUnitRef(onSurfaceSize, VALUE_UNIT.reference); - - inputs[input_len + 0] = nodeValue_Vector("Output dimension", self, DEF_SURF); + inputs[input_len + 0] = nodeValue_Vec2("Output dimension", self, DEF_SURF); inputs[input_len + 1] = nodeValue_Bool("Round position", self, true, "Round position to the closest integer value to avoid jittering."); @@ -19,7 +18,12 @@ function Node_Particle(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _ inputs[input_len + 4] = nodeValue_Enum_Button("Render Type", self, PARTICLE_RENDER_TYPE.surface , [ "Surface", "Line" ]); inputs[input_len + 5] = nodeValue_Int("Line life", self, 4 ); - + + inputs[3] = nodeValue_Area("Spawn area", self, DEF_AREA_REF ) + .setUnitRef(onSurfaceSize, VALUE_UNIT.reference) + .rejectArray() + inputs[3].index = 3; + outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); for(var i = input_len, n = array_length(inputs); i < n; i++) inputs[i].rejectArray(); @@ -49,8 +53,7 @@ function Node_Particle(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _ outputs[0].setValue(_outSurf); } - if(PROJECT.animator.is_playing) - PROJECT.animator.firstFrame(); + if(IS_PLAYING) clearCache(); } static reLoop = function() { @@ -82,11 +85,10 @@ function Node_Particle(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y, _ } static onUpdate = function(frame = CURRENT_FRAME) { - var _inSurf = getInputData(0); - var _dim = getInputData(input_len + 0); - var _bg = getInputData(input_len + 3); - - var _outSurf = outputs[0].getValue(); + var _inSurf = getInputData(0); + var _dim = getInputData(input_len + 0); + var _bg = getInputData(input_len + 3); + var _outSurf = outputs[0].getValue(); if(is_surface(_bg)) _dim = surface_get_dimension(_bg) diff --git a/scripts/node_path_anchor/node_path_anchor.gml b/scripts/node_path_anchor/node_path_anchor.gml index 245de8a5d..5e6275c71 100644 --- a/scripts/node_path_anchor/node_path_anchor.gml +++ b/scripts/node_path_anchor/node_path_anchor.gml @@ -3,12 +3,12 @@ function Node_Path_Anchor(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou color = COLORS.node_blend_number; setDimension(96, 48); - inputs[0] = nodeValue_Vector("Postion", self, [ 0, 0 ] ) + inputs[0] = nodeValue_Vec2("Postion", self, [ 0, 0 ] ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Control point 1", self, [ -16, 0 ] ); + inputs[1] = nodeValue_Vec2("Control point 1", self, [ -16, 0 ] ); - inputs[2] = nodeValue_Vector("Control point 2", self, [ 16, 0 ] ); + inputs[2] = nodeValue_Vec2("Control point 2", self, [ 16, 0 ] ); inputs[3] = nodeValue_Bool("Mirror control point", self, true ); 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 4da3ec55d..d70e229db 100644 --- a/scripts/node_path_l_system/node_path_l_system.gml +++ b/scripts/node_path_l_system/node_path_l_system.gml @@ -18,7 +18,7 @@ function Node_Path_L_System(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr inputs[1] = nodeValue_Rotation("Angle", self, 45); - inputs[2] = nodeValue_Vector("Starting position", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ]); + inputs[2] = nodeValue_Vec2("Starting position", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ]); inputs[3] = nodeValue_Int("Iteration", self, 4); diff --git a/scripts/node_path_plot/node_path_plot.gml b/scripts/node_path_plot/node_path_plot.gml index 643146f56..db06774a6 100644 --- a/scripts/node_path_plot/node_path_plot.gml +++ b/scripts/node_path_plot/node_path_plot.gml @@ -3,7 +3,7 @@ function Node_Path_Plot(_x, _y, _group = noone) : Node(_x, _y, _group) construct length = 0; setDimension(96, 48);; - inputs[0] = nodeValue_Vector("Output scale", self, [ 8, 8 ]); + inputs[0] = nodeValue_Vec2("Output scale", self, [ 8, 8 ]); inputs[1] = nodeValue_Enum_Scroll("Coordinate", self, 0, [ new scrollItem("Cartesian", s_node_axis_type, 0), new scrollItem("Polar", s_node_axis_type, 1), ]); @@ -15,13 +15,13 @@ function Node_Path_Plot(_x, _y, _group = noone) : Node(_x, _y, _group) construct inputs[3] = nodeValue_Text("0 function", self, ""); inputs[4] = nodeValue_Text("1 function", self, ""); - inputs[5] = nodeValue_Vector("Origin", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ] ); + inputs[5] = nodeValue_Vec2("Origin", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ] ); inputs[6] = nodeValue_Slider_Range("Range", self, [ 0, 1 ], { range: [ -1, 1, 0.01 ] }); - inputs[7] = nodeValue_Vector("Input scale", self, [ 1, 1 ]); + inputs[7] = nodeValue_Vec2("Input scale", self, [ 1, 1 ]); - inputs[8] = nodeValue_Vector("Input shift", self, [ 0, 0 ]); + inputs[8] = nodeValue_Vec2("Input shift", self, [ 0, 0 ]); outputs[0] = nodeValue_Output("Path", self, VALUE_TYPE.pathnode, self); diff --git a/scripts/node_path_smooth/node_path_smooth.gml b/scripts/node_path_smooth/node_path_smooth.gml index 3cce6d137..1b60239a8 100644 --- a/scripts/node_path_smooth/node_path_smooth.gml +++ b/scripts/node_path_smooth/node_path_smooth.gml @@ -57,7 +57,7 @@ function Node_Path_Smooth(_x, _y, _group = noone) : Node(_x, _y, _group) constru static createNewInput = function(_x = 0, _y = 0) { #region var index = array_length(inputs); - inputs[index] = nodeValue_Vector("Anchor", self, [ _x, _y ]); + inputs[index] = nodeValue_Vec2("Anchor", self, [ _x, _y ]); recordAction(ACTION_TYPE.list_insert, inputs, [ inputs[index], index, "add path anchor point" ]); resetDisplayList(); diff --git a/scripts/node_path_transform/node_path_transform.gml b/scripts/node_path_transform/node_path_transform.gml index 066c6ee54..840eb67fe 100644 --- a/scripts/node_path_transform/node_path_transform.gml +++ b/scripts/node_path_transform/node_path_transform.gml @@ -5,13 +5,13 @@ function Node_Path_Transform(_x, _y, _group = noone) : Node(_x, _y, _group) cons inputs[0] = nodeValue_PathNode("Path", self, noone) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]); inputs[2] = nodeValue_Rotation("Rotation", self, 0); - inputs[3] = nodeValue_Vector("Scale", self, [ 1, 1 ]); + inputs[3] = nodeValue_Vec2("Scale", self, [ 1, 1 ]); - inputs[4] = nodeValue_Vector("Anchor", self, [ 0, 0 ]); + inputs[4] = nodeValue_Vec2("Anchor", self, [ 0, 0 ]); outputs[0] = nodeValue_Output("Path", self, VALUE_TYPE.pathnode, self); diff --git a/scripts/node_pb_box_divide_grid/node_pb_box_divide_grid.gml b/scripts/node_pb_box_divide_grid/node_pb_box_divide_grid.gml index 7ef655963..0d8d9096e 100644 --- a/scripts/node_pb_box_divide_grid/node_pb_box_divide_grid.gml +++ b/scripts/node_pb_box_divide_grid/node_pb_box_divide_grid.gml @@ -4,7 +4,7 @@ function Node_PB_Box_Divide_Grid(_x, _y, _group = noone) : Node_PB_Box(_x, _y, _ inputs[1] = nodeValue("pBox", self, JUNCTION_CONNECT.input, VALUE_TYPE.pbBox, noone ) .setVisible(true, true); - inputs[2] = nodeValue_Vector("Amount", self, [ 2, 2 ] ); + inputs[2] = nodeValue_Vec2("Amount", self, [ 2, 2 ] ); inputs[3] = nodeValue_Int("Spacing", self, 1 ); diff --git a/scripts/node_pb_box_transform/node_pb_box_transform.gml b/scripts/node_pb_box_transform/node_pb_box_transform.gml index 53e9f374e..2011cb44e 100644 --- a/scripts/node_pb_box_transform/node_pb_box_transform.gml +++ b/scripts/node_pb_box_transform/node_pb_box_transform.gml @@ -4,7 +4,7 @@ function Node_PB_Box_Transform(_x, _y, _group = noone) : Node_PB_Box(_x, _y, _gr inputs[1] = nodeValue("pBox", self, JUNCTION_CONNECT.input, VALUE_TYPE.pbBox, noone ) .setVisible(true, true); - inputs[2] = nodeValue_Vector("Translate", self, [ 0, 0 ] ); + inputs[2] = nodeValue_Vec2("Translate", self, [ 0, 0 ] ); outputs[0] = nodeValue_Output("pBox", self, VALUE_TYPE.pbBox, noone ); diff --git a/scripts/node_pb_fx_brick/node_pb_fx_brick.gml b/scripts/node_pb_fx_brick/node_pb_fx_brick.gml index e055aa29c..43cc7dd88 100644 --- a/scripts/node_pb_fx_brick/node_pb_fx_brick.gml +++ b/scripts/node_pb_fx_brick/node_pb_fx_brick.gml @@ -1,7 +1,7 @@ function Node_PB_Fx_Brick(_x, _y, _group = noone) : Node_PB_Fx(_x, _y, _group) constructor { name = "Brick"; - inputs[1] = nodeValue_Vector("Scale", self, [ 4, 1 ] ); + inputs[1] = nodeValue_Vec2("Scale", self, [ 4, 1 ] ); inputs[2] = nodeValue_Enum_Button("Axis", self, 0 , [ "X", "Y" ] ); @@ -14,7 +14,7 @@ function Node_PB_Fx_Brick(_x, _y, _group = noone) : Node_PB_Fx(_x, _y, _group) c inputs[6] = nodeValue_Int("Detail", self, 1 ) - inputs[7] = nodeValue_Vector("Dissolve Scale", self, [ 4, 4 ] ); + inputs[7] = nodeValue_Vec2("Dissolve Scale", self, [ 4, 4 ] ); input_display_list = [ 0, ["Effect", false], 1, 2, 3, 4, diff --git a/scripts/node_pb_fx_hash/node_pb_fx_hash.gml b/scripts/node_pb_fx_hash/node_pb_fx_hash.gml index 9c28a7f56..8871ac705 100644 --- a/scripts/node_pb_fx_hash/node_pb_fx_hash.gml +++ b/scripts/node_pb_fx_hash/node_pb_fx_hash.gml @@ -12,7 +12,7 @@ function Node_PB_Fx_Hash(_x, _y, _group = noone) : Node_PB_Fx(_x, _y, _group) co inputs[5] = nodeValue_Int("Detail", self, 1 ) - inputs[6] = nodeValue_Vector("Dissolve Scale", self, [ 4, 4 ] ); + inputs[6] = nodeValue_Vec2("Dissolve Scale", self, [ 4, 4 ] ); input_display_list = [ 0, ["Effect", false], 2, 1, 3, diff --git a/scripts/node_perlin/node_perlin.gml b/scripts/node_perlin/node_perlin.gml index 2eb434a4e..d17e6f532 100644 --- a/scripts/node_perlin/node_perlin.gml +++ b/scripts/node_perlin/node_perlin.gml @@ -3,10 +3,10 @@ function Node_Perlin(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 5, 5 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 5, 5 ]) .setMappable(10); inputs[3] = nodeValue_Int("Iteration", self, 4); diff --git a/scripts/node_perlin_extra/node_perlin_extra.gml b/scripts/node_perlin_extra/node_perlin_extra.gml index 8fb8eb27f..44acdf8f9 100644 --- a/scripts/node_perlin_extra/node_perlin_extra.gml +++ b/scripts/node_perlin_extra/node_perlin_extra.gml @@ -2,11 +2,11 @@ function Node_Perlin_Extra(_x, _y, _group = noone) : Node_Shader_Generator(_x, _ name = "Extra Perlins"; shader = sh_perlin_extra; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]) .setMappable(13); addShaderProp(SHADER_UNIFORM.float, "scale"); diff --git a/scripts/node_perlin_smear/node_perlin_smear.gml b/scripts/node_perlin_smear/node_perlin_smear.gml index c4ff62ca5..7991f4074 100644 --- a/scripts/node_perlin_smear/node_perlin_smear.gml +++ b/scripts/node_perlin_smear/node_perlin_smear.gml @@ -3,10 +3,10 @@ function Node_Perlin_Smear(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 6 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 6 ]); inputs[3] = nodeValue_Int("Iteration", self, 3); diff --git a/scripts/node_plot_linear/node_plot_linear.gml b/scripts/node_plot_linear/node_plot_linear.gml index 894bc9f85..1851dda84 100644 --- a/scripts/node_plot_linear/node_plot_linear.gml +++ b/scripts/node_plot_linear/node_plot_linear.gml @@ -29,7 +29,7 @@ function Node_Plot_Linear(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[3] = nodeValue_Float("Sample frequency", self, 1); - inputs[4] = nodeValue_Vector("Origin", self, [ 0, DEF_SURF_H / 2 ]); + inputs[4] = nodeValue_Vec2("Origin", self, [ 0, DEF_SURF_H / 2 ]); inputs[5] = nodeValue_Float("Scale", self, DEF_SURF_W / 2); diff --git a/scripts/node_polar/node_polar.gml b/scripts/node_polar/node_polar.gml index d7d141023..f38a30db7 100644 --- a/scripts/node_polar/node_polar.gml +++ b/scripts/node_polar/node_polar.gml @@ -33,7 +33,7 @@ function Node_Polar(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con ////////////////////////////////////////////////////////////////////////////////////////////////// - inputs[12] = nodeValue_Vector("Tile", self, [ 1, 1 ] ); + inputs[12] = nodeValue_Vec2("Tile", self, [ 1, 1 ] ); outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_pytagorean_tile/node_pytagorean_tile.gml b/scripts/node_pytagorean_tile/node_pytagorean_tile.gml index 2afe6ad63..61c2db29c 100644 --- a/scripts/node_pytagorean_tile/node_pytagorean_tile.gml +++ b/scripts/node_pytagorean_tile/node_pytagorean_tile.gml @@ -3,10 +3,10 @@ function Node_Pytagorean_Tile(_x, _y, _group = noone) : Node_Processor(_x, _y, _ inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 1, 1 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 1, 1 ]) .setMappable(11); inputs[3] = nodeValue_Rotation("Rotation", self, 0) diff --git a/scripts/node_quasicrystal/node_quasicrystal.gml b/scripts/node_quasicrystal/node_quasicrystal.gml index c8a6742db..2d2d675c3 100644 --- a/scripts/node_quasicrystal/node_quasicrystal.gml +++ b/scripts/node_quasicrystal/node_quasicrystal.gml @@ -10,7 +10,7 @@ function Node_Quasicrystal(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[2] = nodeValue_Rotation("Angle", self, 0) .setMappable(7); - inputs[3] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[3] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[4] = nodeValue_Color("Color 1", self, c_white); diff --git a/scripts/node_random_tile/node_random_tile.gml b/scripts/node_random_tile/node_random_tile.gml index 51676a44a..eb4e6291b 100644 --- a/scripts/node_random_tile/node_random_tile.gml +++ b/scripts/node_random_tile/node_random_tile.gml @@ -3,10 +3,10 @@ function Node_Random_Tile(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Scale", self, [ 2, 2 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 2, 2 ]) .setMappable(11); inputs[3] = nodeValue_Rotation("Angle", self, 0) diff --git a/scripts/node_render_sprite_sheet/node_render_sprite_sheet.gml b/scripts/node_render_sprite_sheet/node_render_sprite_sheet.gml index 32a581567..dec2cf2cd 100644 --- a/scripts/node_render_sprite_sheet/node_render_sprite_sheet.gml +++ b/scripts/node_render_sprite_sheet/node_render_sprite_sheet.gml @@ -41,7 +41,7 @@ function Node_Render_Sprite_Sheet(_x, _y, _group = noone) : Node(_x, _y, _group) inputs[8] = nodeValue_Slider_Range("Range", self, [ 0, 0 ]) .setTooltip("Starting/ending frames, set end to 0 to default to last frame.") - inputs[9] = nodeValue_Vector("Spacing", self, [ 0, 0 ]); + inputs[9] = nodeValue_Vec2("Spacing", self, [ 0, 0 ]); inputs[10] = nodeValue_Bool("Overlappable", self, false); diff --git a/scripts/node_repeat/node_repeat.gml b/scripts/node_repeat/node_repeat.gml index 25751c5cf..36ab970e9 100644 --- a/scripts/node_repeat/node_repeat.gml +++ b/scripts/node_repeat/node_repeat.gml @@ -31,7 +31,7 @@ function Node_Repeat(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co new scrollItem("Grid", s_node_repeat_axis, 1), new scrollItem("Circular", s_node_repeat_axis, 2), ]); - inputs[4] = nodeValue_Vector("Shift position", self, [ DEF_SURF_W / 2, 0 ]) + inputs[4] = nodeValue_Vec2("Shift position", self, [ DEF_SURF_W / 2, 0 ]) .setUnitRef(function() { return getDimension(); }); inputs[5] = nodeValue_Rotation_Range("Repeat rotation", self, [0, 0]); @@ -42,7 +42,7 @@ function Node_Repeat(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[8] = nodeValue_Float("Radius", self, 1); - inputs[9] = nodeValue_Vector("Start position", self, [0, 0]) + inputs[9] = nodeValue_Vec2("Start position", self, [0, 0]) .setUnitRef(function(index) { return getInputData(1); }); inputs[10] = nodeValue("Scale over copy", self, JUNCTION_CONNECT.input, VALUE_TYPE.curve, CURVE_DEF_11 ); @@ -68,7 +68,7 @@ function Node_Repeat(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[18] = nodeValue_Int("Column", self, 4); - inputs[19] = nodeValue_Vector("Column shift", self, [0, DEF_SURF_H / 2]) + inputs[19] = nodeValue_Vec2("Column shift", self, [0, DEF_SURF_H / 2]) .setUnitRef(function() { return getDimension(); }); inputs[20] = nodeValue_Float("Animator midpoint", self, 0.5) @@ -77,11 +77,11 @@ function Node_Repeat(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[21] = nodeValue_Float("Animator range", self, 0.1) .setDisplay(VALUE_DISPLAY.slider); - inputs[22] = nodeValue_Vector("Animator position", self, [ 0, 0 ]); + inputs[22] = nodeValue_Vec2("Animator position", self, [ 0, 0 ]); inputs[23] = nodeValue_Rotation("Animator rotation", self, 0); - inputs[24] = nodeValue_Vector("Animator scale", self, [ 0, 0 ]); + inputs[24] = nodeValue_Vec2("Animator scale", self, [ 0, 0 ]); inputs[25] = nodeValue("Animator falloff", self, JUNCTION_CONNECT.input, VALUE_TYPE.curve, CURVE_DEF_10); diff --git a/scripts/node_repeat_texture/node_repeat_texture.gml b/scripts/node_repeat_texture/node_repeat_texture.gml index 76da7981b..a98bca1d4 100644 --- a/scripts/node_repeat_texture/node_repeat_texture.gml +++ b/scripts/node_repeat_texture/node_repeat_texture.gml @@ -4,7 +4,7 @@ function Node_Repeat_Texture(_x, _y, _group = noone) : Node_Processor(_x, _y, _g inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Target dimension", self, DEF_SURF); + inputs[1] = nodeValue_Vec2("Target dimension", self, DEF_SURF); inputs[2] = nodeValue_Enum_Scroll("Type", self, 1, [ "Tile", "Scatter", "Cell" ]); diff --git a/scripts/node_rigid_force_apply/node_rigid_force_apply.gml b/scripts/node_rigid_force_apply/node_rigid_force_apply.gml index 122b0fbf2..f300924b5 100644 --- a/scripts/node_rigid_force_apply/node_rigid_force_apply.gml +++ b/scripts/node_rigid_force_apply/node_rigid_force_apply.gml @@ -12,7 +12,7 @@ function Node_Rigid_Force_Apply(_x, _y, _group = noone) : Node(_x, _y, _group) c inputs[1] = nodeValue_Enum_Scroll("Force type", self, 0, [ "Constant", "Impulse", "Torque", "Explode" ]) .rejectArray(); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[2] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .rejectArray(); inputs[3] = nodeValue_Float("Torque", self, 0) @@ -21,7 +21,7 @@ function Node_Rigid_Force_Apply(_x, _y, _group = noone) : Node(_x, _y, _group) c inputs[4] = nodeValue_Int("Apply frame", self, 0, "Frame index to apply force.") .rejectArray(); - inputs[5] = nodeValue_Vector("Force", self, [ 0.1, 0 ]) + inputs[5] = nodeValue_Vec2("Force", self, [ 0.1, 0 ]) .rejectArray(); inputs[6] = nodeValue_Enum_Button("Scope", self, 0, [ "Global", "Local" ]) diff --git a/scripts/node_rigid_global/node_rigid_global.gml b/scripts/node_rigid_global/node_rigid_global.gml index 270aedadb..5cd9af17f 100644 --- a/scripts/node_rigid_global/node_rigid_global.gml +++ b/scripts/node_rigid_global/node_rigid_global.gml @@ -8,7 +8,7 @@ function Node_Rigid_Global(_x, _y, _group = noone) : Node(_x, _y, _group) constr object = noone; - inputs[0] = nodeValue_Vector("Gravity", self, [ 0, 10 ]); + inputs[0] = nodeValue_Vec2("Gravity", self, [ 0, 10 ]); current_gra = [0, 0]; diff --git a/scripts/node_rigid_group_inline/node_rigid_group_inline.gml b/scripts/node_rigid_group_inline/node_rigid_group_inline.gml index d8b3e9cbe..2421e9c30 100644 --- a/scripts/node_rigid_group_inline/node_rigid_group_inline.gml +++ b/scripts/node_rigid_group_inline/node_rigid_group_inline.gml @@ -6,7 +6,7 @@ function Node_Rigid_Group_Inline(_x, _y, _group = noone) : Node_Collection_Inlin is_simulation = true; manual_ungroupable = false; - inputs[0] = nodeValue_Vector("Gravity", self, [ 0, 10 ]); + inputs[0] = nodeValue_Vec2("Gravity", self, [ 0, 10 ]); if(NODE_NEW_MANUAL) { var _object = nodeBuild("Node_Rigid_Object", x, y); diff --git a/scripts/node_rigid_object/node_rigid_object.gml b/scripts/node_rigid_object/node_rigid_object.gml index 9839a126d..acf6b685e 100644 --- a/scripts/node_rigid_object/node_rigid_object.gml +++ b/scripts/node_rigid_object/node_rigid_object.gml @@ -42,7 +42,7 @@ function Node_Rigid_Object(_x, _y, _group = noone) : Node(_x, _y, _group) constr inputs[6] = nodeValue_Surface("Texture", self) .setAnimable(false); - inputs[7] = nodeValue_Vector("Start position", self, [ 16, 16 ]) + inputs[7] = nodeValue_Vec2("Start position", self, [ 16, 16 ]) .setAnimable(false); inputs[8] = nodeValue_Bool("Spawn", self, true, "Make object spawn when start.") diff --git a/scripts/node_rigid_override/node_rigid_override.gml b/scripts/node_rigid_override/node_rigid_override.gml index da7cc4d3c..2356b4c5b 100644 --- a/scripts/node_rigid_override/node_rigid_override.gml +++ b/scripts/node_rigid_override/node_rigid_override.gml @@ -10,9 +10,9 @@ function Node_Rigid_Override(_x, _y, _group = noone) : Node(_x, _y, _group) cons inputs[0] = nodeValue("Object", self, JUNCTION_CONNECT.input, VALUE_TYPE.rigid, noone ) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Positions", self, [0, 0] ); + inputs[1] = nodeValue_Vec2("Positions", self, [0, 0] ); - inputs[2] = nodeValue_Vector("Scales", self, [0, 0] ); + inputs[2] = nodeValue_Vec2("Scales", self, [0, 0] ); inputs[3] = nodeValue_Float("Rotations", self, 0 ); @@ -20,7 +20,7 @@ function Node_Rigid_Override(_x, _y, _group = noone) : Node(_x, _y, _group) cons inputs[5] = nodeValue_Float("Alpha", self, 0 ); - inputs[6] = nodeValue_Vector("Velocity", self, [0, 0] ); + inputs[6] = nodeValue_Vec2("Velocity", self, [0, 0] ); outputs[0] = nodeValue_Output("Object", self, VALUE_TYPE.rigid, noone ); diff --git a/scripts/node_rigid_render/node_rigid_render.gml b/scripts/node_rigid_render/node_rigid_render.gml index 57106cfa2..d6b3533b7 100644 --- a/scripts/node_rigid_render/node_rigid_render.gml +++ b/scripts/node_rigid_render/node_rigid_render.gml @@ -8,7 +8,7 @@ function Node_Rigid_Render(_x, _y, _group = noone) : Node(_x, _y, _group) constr //use_cache = CACHE_USE.auto; update_on_frame = true; - inputs[0] = nodeValue_Vector("Render dimension", self, DEF_SURF); + inputs[0] = nodeValue_Vec2("Render dimension", self, DEF_SURF); inputs[1] = nodeValue_Bool("Round position", self, false) diff --git a/scripts/node_rigid_render_output/node_rigid_render_output.gml b/scripts/node_rigid_render_output/node_rigid_render_output.gml index 702bbafd4..1641c14bb 100644 --- a/scripts/node_rigid_render_output/node_rigid_render_output.gml +++ b/scripts/node_rigid_render_output/node_rigid_render_output.gml @@ -7,7 +7,7 @@ function Node_Rigid_Render_Output(_x, _y, _group = noone) : Node_Group_Output(_x previewable = true; - inputs[0] = nodeValue_Vector("Render dimension", self, DEF_SURF) + inputs[0] = nodeValue_Vec2("Render dimension", self, DEF_SURF) .rejectArray(); inputs[1] = nodeValue_Bool("Round position", self, false) diff --git a/scripts/node_rm_cloud/node_rm_cloud.gml b/scripts/node_rm_cloud/node_rm_cloud.gml index 977d9b8f5..bd91d8414 100644 --- a/scripts/node_rm_cloud/node_rm_cloud.gml +++ b/scripts/node_rm_cloud/node_rm_cloud.gml @@ -3,9 +3,9 @@ function Node_RM_Cloud(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Dimension(self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0, 0 ]); + inputs[1] = nodeValue_Vec3("Position", self, [ 0, 0, 0 ]); - inputs[2] = nodeValue_Vector("Rotation", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Rotation", self, [ 0, 0, 0 ]); inputs[3] = nodeValue_Float("Scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] }); @@ -13,7 +13,7 @@ function Node_RM_Cloud(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[4] = nodeValue_Float("FOV", self, 30) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 90, 1 ] }); - inputs[5] = nodeValue_Vector("View Range", self, [ 0, 6 ]); + inputs[5] = nodeValue_Vec2("View Range", self, [ 0, 6 ]); inputs[6] = nodeValue_Float("Density", self, 0.5) .setDisplay(VALUE_DISPLAY.slider); diff --git a/scripts/node_rm_combine/node_rm_combine.gml b/scripts/node_rm_combine/node_rm_combine.gml index 2b932c6ef..5b80489dc 100644 --- a/scripts/node_rm_combine/node_rm_combine.gml +++ b/scripts/node_rm_combine/node_rm_combine.gml @@ -12,7 +12,7 @@ function Node_RM_Combine(_x, _y, _group = noone) : Node_RM(_x, _y, _group) const inputs[3] = nodeValue_Float("Ortho Scale", self, 5.) - inputs[4] = nodeValue_Vector("View Range", self, [ 3, 6 ]); + inputs[4] = nodeValue_Vec2("View Range", self, [ 3, 6 ]); inputs[5] = nodeValue_Float("Depth", self, 0) .setDisplay(VALUE_DISPLAY.slider); @@ -24,11 +24,11 @@ function Node_RM_Combine(_x, _y, _group = noone) : Node_RM(_x, _y, _group) const inputs[8] = nodeValue_Float("Ambient Level", self, 0.2) .setDisplay(VALUE_DISPLAY.slider); - inputs[9] = nodeValue_Vector("Light Position", self, [ -.4, -.5, 1 ]); + inputs[9] = nodeValue_Vec3("Light Position", self, [ -.4, -.5, 1 ]); inputs[10] = nodeValue_Surface("Environment", self); - inputs[11] = nodeValue_Vector("Camera Rotation", self, [ 30, 45, 0 ]); + inputs[11] = nodeValue_Vec3("Camera Rotation", self, [ 30, 45, 0 ]); inputs[12] = nodeValue_Float("Camera Scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] }); diff --git a/scripts/node_rm_primitive/node_rm_primitive.gml b/scripts/node_rm_primitive/node_rm_primitive.gml index 3322429ea..0d4fb2be8 100644 --- a/scripts/node_rm_primitive/node_rm_primitive.gml +++ b/scripts/node_rm_primitive/node_rm_primitive.gml @@ -20,9 +20,9 @@ function Node_RM_Primitive(_x, _y, _group = noone) : Node_RM(_x, _y, _group) con inputs[1] = nodeValue_Enum_Scroll("Shape", self, 1, { data: shape_types_str, horizontal: true, text_pad: ui(16) }); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Position", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Rotation", self, [ 0, 0, 0 ]); + inputs[3] = nodeValue_Vec3("Rotation", self, [ 0, 0, 0 ]); inputs[4] = nodeValue_Float("Scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] }); @@ -30,19 +30,19 @@ function Node_RM_Primitive(_x, _y, _group = noone) : Node_RM(_x, _y, _group) con inputs[5] = nodeValue_Float("FOV", self, 30) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 90, 1 ] }); - inputs[6] = nodeValue_Vector("View Range", self, [ 3, 6 ]); + inputs[6] = nodeValue_Vec2("View Range", self, [ 3, 6 ]); inputs[7] = nodeValue_Float("Depth", self, 0) .setDisplay(VALUE_DISPLAY.slider); - inputs[8] = nodeValue_Vector("Light Position", self, [ -.4, -.5, 1 ]); + inputs[8] = nodeValue_Vec3("Light Position", self, [ -.4, -.5, 1 ]); inputs[9] = nodeValue_Color("Base Color", self, c_white); inputs[10] = nodeValue_Float("Ambient Level", self, 0.2) .setDisplay(VALUE_DISPLAY.slider); - inputs[11] = nodeValue_Vector("Elongate", self, [ 0, 0, 0 ]); + inputs[11] = nodeValue_Vec3("Elongate", self, [ 0, 0, 0 ]); inputs[12] = nodeValue_Float("Rounded", self, 0.) .setDisplay(VALUE_DISPLAY.slider); @@ -51,22 +51,22 @@ function Node_RM_Primitive(_x, _y, _group = noone) : Node_RM(_x, _y, _group) con inputs[14] = nodeValue_Float("Ortho Scale", self, 1.) - inputs[15] = nodeValue_Vector("Wave Amplitude", self, [ 4, 4, 4 ]); + inputs[15] = nodeValue_Vec3("Wave Amplitude", self, [ 4, 4, 4 ]); - inputs[16] = nodeValue_Vector("Wave Intensity", self, [ 0, 0, 0 ]); + inputs[16] = nodeValue_Vec3("Wave Intensity", self, [ 0, 0, 0 ]); - inputs[17] = nodeValue_Vector("Wave Phase", self, [ 0, 0, 0 ]); + inputs[17] = nodeValue_Vec3("Wave Phase", self, [ 0, 0, 0 ]); inputs[18] = nodeValue_Enum_Button("Twist Axis", self, 0, [ "X", "Y", "Z" ]); inputs[19] = nodeValue_Float("Twist Amount", self, 0) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 8, 0.1 ] }); - inputs[20] = nodeValue_Vector("Tile Distance", self, [ 1, 1, 1 ]); + inputs[20] = nodeValue_Vec3("Tile Distance", self, [ 1, 1, 1 ]); ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// - inputs[21] = nodeValue_Vector("Size", self, [ 1, 1, 1 ]); + inputs[21] = nodeValue_Vec3("Size", self, [ 1, 1, 1 ]); inputs[22] = nodeValue_Float("Radius", self, .7) .setDisplay(VALUE_DISPLAY.slider); @@ -89,7 +89,7 @@ function Node_RM_Primitive(_x, _y, _group = noone) : Node_RM(_x, _y, _group) con ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// - inputs[29] = nodeValue_Vector("Tile Amount", self, [ 1, 1, 1 ]); + inputs[29] = nodeValue_Vec3("Tile Amount", self, [ 1, 1, 1 ]); inputs[30] = nodeValue_Color("Background", self, c_black); @@ -114,15 +114,15 @@ function Node_RM_Primitive(_x, _y, _group = noone) : Node_RM(_x, _y, _group) con inputs[38] = nodeValue_Float("Texture Scale", self, 1.); - inputs[39] = nodeValue_Vector("Corner", self, [ 0.25, 0.25, 0.25, 0.25 ]); + inputs[39] = nodeValue_Vec4("Corner", self, [ 0.25, 0.25, 0.25, 0.25 ]); - inputs[40] = nodeValue_Vector("2D Size", self, [ 0.5, 0.5 ]); + inputs[40] = nodeValue_Vec2("2D Size", self, [ 0.5, 0.5 ]); inputs[41] = nodeValue_Int("Side", self, 3); ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// - inputs[42] = nodeValue_Vector("Camera Rotation", self, [ 30, 45, 0 ]); + inputs[42] = nodeValue_Vec3("Camera Rotation", self, [ 30, 45, 0 ]); inputs[43] = nodeValue_Float("Camera Scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] }); @@ -133,9 +133,9 @@ function Node_RM_Primitive(_x, _y, _group = noone) : Node_RM(_x, _y, _group) con inputs[45] = nodeValue_Bool("Tile", self, false); - inputs[46] = nodeValue_Vector("Tiled Shift", self, [ 0, 0, 0 ]); + inputs[46] = nodeValue_Vec3("Tiled Shift", self, [ 0, 0, 0 ]); - inputs[47] = nodeValue_Vector("Tiled Rotation", self, [ 0, 0, 0 ]); + inputs[47] = nodeValue_Vec3("Tiled Rotation", self, [ 0, 0, 0 ]); inputs[48] = nodeValue_Float("Tiled Scale", self, 0); diff --git a/scripts/node_rm_render/node_rm_render.gml b/scripts/node_rm_render/node_rm_render.gml index 0503e20e4..eb4f3591b 100644 --- a/scripts/node_rm_render/node_rm_render.gml +++ b/scripts/node_rm_render/node_rm_render.gml @@ -12,7 +12,7 @@ function Node_RM_Render(_x, _y, _group = noone) : Node_RM(_x, _y, _group) constr inputs[3] = nodeValue_Float("Ortho Scale", self, 5.) - inputs[4] = nodeValue_Vector("View Range", self, [ 3, 6 ]); + inputs[4] = nodeValue_Vec2("View Range", self, [ 3, 6 ]); inputs[5] = nodeValue_Float("Depth", self, 0) .setDisplay(VALUE_DISPLAY.slider); @@ -24,11 +24,11 @@ function Node_RM_Render(_x, _y, _group = noone) : Node_RM(_x, _y, _group) constr inputs[8] = nodeValue_Float("Ambient Level", self, 0.2) .setDisplay(VALUE_DISPLAY.slider); - inputs[9] = nodeValue_Vector("Light Position", self, [ -.4, -.5, 1 ]); + inputs[9] = nodeValue_Vec3("Light Position", self, [ -.4, -.5, 1 ]); inputs[10] = nodeValue_Surface("Environment", self); - inputs[11] = nodeValue_Vector("Camera Rotation", self, [ 30, 45, 0 ]); + inputs[11] = nodeValue_Vec3("Camera Rotation", self, [ 30, 45, 0 ]); inputs[12] = nodeValue_Float("Camera Scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] }); diff --git a/scripts/node_rm_terrain/node_rm_terrain.gml b/scripts/node_rm_terrain/node_rm_terrain.gml index 819fc1405..0ec69e28d 100644 --- a/scripts/node_rm_terrain/node_rm_terrain.gml +++ b/scripts/node_rm_terrain/node_rm_terrain.gml @@ -5,9 +5,9 @@ function Node_RM_Terrain(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[1] = nodeValue_Surface("Surface", self); - inputs[2] = nodeValue_Vector("Position", self, [ 0, 0, 0 ]); + inputs[2] = nodeValue_Vec3("Position", self, [ 0, 0, 0 ]); - inputs[3] = nodeValue_Vector("Rotation", self, [ 30, 45, 0 ]); + inputs[3] = nodeValue_Vec3("Rotation", self, [ 30, 45, 0 ]); inputs[4] = nodeValue_Float("Scale", self, 1) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] }); @@ -15,7 +15,7 @@ function Node_RM_Terrain(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[5] = nodeValue_Float("FOV", self, 30) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 90, 1 ] }); - inputs[6] = nodeValue_Vector("View Range", self, [ 0, 6 ]); + inputs[6] = nodeValue_Vec2("View Range", self, [ 0, 6 ]); inputs[7] = nodeValue_Float("BG Bleed", self, 1) .setDisplay(VALUE_DISPLAY.slider); @@ -33,7 +33,7 @@ function Node_RM_Terrain(_x, _y, _group = noone) : Node_Processor(_x, _y, _group inputs[13] = nodeValue_Surface("Reflection", self); - inputs[14] = nodeValue_Vector("Sun Position", self, [ .5, 1, .5 ]); + inputs[14] = nodeValue_Vec3("Sun Position", self, [ .5, 1, .5 ]); inputs[15] = nodeValue_Float("Shadow", self, 0.2) .setDisplay(VALUE_DISPLAY.slider); diff --git a/scripts/node_sampler/node_sampler.gml b/scripts/node_sampler/node_sampler.gml index 27ab1dcc8..d20a857ac 100644 --- a/scripts/node_sampler/node_sampler.gml +++ b/scripts/node_sampler/node_sampler.gml @@ -4,7 +4,7 @@ function Node_Sampler(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[2] = nodeValue_Int("Sampling size", self, 1, "Size of square around the position to sample and average pixel color.") diff --git a/scripts/node_scale/node_scale.gml b/scripts/node_scale/node_scale.gml index 80f8c4a9b..78bd26b18 100644 --- a/scripts/node_scale/node_scale.gml +++ b/scripts/node_scale/node_scale.gml @@ -10,7 +10,7 @@ function Node_Scale(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[2] = nodeValue_Enum_Button("Mode", self, 0, [ "Upscale", "Scale to fit" ]); - inputs[3] = nodeValue_Vector("Target dimension", self, DEF_SURF); + inputs[3] = nodeValue_Vec2("Target dimension", self, DEF_SURF); inputs[4] = nodeValue_Bool("Active", self, true); active_index = 4; diff --git a/scripts/node_scatter/node_scatter.gml b/scripts/node_scatter/node_scatter.gml index c2c0d038f..14f4df1f1 100644 --- a/scripts/node_scatter/node_scatter.gml +++ b/scripts/node_scatter/node_scatter.gml @@ -88,7 +88,7 @@ function Node_Scatter(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c ////////////////////////////////////////////////////////////////////////////////////////////////// - inputs[30] = nodeValue_Vector("Uniform amount", self, [ 4, 4 ]); + inputs[30] = nodeValue_Vec2("Uniform amount", self, [ 4, 4 ]); inputs[31] = nodeValue_Bool("Auto amount", self, false); @@ -96,11 +96,11 @@ function Node_Scatter(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c inputs[33] = nodeValue_Vec2_Range("Random position", self, [ 0, 0, 0, 0 ]); - inputs[34] = nodeValue_Vector("Scale per radius", self, [ 0, 0 ]); + inputs[34] = nodeValue_Vec2("Scale per radius", self, [ 0, 0 ]); inputs[35] = nodeValue_Rotation_Range("Angle range", self, [ 0, 360 ]); - inputs[36] = nodeValue_Vector("Shift position", self, [ 0, 0 ]); + inputs[36] = nodeValue_Vec2("Shift position", self, [ 0, 0 ]); inputs[37] = nodeValue_Bool("Exact", self, false) diff --git a/scripts/node_scatter_points/node_scatter_points.gml b/scripts/node_scatter_points/node_scatter_points.gml index 53d628509..ba4f021b1 100644 --- a/scripts/node_scatter_points/node_scatter_points.gml +++ b/scripts/node_scatter_points/node_scatter_points.gml @@ -26,7 +26,7 @@ function Node_Scatter_Points(_x, _y, _group = noone) : Node(_x, _y, _group) cons inputs[6] = nodeValue_Bool("Fixed position", self, false, "Fix point position, and only select point in the area."); - inputs[7] = nodeValue_Vector("Reference dimension", self, DEF_SURF); + inputs[7] = nodeValue_Vec2("Reference dimension", self, DEF_SURF); inputs[8] = nodeValue_Surface("Reference value", self); diff --git a/scripts/node_shadow/node_shadow.gml b/scripts/node_shadow/node_shadow.gml index 8a8ba2a60..3e4c3f281 100644 --- a/scripts/node_shadow/node_shadow.gml +++ b/scripts/node_shadow/node_shadow.gml @@ -7,7 +7,7 @@ function Node_Shadow(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[2] = nodeValue_Float("Strength", self, .5) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 2, 0.01] }); - inputs[3] = nodeValue_Vector("Shift", self, [ 4, 4 ]) + inputs[3] = nodeValue_Vec2("Shift", self, [ 4, 4 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[4] = nodeValue_Float("Grow", self, 3) @@ -28,7 +28,7 @@ function Node_Shadow(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[11] = nodeValue_Enum_Scroll("Positioning", self, 0, [ "Shift", "Light" ]); - inputs[12] = nodeValue_Vector("Light Position", self, [ 0, 0 ]) + inputs[12] = nodeValue_Vec2("Light Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_shadow_cast/node_shadow_cast.gml b/scripts/node_shadow_cast/node_shadow_cast.gml index 7c2e011ff..9021a8d1c 100644 --- a/scripts/node_shadow_cast/node_shadow_cast.gml +++ b/scripts/node_shadow_cast/node_shadow_cast.gml @@ -6,7 +6,7 @@ function Node_Shadow_Cast(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou inputs[1] = nodeValue_Surface("Solid", self); - inputs[2] = nodeValue_Vector("Light Position", self, [ 0, 0 ]) + inputs[2] = nodeValue_Vec2("Light Position", self, [ 0, 0 ]) .setUnitRef(function(index) { var _surf = getInputData(0); if(is_array(_surf) && array_length(_surf) == 0) diff --git a/scripts/node_shape/node_shape.gml b/scripts/node_shape/node_shape.gml index 18917e0fd..477baefe1 100644 --- a/scripts/node_shape/node_shape.gml +++ b/scripts/node_shape/node_shape.gml @@ -90,10 +90,10 @@ function Node_Shape(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[15] = nodeValue_Enum_Scroll("Positioning Mode", self, 0, [ "Area", "Center + Scale", "Full Image" ]) - inputs[16] = nodeValue_Vector("Center", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ] ) + inputs[16] = nodeValue_Vec2("Center", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ] ) .setUnitRef(onSurfaceSize); - inputs[17] = nodeValue_Vector("Half Size", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ] ) + inputs[17] = nodeValue_Vec2("Half Size", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ] ) .setUnitRef(onSurfaceSize); inputs[18] = nodeValue_Bool("Tile", self, false); @@ -113,7 +113,7 @@ function Node_Shape(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[25] = nodeValue_Int("Teeth Amount", self, 6 ); - inputs[26] = nodeValue_Vector("Teeth Size", self, [ 0.2, 0.2 ] , { slideSpeed : 0.01 }); + inputs[26] = nodeValue_Vec2("Teeth Size", self, [ 0.2, 0.2 ] , { slideSpeed : 0.01 }); inputs[27] = nodeValue_Rotation("Teeth Rotation", self, 0); diff --git a/scripts/node_shape_map/node_shape_map.gml b/scripts/node_shape_map/node_shape_map.gml index c73d930c6..2ca8da598 100644 --- a/scripts/node_shape_map/node_shape_map.gml +++ b/scripts/node_shape_map/node_shape_map.gml @@ -9,7 +9,7 @@ function Node_Shape_Map(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[2] = nodeValue_Enum_Scroll("Shape", self, 0, [ new scrollItem("Circle", s_node_shape_circle, 0), new scrollItem("Polygon", s_node_shape_misc, 1), ]); - inputs[3] = nodeValue_Vector("Map Scale", self, [ 4, 1 ]); + inputs[3] = nodeValue_Vec2("Map Scale", self, [ 4, 1 ]); inputs[4] = nodeValue_Float("Radius", self, 0.5); diff --git a/scripts/node_shape_polygon/node_shape_polygon.gml b/scripts/node_shape_polygon/node_shape_polygon.gml index 0ead6d3f8..5ce8e2ec2 100644 --- a/scripts/node_shape_polygon/node_shape_polygon.gml +++ b/scripts/node_shape_polygon/node_shape_polygon.gml @@ -16,12 +16,12 @@ function Node_Shape_Polygon(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr inputs[4] = nodeValue_Enum_Scroll("Shape", self, 0, shapesArray); - inputs[5] = nodeValue_Vector("Position", self, [ 0.5, 0.5 ]) + inputs[5] = nodeValue_Vec2("Position", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[6] = nodeValue_Rotation("Rotation", self, 0); - inputs[7] = nodeValue_Vector("Scale", self, [ 0.5, 0.5 ]) + inputs[7] = nodeValue_Vec2("Scale", self, [ 0.5, 0.5 ]) .setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference); inputs[8] = nodeValue_Int("Sides", self, 16) diff --git a/scripts/node_shard_noise/node_shard_noise.gml b/scripts/node_shard_noise/node_shard_noise.gml index 37d2c8ad9..ed95b22c0 100644 --- a/scripts/node_shard_noise/node_shard_noise.gml +++ b/scripts/node_shard_noise/node_shard_noise.gml @@ -2,11 +2,11 @@ function Node_Shard_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x, _y name = "Shard Noise"; shader = sh_noise_shard; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]) .setMappable(6); addShaderProp(SHADER_UNIFORM.float, "scale"); diff --git a/scripts/node_skew/node_skew.gml b/scripts/node_skew/node_skew.gml index 44b9b2bd8..e01700975 100644 --- a/scripts/node_skew/node_skew.gml +++ b/scripts/node_skew/node_skew.gml @@ -10,7 +10,7 @@ function Node_Skew(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[3] = nodeValue_Bool("Wrap", self, false); - inputs[4] = nodeValue_Vector("Center", self, [0, 0] , { side_button : button(function() { centerAnchor(); }) + inputs[4] = nodeValue_Vec2("Center", self, [0, 0] , { side_button : button(function() { centerAnchor(); }) .setIcon(THEME.anchor) .setTooltip(__txt("Set to center")) }); diff --git a/scripts/node_smoke_add/node_smoke_add.gml b/scripts/node_smoke_add/node_smoke_add.gml index 880faff15..644b9f543 100644 --- a/scripts/node_smoke_add/node_smoke_add.gml +++ b/scripts/node_smoke_add/node_smoke_add.gml @@ -11,7 +11,7 @@ function Node_Smoke_Add(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) con inputs[1] = nodeValue_Surface("Fluid brush", self); - inputs[2] = nodeValue_Vector("Position", self, [0, 0]); + inputs[2] = nodeValue_Vec2("Position", self, [0, 0]); inputs[3] = nodeValue_Bool("Active", self, true); @@ -23,7 +23,7 @@ function Node_Smoke_Add(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) con inputs[6] = nodeValue_Int("Expand velocity mask", self, 0); - inputs[7] = nodeValue_Vector("Velocity", self, [0, 0]); + inputs[7] = nodeValue_Vec2("Velocity", self, [0, 0]); input_display_list = [ ["Domain", false], 0, diff --git a/scripts/node_smoke_apply_velocity/node_smoke_apply_velocity.gml b/scripts/node_smoke_apply_velocity/node_smoke_apply_velocity.gml index 85952772a..e04dbea5a 100644 --- a/scripts/node_smoke_apply_velocity/node_smoke_apply_velocity.gml +++ b/scripts/node_smoke_apply_velocity/node_smoke_apply_velocity.gml @@ -9,9 +9,9 @@ function Node_Smoke_Apply_Velocity(_x, _y, _group = noone) : Node_Smoke(_x, _y, inputs[1] = nodeValue_Surface("Brush", self); - inputs[2] = nodeValue_Vector("Position", self, [0, 0]); + inputs[2] = nodeValue_Vec2("Position", self, [0, 0]); - inputs[3] = nodeValue_Vector("Velocity", self, [0, 0]); + inputs[3] = nodeValue_Vec2("Velocity", self, [0, 0]); inputs[4] = nodeValue_Bool("Active", self, true); diff --git a/scripts/node_smoke_domain/node_smoke_domain.gml b/scripts/node_smoke_domain/node_smoke_domain.gml index 82c2726a6..17b320cc1 100644 --- a/scripts/node_smoke_domain/node_smoke_domain.gml +++ b/scripts/node_smoke_domain/node_smoke_domain.gml @@ -19,9 +19,9 @@ function Node_Smoke_Domain(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) inputs[5] = nodeValue_Float("Velocity dissipation", self, 0.00) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 0.1, 0.01 ] }); - inputs[6] = nodeValue_Vector("Acceleration", self, [ 0, 0 ]); + inputs[6] = nodeValue_Vec2("Acceleration", self, [ 0, 0 ]); - inputs[7] = nodeValue_Vector("Material intertia", self, [ 1, -0.2 ]); + inputs[7] = nodeValue_Vec2("Material intertia", self, [ 1, -0.2 ]); inputs[8] = nodeValue_Float("Initial pressure", self, 0.75) .setDisplay(VALUE_DISPLAY.slider); diff --git a/scripts/node_smoke_group/node_smoke_group.gml b/scripts/node_smoke_group/node_smoke_group.gml index 17efe02fa..0f51aab48 100644 --- a/scripts/node_smoke_group/node_smoke_group.gml +++ b/scripts/node_smoke_group/node_smoke_group.gml @@ -26,9 +26,9 @@ function Node_Smoke_Group(_x, _y, _group = noone) : Node_Collection(_x, _y, _gro inputs[5] = nodeValue_Float("Velocity dissipation", self, 0.00) .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 0.1, 0.01 ] }); - inputs[6] = nodeValue_Vector("Acceleration", self, [ 0, 0 ]); + inputs[6] = nodeValue_Vec2("Acceleration", self, [ 0, 0 ]); - inputs[7] = nodeValue_Vector("Material intertia", self, [ 1, -0.2 ]); + inputs[7] = nodeValue_Vec2("Material intertia", self, [ 1, -0.2 ]); inputs[8] = nodeValue_Float("Initial pressure", self, 0.75) .setDisplay(VALUE_DISPLAY.slider); diff --git a/scripts/node_smoke_repulse/node_smoke_repulse.gml b/scripts/node_smoke_repulse/node_smoke_repulse.gml index 4b24d3607..808a0fefc 100644 --- a/scripts/node_smoke_repulse/node_smoke_repulse.gml +++ b/scripts/node_smoke_repulse/node_smoke_repulse.gml @@ -7,7 +7,7 @@ function Node_Smoke_Repulse(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) inputs[0] = nodeValue("Domain", self, JUNCTION_CONNECT.input, VALUE_TYPE.sdomain, noone) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [0, 0]); + inputs[1] = nodeValue_Vec2("Position", self, [0, 0]); inputs[2] = nodeValue_Float("Radius", self, 8); diff --git a/scripts/node_smoke_vortex/node_smoke_vortex.gml b/scripts/node_smoke_vortex/node_smoke_vortex.gml index ed42dc2e1..261f7a15e 100644 --- a/scripts/node_smoke_vortex/node_smoke_vortex.gml +++ b/scripts/node_smoke_vortex/node_smoke_vortex.gml @@ -7,7 +7,7 @@ function Node_Smoke_Vortex(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) inputs[0] = nodeValue("Domain", self, JUNCTION_CONNECT.input, VALUE_TYPE.sdomain, noone) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Position", self, [0, 0]); + inputs[1] = nodeValue_Vec2("Position", self, [0, 0]); inputs[2] = nodeValue_Float("Radius", self, 8); diff --git a/scripts/node_spherize/node_spherize.gml b/scripts/node_spherize/node_spherize.gml index d55fad896..c539cea54 100644 --- a/scripts/node_spherize/node_spherize.gml +++ b/scripts/node_spherize/node_spherize.gml @@ -3,7 +3,7 @@ function Node_Spherize(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Center", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ]) + inputs[1] = nodeValue_Vec2("Center", self, [ DEF_SURF_W / 2, DEF_SURF_H / 2 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[2] = nodeValue_Float("Strength", self, 1) diff --git a/scripts/node_sprite_stack/node_sprite_stack.gml b/scripts/node_sprite_stack/node_sprite_stack.gml index 2f6c1990b..c2f2d1bfd 100644 --- a/scripts/node_sprite_stack/node_sprite_stack.gml +++ b/scripts/node_sprite_stack/node_sprite_stack.gml @@ -8,9 +8,9 @@ function Node_Sprite_Stack(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro inputs[2] = nodeValue_Int("Stack amount", self, 4); - inputs[3] = nodeValue_Vector("Stack shift", self, [ 0, 1 ] ); + inputs[3] = nodeValue_Vec2("Stack shift", self, [ 0, 1 ] ); - inputs[4] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[4] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[5] = nodeValue_Rotation("Rotation", self, 0); diff --git a/scripts/node_strand_create/node_strand_create.gml b/scripts/node_strand_create/node_strand_create.gml index 646ca628e..dae13e0ad 100644 --- a/scripts/node_strand_create/node_strand_create.gml +++ b/scripts/node_strand_create/node_strand_create.gml @@ -11,7 +11,7 @@ function Node_Strand_Create(_x, _y, _group = noone) : Node(_x, _y, _group) const inputs[1] = nodeValue_Int("Density", self, 8, "How many strands to generate."); - inputs[2] = nodeValue_Vector("Length", self, [ 4, 4 ]); + inputs[2] = nodeValue_Vec2("Length", self, [ 4, 4 ]); inputs[3] = nodeValue_Int("Segment", self, 4); @@ -20,7 +20,7 @@ function Node_Strand_Create(_x, _y, _group = noone) : Node(_x, _y, _group) const inputs[5] = nodeValue_PathNode("Path", self, noone); - inputs[6] = nodeValue_Vector("Position", self, [ 0, 0 ]); + inputs[6] = nodeValue_Vec2("Position", self, [ 0, 0 ]); inputs[7] = nodeValue_Enum_Button("Side", self, 0, [ "Inner", "Outer", "Both" ]); @@ -52,7 +52,7 @@ function Node_Strand_Create(_x, _y, _group = noone) : Node(_x, _y, _group) const inputs[16] = nodeValue_Bool("View fix hair", self, false); - inputs[17] = nodeValue_Vector("Root strength", self, [-1, -1]) + inputs[17] = nodeValue_Vec2("Root strength", self, [-1, -1]) .setTooltip("The force required to break strand from its root. Set to -1 to make strand infinitely strong."); outputs[0] = nodeValue_Output("Strand", self, VALUE_TYPE.strands, noone); diff --git a/scripts/node_stripe/node_stripe.gml b/scripts/node_stripe/node_stripe.gml index a9b2452a1..e54ee3ec9 100644 --- a/scripts/node_stripe/node_stripe.gml +++ b/scripts/node_stripe/node_stripe.gml @@ -12,7 +12,7 @@ function Node_Stripe(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co inputs[3] = nodeValue_Enum_Button("Type", self, 0, [ "Solid", "Smooth", "AA" ]); - inputs[4] = nodeValue_Vector("Position", self, [ 0, 0 ] ) + inputs[4] = nodeValue_Vec2("Position", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[5] = nodeValue_Float("Random", self, 0) diff --git a/scripts/node_text/node_text.gml b/scripts/node_text/node_text.gml index 6d7e45ac6..b86ba826e 100644 --- a/scripts/node_text/node_text.gml +++ b/scripts/node_text/node_text.gml @@ -12,11 +12,11 @@ function Node_Text(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[3] = nodeValue_Bool("Anti-Aliasing ", self, false); - inputs[4] = nodeValue_Vector("Character range", self, [ 32, 128 ]); + inputs[4] = nodeValue_Vec2("Character range", self, [ 32, 128 ]); inputs[5] = nodeValue_Color("Color", self, c_white); - inputs[6] = nodeValue_Vector("Fixed dimension", self, DEF_SURF ) + inputs[6] = nodeValue_Vec2("Fixed dimension", self, DEF_SURF ) .setVisible(true, false); inputs[7] = nodeValue_Enum_Button("Horizontal alignment", self, 0 , [ THEME.inspector_text_halign, THEME.inspector_text_halign, THEME.inspector_text_halign]); diff --git a/scripts/node_transform_array/node_transform_array.gml b/scripts/node_transform_array/node_transform_array.gml index 3b4af16ba..0f8aec7da 100644 --- a/scripts/node_transform_array/node_transform_array.gml +++ b/scripts/node_transform_array/node_transform_array.gml @@ -4,13 +4,13 @@ function Node_Transform_Array(_x, _y, _group = noone) : Node_Processor(_x, _y, _ setDimension(96, 48); - inputs[0] = nodeValue_Vector("Postion", self, [ 0, 0 ] ) + inputs[0] = nodeValue_Vec2("Postion", self, [ 0, 0 ] ) .setVisible(true, true); inputs[1] = nodeValue_Rotation("Rotation", self, 0) .setVisible(true, true); - inputs[2] = nodeValue_Vector("Scale", self, [ 1, 1 ] ) + inputs[2] = nodeValue_Vec2("Scale", self, [ 1, 1 ] ) .setVisible(true, true); outputs[0] = nodeValue_Output("Transform", self, VALUE_TYPE.float, [ 0, 0, 0, 1, 1 ]) diff --git a/scripts/node_twirl/node_twirl.gml b/scripts/node_twirl/node_twirl.gml index c69016ef5..9523b6e49 100644 --- a/scripts/node_twirl/node_twirl.gml +++ b/scripts/node_twirl/node_twirl.gml @@ -3,7 +3,7 @@ function Node_Twirl(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Center", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Center", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); inputs[2] = nodeValue_Float("Strength", self, 3) diff --git a/scripts/node_vector2/node_vector2.gml b/scripts/node_vector2/node_vector2.gml index 508e64c6b..b5e756362 100644 --- a/scripts/node_vector2/node_vector2.gml +++ b/scripts/node_vector2/node_vector2.gml @@ -36,20 +36,21 @@ function Node_Vector2(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c wd_pan_my = 0; coordinate_menu = [ - menuItemAction(__txt("Reset view"), function() { - wd_minx = -1; - wd_miny = -1; - wd_maxx = 1; - wd_maxy = 1; + menuItem(__txt("Reset view"), function() { + wd_minx = -1; + wd_miny = -1; + wd_maxx = 1; + wd_maxy = 1; }), - menuItemAction(__txt("Focus value"), function() { + + menuItem(__txt("Focus value"), function() { var _x = getInputData(0); var _y = getInputData(1); - wd_minx = _x - 1; - wd_miny = _y - 1; - wd_maxx = _x + 1; - wd_maxy = _y + 1; + wd_minx = _x - 1; + wd_miny = _y - 1; + wd_maxx = _x + 1; + wd_maxy = _y + 1; }), ]; diff --git a/scripts/node_vector_cross_2D/node_vector_cross_2D.gml b/scripts/node_vector_cross_2D/node_vector_cross_2D.gml index 6b36a5882..2854fb161 100644 --- a/scripts/node_vector_cross_2D/node_vector_cross_2D.gml +++ b/scripts/node_vector_cross_2D/node_vector_cross_2D.gml @@ -4,10 +4,10 @@ function Node_Vector_Cross_2D(_x, _y, _group = noone) : Node_Processor(_x, _y, _ setDimension(96, 48); - inputs[0] = nodeValue_Vector("Point 1", self, [ 0, 0 ]) + inputs[0] = nodeValue_Vec2("Point 1", self, [ 0, 0 ]) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Point 2", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Point 2", self, [ 0, 0 ]) .setVisible(true, true); outputs[0] = nodeValue_Output("Result", self, VALUE_TYPE.float, 0 ); diff --git a/scripts/node_vector_cross_3D/node_vector_cross_3D.gml b/scripts/node_vector_cross_3D/node_vector_cross_3D.gml index 902684ad0..32adaa156 100644 --- a/scripts/node_vector_cross_3D/node_vector_cross_3D.gml +++ b/scripts/node_vector_cross_3D/node_vector_cross_3D.gml @@ -4,10 +4,10 @@ function Node_Vector_Cross_3D(_x, _y, _group = noone) : Node_Processor(_x, _y, _ setDimension(96, 48); - inputs[0] = nodeValue_Vector("Point 1", self, [ 0, 0, 0 ]) + inputs[0] = nodeValue_Vec3("Point 1", self, [ 0, 0, 0 ]) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Point 2", self, [ 0, 0, 0 ]) + inputs[1] = nodeValue_Vec3("Point 2", self, [ 0, 0, 0 ]) .setVisible(true, true); outputs[0] = nodeValue_Output("Result", self, VALUE_TYPE.float, [ 0, 0, 0 ] ) diff --git a/scripts/node_vector_dot/node_vector_dot.gml b/scripts/node_vector_dot/node_vector_dot.gml index 48280b3d9..e2c00011c 100644 --- a/scripts/node_vector_dot/node_vector_dot.gml +++ b/scripts/node_vector_dot/node_vector_dot.gml @@ -3,10 +3,10 @@ function Node_Vector_Dot(_x, _y, _group = noone) : Node_Processor(_x, _y, _group color = COLORS.node_blend_number; setDimension(96, 48); - inputs[0] = nodeValue_Vector("Point 1", self, [ 0, 0 ]) + inputs[0] = nodeValue_Vec2("Point 1", self, [ 0, 0 ]) .setVisible(true, true); - inputs[1] = nodeValue_Vector("Point 2", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Point 2", self, [ 0, 0 ]) .setVisible(true, true); outputs[0] = nodeValue_Output("Result", self, VALUE_TYPE.float, 0 ); diff --git a/scripts/node_vector_split/node_vector_split.gml b/scripts/node_vector_split/node_vector_split.gml index 2018f3191..35f3526ab 100644 --- a/scripts/node_vector_split/node_vector_split.gml +++ b/scripts/node_vector_split/node_vector_split.gml @@ -7,7 +7,7 @@ function Node_Vector_Split(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro draw_padding = 4; - inputs[0] = nodeValue_Vector("Vector", self, [ 0, 0, 0, 0 ]) + inputs[0] = nodeValue_Vec4("Vector", self, [ 0, 0, 0, 0 ]) .setArrayDynamic() .setVisible(true, true); diff --git a/scripts/node_voronoi_extra/node_voronoi_extra.gml b/scripts/node_voronoi_extra/node_voronoi_extra.gml index 817ba1d53..e3e4dae01 100644 --- a/scripts/node_voronoi_extra/node_voronoi_extra.gml +++ b/scripts/node_voronoi_extra/node_voronoi_extra.gml @@ -2,11 +2,11 @@ function Node_Voronoi_Extra(_x, _y, _group = noone) : Node_Shader_Generator(_x, name = "Extra Voronoi"; shader = sh_voronoi_extra; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]); + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]); addShaderProp(SHADER_UNIFORM.float, "scale"); inputs[3] = nodeValue_Float("Seed", self, seed_random(6)) diff --git a/scripts/node_warp/node_warp.gml b/scripts/node_warp/node_warp.gml index 37d672c5d..0d6b89558 100644 --- a/scripts/node_warp/node_warp.gml +++ b/scripts/node_warp/node_warp.gml @@ -3,16 +3,16 @@ function Node_Warp(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons inputs[0] = nodeValue_Surface("Surface in", self); - inputs[1] = nodeValue_Vector("Top left", self, [ 0, 0 ] ) + inputs[1] = nodeValue_Vec2("Top left", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[2] = nodeValue_Vector("Top right", self, [ DEF_SURF_W, 0 ] ) + inputs[2] = nodeValue_Vec2("Top right", self, [ DEF_SURF_W, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[3] = nodeValue_Vector("Bottom left", self, [ 0, DEF_SURF_H ] ) + inputs[3] = nodeValue_Vec2("Bottom left", self, [ 0, DEF_SURF_H ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[4] = nodeValue_Vector("Bottom right", self, DEF_SURF ) + inputs[4] = nodeValue_Vec2("Bottom right", self, DEF_SURF ) .setUnitRef(function(index) { return getDimension(index); }); inputs[5] = nodeValue_Bool("Active", self, true); diff --git a/scripts/node_wav_file_write/node_wav_file_write.gml b/scripts/node_wav_file_write/node_wav_file_write.gml index 858ac4935..11e25f9af 100644 --- a/scripts/node_wav_file_write/node_wav_file_write.gml +++ b/scripts/node_wav_file_write/node_wav_file_write.gml @@ -18,7 +18,7 @@ function Node_WAV_File_Write(_x, _y, _group = noone) : Node(_x, _y, _group) cons inputs[4] = nodeValue_Bool("Remap Data", self, false) - inputs[5] = nodeValue_Vector("Data Range", self, [ 0, 1 ]); + inputs[5] = nodeValue_Vec2("Data Range", self, [ 0, 1 ]); input_display_list = [ [ "Data", false], 1, 0, 4, 5, diff --git a/scripts/node_wavelet_noise/node_wavelet_noise.gml b/scripts/node_wavelet_noise/node_wavelet_noise.gml index 14382ab75..035d22772 100644 --- a/scripts/node_wavelet_noise/node_wavelet_noise.gml +++ b/scripts/node_wavelet_noise/node_wavelet_noise.gml @@ -2,11 +2,11 @@ function Node_Wavelet_Noise(_x, _y, _group = noone) : Node_Shader_Generator(_x, name = "Wavelet Noise"; shader = sh_noise_wavelet; - inputs[1] = nodeValue_Vector("Position", self, [ 0, 0 ]) + inputs[1] = nodeValue_Vec2("Position", self, [ 0, 0 ]) .setUnitRef(function(index) { return getDimension(index); }); addShaderProp(SHADER_UNIFORM.float, "position"); - inputs[2] = nodeValue_Vector("Scale", self, [ 4, 4 ]) + inputs[2] = nodeValue_Vec2("Scale", self, [ 4, 4 ]) .setMappable(6); addShaderProp(SHADER_UNIFORM.float, "scale"); diff --git a/scripts/node_wrap_perspective/node_wrap_perspective.gml b/scripts/node_wrap_perspective/node_wrap_perspective.gml index 4ec87362a..80c76e118 100644 --- a/scripts/node_wrap_perspective/node_wrap_perspective.gml +++ b/scripts/node_wrap_perspective/node_wrap_perspective.gml @@ -6,28 +6,28 @@ function Node_Warp_Perspective(_x, _y, _group = noone) : Node_Processor(_x, _y, inputs[1] = nodeValue_Bool("Active", self, true); active_index = 1; - inputs[2] = nodeValue_Vector("Top left", self, [ 0, 0 ] ) + inputs[2] = nodeValue_Vec2("Top left", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[3] = nodeValue_Vector("Top right", self, [ DEF_SURF_W, 0 ] ) + inputs[3] = nodeValue_Vec2("Top right", self, [ DEF_SURF_W, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[4] = nodeValue_Vector("Bottom left", self, [ 0, DEF_SURF_H ] ) + inputs[4] = nodeValue_Vec2("Bottom left", self, [ 0, DEF_SURF_H ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[5] = nodeValue_Vector("Bottom right", self, DEF_SURF ) + inputs[5] = nodeValue_Vec2("Bottom right", self, DEF_SURF ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[6] = nodeValue_Vector("Top left", self, [ 0, 0 ] ) + inputs[6] = nodeValue_Vec2("Top left", self, [ 0, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[7] = nodeValue_Vector("Top right", self, [ DEF_SURF_W, 0 ] ) + inputs[7] = nodeValue_Vec2("Top right", self, [ DEF_SURF_W, 0 ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[8] = nodeValue_Vector("Bottom left", self, [ 0, DEF_SURF_H ] ) + inputs[8] = nodeValue_Vec2("Bottom left", self, [ 0, DEF_SURF_H ] ) .setUnitRef(function(index) { return getDimension(index); }); - inputs[9] = nodeValue_Vector("Bottom right", self, DEF_SURF ) + inputs[9] = nodeValue_Vec2("Bottom right", self, DEF_SURF ) .setUnitRef(function(index) { return getDimension(index); }); outputs[0] = nodeValue_Output("Surface out", self, VALUE_TYPE.surface, noone); diff --git a/scripts/node_zigzag/node_zigzag.gml b/scripts/node_zigzag/node_zigzag.gml index a775da54e..bf4485176 100644 --- a/scripts/node_zigzag/node_zigzag.gml +++ b/scripts/node_zigzag/node_zigzag.gml @@ -7,7 +7,7 @@ function Node_Zigzag(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co .setDisplay(VALUE_DISPLAY.slider, { range: [1, 16, 0.1] }) .setMappable(6); - inputs[2] = nodeValue_Vector("Position", self, [0, 0] ) + inputs[2] = nodeValue_Vec2("Position", self, [0, 0] ) .setUnitRef(function(index) { return getDimension(index); }); inputs[3] = nodeValue_Color("Color 1", self, c_white); diff --git a/scripts/panel_collection/panel_collection.gml b/scripts/panel_collection/panel_collection.gml index b27c7fdad..8e3a62b88 100644 --- a/scripts/panel_collection/panel_collection.gml +++ b/scripts/panel_collection/panel_collection.gml @@ -140,15 +140,16 @@ function Panel_Collection() : PanelContent() constructor { function steam_unsubscribe() { if(_menu_node == noone) return; - var meta = _menu_node.getMetadata(); + var meta = _menu_node.getMetadata(); var del_id = meta.file_id; for( var i = 0; i < ds_list_size(STEAM_COLLECTION); i++ ) { - if(STEAM_COLLECTION[| i].getMetadata().file_id == del_id) { - ds_list_delete(STEAM_COLLECTION, i); - break; - } + if(STEAM_COLLECTION[| i].getMetadata().file_id != del_id) continue; + + ds_list_delete(STEAM_COLLECTION, i); + break; } + steam_ugc_unsubscribe_item(del_id); } #endregion @@ -175,8 +176,9 @@ function Panel_Collection() : PanelContent() constructor { if(STEAM_ENABLED) { if(meta.steam == FILE_STEAM_TYPE.local) { array_push(contentMenu, MENU_ITEMS.collection_upload_to_steam); + } else { - if(meta.author_steam_id == STEAM_USER_ID && meta.file_id != 0) + if(meta.author_steam_id && meta.author_steam_id == STEAM_USER_ID) array_push(contentMenu, MENU_ITEMS.collection_update_steam); array_push(contentMenu, MENU_ITEMS.collection_unsubscribe); } diff --git a/scripts/panel_data/panel_data.gml b/scripts/panel_data/panel_data.gml index 7d02e9a41..ee46ef768 100644 --- a/scripts/panel_data/panel_data.gml +++ b/scripts/panel_data/panel_data.gml @@ -53,18 +53,18 @@ function Panel(_parent, _x, _y, _w, _h) constructor { draw_droppable = false; - border_rb_close = menuItemAction(__txt("Close"), function() { + border_rb_close = menuItem(__txt("Close"), function() { var con = getContent(); if(con == noone) return; con.close(); }, THEME.cross); border_rb_menu = [ - menuItemAction(__txt("Move"), function() { + menuItem(__txt("Move"), function() { extract(); panel_mouse = 1; }), - menuItemAction(__txtx("panel_pop_out", "Pop out"), function() { popWindow(); }, THEME.node_goto), + menuItem(__txtx("panel_pop_out", "Pop out"), function() { popWindow(); }, THEME.node_goto), border_rb_close ]; diff --git a/scripts/panel_function/panel_function.gml b/scripts/panel_function/panel_function.gml index 14d2bff6b..dec527a39 100644 --- a/scripts/panel_function/panel_function.gml +++ b/scripts/panel_function/panel_function.gml @@ -479,35 +479,35 @@ function __fnInit_Panels() { - registerFunction("", "Preference", "", MOD_KEY.none, call_dialog_preference ).setMenu("preference", THEME.gear) + registerFunction("", "Preferences", "", MOD_KEY.none, call_dialog_preference ).setMenu("preference", THEME.gear) registerFunction("", "Splash screen", "", MOD_KEY.none, call_dialog_splash ).setMenu("splash_screen") registerFunction("", "Release note", "", MOD_KEY.none, call_dialog_release_note ).setMenu("release_note") - registerFunction("", "Command Palette", "T", MOD_KEY.ctrl | MOD_KEY.shift, call_dialog_command_palette ).setMenu("command_palette") - registerFunction("", "Autosave folder", "", MOD_KEY.none, open_autosave_folder ).setMenu("autosave_folder", THEME.save_auto) + registerFunction("", "Command Palette", "T", MOD_KEY.ctrl | MOD_KEY.shift, call_dialog_command_palette).setMenu("command_palette") + registerFunction("", "Open Autosave Folder", "", MOD_KEY.none, open_autosave_folder ).setMenu("autosave_folder", THEME.save_auto) registerFunction("", "Addons", "", MOD_KEY.none, call_panel_addon ).setMenu("addons") registerFunction("", "History", "", MOD_KEY.none, call_panel_history ).setMenu("history") - registerFunction("", "Notification Panel", vk_f12, MOD_KEY.none, call_panel_Notification ).setMenu("notification_panel") - registerFunction("", "Collections Panel", "", MOD_KEY.none, call_panel_Collection ).setMenu("collections_panel") - registerFunction("", "Graph Panel", "", MOD_KEY.none, call_panel_Graph ).setMenu("graph_panel") - registerFunction("", "Preview Panel", "", MOD_KEY.none, call_panel_Preview ).setMenu("preview_panel") - registerFunction("", "Preview Histogram", "", MOD_KEY.none, call_panel_Preview_Histogram ).setMenu("preview_histogram") - registerFunction("", "Inspector Panel", "", MOD_KEY.none, call_panel_Inspector ).setMenu("inspector_panel") - registerFunction("", "Workspace Panel", "", MOD_KEY.none, call_panel_Workspace ).setMenu("workspace_panel") - registerFunction("", "Animation Panel", "", MOD_KEY.none, call_panel_Animation ).setMenu("animation_panel") + registerFunction("", "Notification Panel", vk_f12, MOD_KEY.none, call_panel_Notification ).setMenuAlt("Notification", "notification_panel") + registerFunction("", "Collections Panel", "", MOD_KEY.none, call_panel_Collection ).setMenuAlt("Collections", "collections_panel") + registerFunction("", "Graph Panel", "", MOD_KEY.none, call_panel_Graph ).setMenuAlt("Graph", "graph_panel") + registerFunction("", "Preview Panel", "", MOD_KEY.none, call_panel_Preview ).setMenuAlt("Preview", "preview_panel") + registerFunction("", "Preview Histogram", "", MOD_KEY.none, call_panel_Preview_Histogram ).setMenuAlt("Preview", "preview_histogram") + registerFunction("", "Inspector Panel", "", MOD_KEY.none, call_panel_Inspector ).setMenuAlt("Inspector", "inspector_panel") + registerFunction("", "Workspace Panel", "", MOD_KEY.none, call_panel_Workspace ).setMenuAlt("Workspace", "workspace_panel") + registerFunction("", "Animation Panel", "", MOD_KEY.none, call_panel_Animation ).setMenuAlt("Animation", "animation_panel") - registerFunction("", "Align Panel", "", MOD_KEY.none, call_panel_Node_Align ).setMenu("align_panel") - registerFunction("", "Nodes Panel", "", MOD_KEY.none, call_panel_Nodes ).setMenu("nodes_panel") - registerFunction("", "Tunnels Panel", "", MOD_KEY.none, call_panel_Tunnels ).setMenu("tunnels_panel") + registerFunction("", "Align Panel", "", MOD_KEY.none, call_panel_Node_Align ).setMenuAlt("Align", "align_panel") + registerFunction("", "Nodes Panel", "", MOD_KEY.none, call_panel_Nodes ).setMenuAlt("Nodes", "nodes_panel") + registerFunction("", "Tunnels Panel", "", MOD_KEY.none, call_panel_Tunnels ).setMenuAlt("Tunnels", "tunnels_panel") - registerFunction("", "Color Panel", "", MOD_KEY.none, call_panel_Color ).setMenu("color_panel") - registerFunction("", "Palettes Panel", "", MOD_KEY.none, call_panel_Palette ).setMenu("palettes_panel") - registerFunction("", "Palettes Mixer Panel", "", MOD_KEY.none, call_panel_Palette_Mixer ).setMenu("palettes_mixer_panel") - registerFunction("", "Gradients Panel", "", MOD_KEY.none, call_panel_Gradient ).setMenu("gradients_panel") + registerFunction("", "Color Panel", "", MOD_KEY.none, call_panel_Color ).setMenuAlt("Color", "color_panel") + registerFunction("", "Palettes Panel", "", MOD_KEY.none, call_panel_Palette ).setMenuAlt("Palettes", "palettes_panel") + registerFunction("", "Palettes Mixer Panel", "", MOD_KEY.none, call_panel_Palette_Mixer ).setMenuAlt("Palettes", "palettes_mixer_panel") + registerFunction("", "Gradients Panel", "", MOD_KEY.none, call_panel_Gradient ).setMenuAlt("Gradients", "gradients_panel") - registerFunction("", "Console Panel", "", MOD_KEY.none, call_panel_Console ).setMenu("console_panel") - registerFunction("", "Globalvar Panel", "", MOD_KEY.none, call_panel_Globalvar ).setMenu("globalvar_panel") - registerFunction("", "File Explorer Panel", "", MOD_KEY.none, call_panel_File_Explorer ).setMenu("file_explorer_panel") + registerFunction("", "Console Panel", "", MOD_KEY.none, call_panel_Console ).setMenuAlt("Console", "console_panel") + registerFunction("", "Globalvar Panel", "", MOD_KEY.none, call_panel_Globalvar ).setMenuAlt("Globalvar", "globalvar_panel") + registerFunction("", "File Explorer Panel", "", MOD_KEY.none, call_panel_File_Explorer ).setMenuAlt("File", "file_explorer_panel") } #endregion \ No newline at end of file diff --git a/scripts/panel_inspector/panel_inspector.gml b/scripts/panel_inspector/panel_inspector.gml index b9b04355f..fb958ca03 100644 --- a/scripts/panel_inspector/panel_inspector.gml +++ b/scripts/panel_inspector/panel_inspector.gml @@ -29,8 +29,8 @@ registerFunction("Inspector", "Collapse All Sections", "", MOD_KEY.none, panel_inspector_section_collapse_all ).setMenu("inspector_collapse_all_sections") registerFunction("Inspector", "Reset", "", MOD_KEY.none, panel_inspector_reset ).setMenu("inspector_reset") - registerFunction("Inspector", "Add", "", MOD_KEY.none, panel_inspector_add ).setMenu("inspector_add") - registerFunction("Inspector", "Remove", "", MOD_KEY.none, panel_inspector_remove ).setMenu("inspector_remove") + registerFunction("Inspector", "Animate", "", MOD_KEY.none, panel_inspector_add ).setMenu("inspector_animate") + registerFunction("Inspector", "Reset Animation", "", MOD_KEY.none, panel_inspector_remove ).setMenu("inspector_remove_animate") registerFunction("Inspector", "Combine Axis", "", MOD_KEY.none, panel_inspector_axis_combine ).setMenu("inspector_combine_axis") registerFunction("Inspector", "Separate Axis", "", MOD_KEY.none, panel_inspector_axis_separate ).setMenu("inspector_separate_axis") registerFunction("Inspector", "Use Expression", "", MOD_KEY.none, panel_inspector_use_expression ).setMenu("inspector_use_expression") @@ -155,22 +155,28 @@ function Panel_Inspector() : PanelContent() constructor { #region ---- metadata ---- current_meta = -1; - meta_tb[0] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.description = str; }); - meta_tb[1] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.author = str; }); - meta_tb[2] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.contact = str; }); - meta_tb[3] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.alias = str; }); + meta_tb[0] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.description = str; }); + meta_tb[1] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.author = str; }); + meta_tb[2] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.contact = str; }); + meta_tb[3] = new textArea(TEXTBOX_INPUT.text, function(str) { current_meta.alias = str; }); meta_tb[4] = new textArrayBox(noone, META_TAGS); for( var i = 0, n = array_length(meta_tb); i < n; i++ ) meta_tb[i].hide = true; - + meta_display = [ - [ __txt("Project Settings"), false ], - [ __txt("Metadata"), true ], - [ __txtx("panel_globalvar", "Global variables"), true, button(function() { panelAdd("Panel_Globalvar", true); }, THEME.node_goto).setIcon(THEME.node_goto, 0, COLORS._main_icon) ], - [ __txt("Group Properties"), true ], + [ __txt("Project Settings"), false ], + [ __txt("Metadata"), true ], + [ __txtx("panel_globalvar", "Global variables"), true ], + [ __txt("Group Properties"), true ], ]; meta_steam_avatar = new checkBox(function() { STEAM_UGC_ITEM_AVATAR = !STEAM_UGC_ITEM_AVATAR; }); + + global_buttons = [ + // button(() => { panelAdd("Panel_Globalvar", true); } ).setIcon(THEME.node_goto, 0, COLORS._main_icon_light), + button(function() /*=>*/ { meta_display[2][1] = false; var_editing = !var_editing; } ).setIcon(THEME.gear_16, 0, COLORS._main_icon_light), + button(function() /*=>*/ { meta_display[2][1] = false; PROJECT.globalNode.createValue(); } ).setIcon(THEME.add_16, 0, COLORS._main_value_positive), + ]; #endregion #region ---- workshop ---- @@ -226,8 +232,8 @@ function Panel_Inspector() : PanelContent() constructor { __dialog_junction = noone; menu_junc_reset_value = MENU_ITEMS.inspector_reset; - menu_junc_add_anim = MENU_ITEMS.inspector_add; - menu_junc_rem_anim = MENU_ITEMS.inspector_remove; + menu_junc_add_anim = MENU_ITEMS.inspector_animate; + menu_junc_rem_anim = MENU_ITEMS.inspector_remove_animate; menu_junc_combine_axis = MENU_ITEMS.inspector_combine_axis; menu_junc_separate_axis = MENU_ITEMS.inspector_separate_axis; menu_junc_expression_ena = MENU_ITEMS.inspector_use_expression; @@ -300,24 +306,53 @@ function Panel_Inspector() : PanelContent() constructor { var _meta = meta_display[i]; var _txt = array_safe_get_fast(_meta, 0); - var _b = array_safe_get_fast(_meta, 2, noone); - var _x1 = con_w - (_b != noone) * ui(30); - if(_hover && point_in_rectangle(_m[0], _m[1], 0, yy, _x1, yy + lbh)) { - draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, 0, yy, con_w, lbh, COLORS.panel_inspector_group_hover, 1); + switch(i) { + case 2 : + var _bw = ui(28); + var _bh = lbh - ui(4); + + var _x1 = con_w; + var _y1 = yy + ui(2); + + var _amo = array_length(global_buttons); + var _tw = (_bw + ui(4)) * _amo; + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, con_w - _tw, yy, _tw, lbh, COLORS.panel_inspector_group_bg, 1); + + global_buttons[0].icon = var_editing? THEME.accept_16 : THEME.gear_16; + global_buttons[0].icon_blend = var_editing? COLORS._main_value_positive : COLORS._main_icon_light; + + for (var j = 0, m = array_length(global_buttons); j < m; j++) { + _x1 -= _bw + ui(4); - if(mouse_press(mb_left, pFOCUS)) - meta_display[i][1] = !meta_display[i][1]; - } else - draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, 0, yy, con_w, lbh, COLORS.panel_inspector_group_bg, 1); - - if(_b != noone) { - _b.setFocusHover(pFOCUS, _hover); - _b.draw(_x1, yy + ui(2), ui(28), lbh - ui(4), _m, THEME.button_hide_fill); - if(_b.inBBOX(_m)) contentPane.hover_content = true; + var _b = global_buttons[j]; + _b.setFocusHover(pFOCUS, _hover); + _b.draw(_x1 + ui(2), _y1, _bw, _bh, _m, THEME.button_hide_fill); + if(_b.inBBOX(_m)) contentPane.hover_content = true; + } + + _x1 -= ui(4); + if(_hover && point_in_rectangle(_m[0], _m[1], 0, yy, _x1, yy + lbh)) { + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, 0, yy, _x1, lbh, COLORS.panel_inspector_group_hover, 1); + if(mouse_press(mb_left, pFOCUS)) _meta[1] = !_meta[1]; + + } else + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, 0, yy, _x1, lbh, COLORS.panel_inspector_group_bg, 1); + + break; + + default : + var _x1 = con_w; + + if(_hover && point_in_rectangle(_m[0], _m[1], 0, yy, _x1, yy + lbh)) { + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, 0, yy, con_w, lbh, COLORS.panel_inspector_group_hover, 1); + if(mouse_press(mb_left, pFOCUS)) _meta[1] = !_meta[1]; + + } else + draw_sprite_stretched_ext(THEME.s_box_r5_clr, 0, 0, yy, con_w, lbh, COLORS.panel_inspector_group_bg, 1); } - draw_sprite_ui(THEME.arrow, meta_display[i][1]? 0 : 3, ui(16), yy + lbh / 2, 1, 1, 0, COLORS.panel_inspector_group_bg, 1); + draw_sprite_ui(THEME.arrow, _meta[1]? 0 : 3, ui(16), yy + lbh / 2, 1, 1, 0, COLORS.panel_inspector_group_bg, 1); draw_set_text(viewMode? f_p0 : f_p1, fa_left, fa_center, COLORS._main_text_inner); draw_text_add(ui(32), yy + lbh / 2, _txt); @@ -325,7 +360,7 @@ function Panel_Inspector() : PanelContent() constructor { yy += lbh + ui(viewMode? 8 : 6); hh += lbh + ui(viewMode? 8 : 6); - if(meta_display[i][1]) continue; + if(_meta[1]) continue; var _font = viewMode == INSP_VIEW_MODE.spacious? f_p0 : f_p2; @@ -396,7 +431,7 @@ function Panel_Inspector() : PanelContent() constructor { var _wdx = viewMode == INSP_VIEW_MODE.spacious? ui(16) : ui(140); var _wdw = w - ui(48) - _wdx; var _whh = line_get_height(_font); - var _edt = !PROJECT.meta.file_id || PROJECT.meta.author_steam_id == STEAM_USER_ID; + var _edt = PROJECT.meta.author_steam_id && PROJECT.meta.author_steam_id == STEAM_USER_ID; for( var j = 0; j < array_length(meta.displays); j++ ) { var display = meta.displays[j]; @@ -478,62 +513,62 @@ function Panel_Inspector() : PanelContent() constructor { if(_m[1] > yy) contentPane.hover_content = true; var glPar = globalvar_viewer_draw(ui(16), yy, contentPane.surface_w - ui(24), _m, pFOCUS, _hover, contentPane, ui(16) + x, top_bar_h + y); - var gvh = glPar[0]; + var gvh = glPar[0]; yy += gvh + ui(8); hh += gvh + ui(8); - var bh = ui(36); - var bx = ui(16); - var by = yy; - var bbw = contentPane.surface_w - ui(24); + // var bh = ui(36); + // var bx = ui(16); + // var by = yy; + // var bbw = contentPane.surface_w - ui(24); - if(var_editing) { - var bw = bbw / 2 - ui(4); + // if(var_editing) { + // var bw = bbw / 2 - ui(4); - if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, pFOCUS, _hover) == 2) - var_editing = !var_editing; + // if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, pFOCUS, _hover) == 2) + // var_editing = !var_editing; - var txt = __txt("Apply"); - var icon = THEME.accept; - var colr = COLORS._main_value_positive; + // var txt = __txt("Apply"); + // var icon = THEME.accept; + // var colr = COLORS._main_value_positive; - draw_set_text(f_p0b, fa_left, fa_center, COLORS._main_icon) - var bxc = bx + bw / 2 - (string_width(txt) + ui(48)) / 2; - var byc = by + bh / 2; - draw_sprite_ui(icon, 0, bxc + ui(24), byc,,,, colr); - draw_text_over(bxc + ui(48), byc, txt); + // draw_set_text(f_p0b, fa_left, fa_center, COLORS._main_icon) + // var bxc = bx + bw / 2 - (string_width(txt) + ui(48)) / 2; + // var byc = by + bh / 2; + // draw_sprite_ui(icon, 0, bxc + ui(24), byc,,,, colr); + // draw_text_over(bxc + ui(48), byc, txt); - bx += bw + ui(4); + // bx += bw + ui(4); - if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, pFOCUS, _hover) == 2) - PROJECT.globalNode.createValue(); + // if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, pFOCUS, _hover) == 2) + // PROJECT.globalNode.createValue(); - var txt = __txt("Add"); - var icon = THEME.add; + // var txt = __txt("Add"); + // var icon = THEME.add; - draw_set_text(f_p0b, fa_left, fa_center, COLORS._main_icon) - var bxc = bx + bw / 2 - (string_width(txt) + ui(48)) / 2; - var byc = by + bh / 2; - draw_sprite_ui(icon, 0, bxc + ui(24), byc,,,, colr); - draw_text_over(bxc + ui(48), byc, txt); + // draw_set_text(f_p0b, fa_left, fa_center, COLORS._main_icon) + // var bxc = bx + bw / 2 - (string_width(txt) + ui(48)) / 2; + // var byc = by + bh / 2; + // draw_sprite_ui(icon, 0, bxc + ui(24), byc,,,, colr); + // draw_text_over(bxc + ui(48), byc, txt); - } else { - var bw = bbw; + // } else { + // var bw = bbw; - if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, pFOCUS, _hover) == 2) - var_editing = !var_editing; - - var txt = __txt("Edit"); - var icon = THEME.gear; - var colr = COLORS._main_icon; + // if(buttonInstant(THEME.button_hide, bx, by, bw, bh, _m, pFOCUS, _hover) == 2) + // var_editing = !var_editing; + + // var txt = __txt("Edit"); + // var icon = THEME.gear; + // var colr = COLORS._main_icon; - draw_set_text(f_p0b, fa_left, fa_center, colr) - var bxc = bx + bw / 2 - (string_width(txt) + ui(48)) / 2; - var byc = by + bh / 2; - draw_sprite_ui(icon, 0, bxc + ui(24), byc,,,, colr); - draw_text_over(bxc + ui(48), byc, txt); - } + // draw_set_text(f_p0b, fa_left, fa_center, colr) + // var bxc = bx + bw / 2 - (string_width(txt) + ui(48)) / 2; + // var byc = by + bh / 2; + // draw_sprite_ui(icon, 0, bxc + ui(24), byc,,,, colr); + // draw_text_over(bxc + ui(48), byc, txt); + // } break; @@ -922,7 +957,7 @@ function Panel_Inspector() : PanelContent() constructor { array_push(_menuItem, menu_junc_extract); } - var dia = menuCall("inspector_value_menu", _menuItem,, jun); + var dia = menuCall("inspector_value_menu", _menuItem); __dialog_junction = jun; } #endregion } diff --git a/scripts/panel_menu/panel_menu.gml b/scripts/panel_menu/panel_menu.gml index 3e7e64b76..a6bea477c 100644 --- a/scripts/panel_menu/panel_menu.gml +++ b/scripts/panel_menu/panel_menu.gml @@ -35,9 +35,6 @@ registerFunction("", "Append", "", MOD_KEY.none, APPEND ).setMenu("append", ) .setArg([ ARG("path", ""), ARG("context", function() { return PANEL_GRAPH.getCurrentContext() }, true) ]) - registerFunction("", "Import .zip", "", MOD_KEY.none, __IMPORT_ZIP ).setMenu("import_zip", ) - registerFunction("", "Export .zip", "", MOD_KEY.none, __EXPORT_ZIP ).setMenu("export_zip", ) - registerFunction("", "Recent Files", "R", MOD_KEY.ctrl | MOD_KEY.shift, function(_dat) { var arr = []; @@ -46,7 +43,13 @@ array_push(arr, menuItem(_rec, function(_dat) { LOAD_PATH(_dat.name); })); } return submenuCall(_dat, arr) - }).setMenu("recent_files",, true) + }).setMenu("recent_files",, true); + + registerFunction("", "Import .zip", "", MOD_KEY.none, __IMPORT_ZIP ).setMenu("import_zip", ) + registerFunction("", "Export .zip", "", MOD_KEY.none, __EXPORT_ZIP ).setMenu("export_zip", ) + + registerFunction("", "Import", "", MOD_KEY.none, function(_dat) /*=>*/ {return submenuCall(_dat, [ MENU_ITEMS.import_zip ])} ).setMenu("import_menu",, true); + registerFunction("", "Export", "", MOD_KEY.none, function(_dat) /*=>*/ {return submenuCall(_dat, [ MENU_ITEMS.export_zip ])} ).setMenu("export_menu",, true); } registerFunction("", "Undo", "Z", MOD_KEY.ctrl, UNDO ).setMenu("undo", ) @@ -66,6 +69,20 @@ .setArg([ ARG("project", function() { return PROJECT; }, true) ]) registerFunction("", "Reload theme", vk_f10, MOD_KEY.ctrl | MOD_KEY.shift, global_theme_reload ).setMenu("reload_theme", ) + + registerFunction("", "Addons Menu", "", MOD_KEY.none, function(_dat) /*=>*/ { + var arr = [ + MENU_ITEMS.addons, + menuItem(__txtx("panel_menu_addons_key", "Key displayer"), function() /*=>*/ { if(instance_exists(addon_key_displayer)) return; instance_create_depth(0, 0, 0, addon_key_displayer); }), + -1 + ]; + + for( var i = 0, n = array_length(ADDONS); i < n; i++ ) + array_push(arr, menuItem(ADDONS[i].name, function(_dat) /*=>*/ { addonTrigger(_dat.name); } )); + + return submenuCall(_dat, arr); + }).setMenu("addon_menu", THEME.addon_icon, true) + } #endregion @@ -98,8 +115,8 @@ function Panel_Menu() : PanelContent() constructor { MENU_ITEMS.recent_files, MENU_ITEMS.autosave_folder, - menuItemAction(__txt("Import"), function(_dat) { var arr = [ MENU_ITEMS.import_zip, ]; return submenuCall(_dat, arr); }).setIsShelf(), - menuItemAction(__txt("Export"), function(_dat) { var arr = [ MENU_ITEMS.export_zip, ]; return submenuCall(_dat, arr); }).setIsShelf(), + MENU_ITEMS.import_menu, + MENU_ITEMS.export_menu, -1, ]; @@ -107,27 +124,7 @@ function Panel_Menu() : PanelContent() constructor { MENU_ITEMS.preference, MENU_ITEMS.splash_screen, -1, - menuItemAction(__txt("Addons"), function(_dat) { - var arr = [ - MENU_ITEMS.addons, - menuItemAction(__txtx("panel_menu_addons_key", "Key displayer"), function() { - if(instance_exists(addon_key_displayer)) { - instance_destroy(addon_key_displayer); - return; - } - - instance_create_depth(0, 0, 0, addon_key_displayer); - }), - -1 - ]; - - for( var i = 0, n = array_length(ADDONS); i < n; i++ ) { - var _dir = ADDONS[i].name; - array_push(arr, menuItemAction(_dir, function(_dat) { addonTrigger(_dat.name); } )); - } - - return submenuCall(_dat, arr); - }, THEME.addon_icon ).setIsShelf(), + MENU_ITEMS.addon_menu, -1, MENU_ITEMS.fullscreen, MENU_ITEMS.close_file, diff --git a/scripts/steam_ugc_collection/steam_ugc_collection.gml b/scripts/steam_ugc_collection/steam_ugc_collection.gml index f8145576c..300a200e2 100644 --- a/scripts/steam_ugc_collection/steam_ugc_collection.gml +++ b/scripts/steam_ugc_collection/steam_ugc_collection.gml @@ -1,4 +1,4 @@ -function steam_ugc_create_collection(file) { #region +function steam_ugc_create_collection(file) { if(STEAM_UGC_ITEM_UPLOADING) return; STEAM_UGC_UPDATE = false; @@ -6,20 +6,21 @@ function steam_ugc_create_collection(file) { #region STEAM_UGC_ITEM_FILE = file; STEAM_UGC_TYPE = STEAM_UGC_FILE_TYPE.collection; - directory_destroy(DIRECTORY + "steamUGC"); - directory_create(DIRECTORY + "steamUGC"); + var _dir = DIRECTORY + "steamUGC" + directory_destroy(_dir); + directory_create(_dir); - file_copy(file.path, DIRECTORY + "steamUGC/" + filename_name(file.path)); - file_copy(file.meta_path, DIRECTORY + "steamUGC/" + filename_name(file.meta_path)); + file_copy(file.path, $"{_dir}/{filename_name(file.path )}"); + file_copy(file.meta_path, $"{_dir}/{filename_name(file.meta_path)}"); if(array_safe_get_fast(file.spr_path, 0) != 0) - file_copy(file.spr_path[0], DIRECTORY + "steamUGC/" + filename_name(file.spr_path[0])); + file_copy(file.spr_path[0], $"{_dir}/{filename_name(file.spr_path[0])}"); steam_ugc_collection_generate(array_safe_get_fast(file.spr_path, 0)); STEAM_UGC_ITEM_ID = steam_ugc_create_item(STEAM_APP_ID, ugc_filetype_community); -} #endregion +} -function steam_ugc_update_collection(file, update_preview = false, update_note = "Updated") { #region +function steam_ugc_update_collection(file, update_preview = false, update_note = "Updated") { if(STEAM_UGC_ITEM_UPLOADING) return; STEAM_UGC_UPDATE = true; @@ -27,18 +28,20 @@ function steam_ugc_update_collection(file, update_preview = false, update_note = STEAM_UGC_ITEM_FILE = file; STEAM_UGC_TYPE = STEAM_UGC_FILE_TYPE.collection; - directory_destroy(DIRECTORY + "steamUGC"); - directory_create(DIRECTORY + "steamUGC"); + var _dir = DIRECTORY + "steamUGC" + directory_destroy(_dir); + directory_create(_dir); - file_copy(file.path, DIRECTORY + "steamUGC/" + filename_name(file.path)); - file_copy(file.meta_path, DIRECTORY + "steamUGC/" + filename_name(file.meta_path)); - if(array_safe_get_fast(file.spr_path, 0, 0) != 0) - file_copy(file.spr_path[0], DIRECTORY + "steamUGC/" + filename_name(file.spr_path[0])); + file_copy(file.path, $"{_dir}/{filename_name(file.path )}"); + file_copy(file.meta_path, $"{_dir}/{filename_name(file.meta_path)}"); - STEAM_UGC_PUBLISH_ID = file.meta.file_id; + if(array_safe_get_fast(file.spr_path, 0) != 0) + file_copy(file.spr_path[0], $"{_dir}/{filename_name(file.spr_path[0])}"); + + STEAM_UGC_PUBLISH_ID = file.meta.file_id; STEAM_UGC_UPDATE_HANDLE = steam_ugc_start_item_update(STEAM_APP_ID, STEAM_UGC_PUBLISH_ID); - steam_ugc_set_item_title(STEAM_UGC_UPDATE_HANDLE, STEAM_UGC_ITEM_FILE.meta.name); + steam_ugc_set_item_title(STEAM_UGC_UPDATE_HANDLE, STEAM_UGC_ITEM_FILE.meta.name); steam_ugc_set_item_description(STEAM_UGC_UPDATE_HANDLE, STEAM_UGC_ITEM_FILE.meta.description); var tgs = STEAM_UGC_ITEM_FILE.meta.tags; @@ -49,14 +52,14 @@ function steam_ugc_update_collection(file, update_preview = false, update_note = steam_ugc_collection_generate(array_safe_get_fast(file.spr_path, 0)); steam_ugc_set_item_tags(STEAM_UGC_UPDATE_HANDLE, tgs); - steam_ugc_set_item_content(STEAM_UGC_UPDATE_HANDLE, DIRECTORY + "steamUGC"); + steam_ugc_set_item_content(STEAM_UGC_UPDATE_HANDLE, _dir); if(file_exists_empty(TEMPDIR + "steamUGCthumbnail.png")) steam_ugc_set_item_preview(STEAM_UGC_UPDATE_HANDLE, TEMPDIR + "steamUGCthumbnail.png"); STEAM_UGC_SUBMIT_ID = steam_ugc_submit_item_update(STEAM_UGC_UPDATE_HANDLE, update_note); -} #endregion +} -function steam_ugc_collection_generate(file, dest_path = TEMPDIR + "steamUGCthumbnail.png") { #region +function steam_ugc_collection_generate(file, dest_path = TEMPDIR + "steamUGCthumbnail.png") { file_delete(dest_path); var prev_size = 512; @@ -116,4 +119,4 @@ function steam_ugc_collection_generate(file, dest_path = TEMPDIR + "steamUGCthum surface_free(_s); surface_free(avartar); -} #endregion \ No newline at end of file +} \ No newline at end of file diff --git a/scripts/steam_ugc_project/steam_ugc_project.gml b/scripts/steam_ugc_project/steam_ugc_project.gml index 30b62959e..ad229864e 100644 --- a/scripts/steam_ugc_project/steam_ugc_project.gml +++ b/scripts/steam_ugc_project/steam_ugc_project.gml @@ -10,15 +10,16 @@ function steam_ugc_create_project() { STEAM_UGC_ITEM_FILE = file; STEAM_UGC_TYPE = STEAM_UGC_FILE_TYPE.project; - directory_destroy(DIRECTORY + "steamUGC"); - directory_create(DIRECTORY + "steamUGC"); + var _dir = DIRECTORY + "steamUGC" + directory_destroy(_dir); + directory_create(_dir); - file_copy(file.path, DIRECTORY + "steamUGC/" + filename_name(file.path)); - json_save_struct(DIRECTORY + "steamUGC/" + filename_name_only(file.path) + ".meta", file.meta); + file_copy(file.path, $"{_dir}/{filename_name(file.path)}"); + json_save_struct($"{_dir}/{filename_name_only(file.path)}.meta", file.meta); var preview_surface = PANEL_PREVIEW.getNodePreviewSurface(); - surface_save_safe(preview_surface, DIRECTORY + "steamUGC/thumbnail.png"); - steam_ugc_project_generate(DIRECTORY + "steamUGC/thumbnail.png"); + surface_save_safe(preview_surface, $"{_dir}/thumbnail.png"); + steam_ugc_project_generate($"{_dir}/thumbnail.png"); STEAM_UGC_ITEM_ID = steam_ugc_create_item(STEAM_APP_ID, ugc_filetype_community); } @@ -34,15 +35,16 @@ function steam_ugc_update_project(update_preview = false, update_note = "Updated STEAM_UGC_ITEM_FILE = file; STEAM_UGC_TYPE = STEAM_UGC_FILE_TYPE.project; - directory_destroy(DIRECTORY + "steamUGC"); - directory_create(DIRECTORY + "steamUGC"); + var _dir = DIRECTORY + "steamUGC" + directory_destroy(_dir); + directory_create(_dir); - file_copy(file.path, DIRECTORY + "steamUGC/" + filename_name(file.path)); + file_copy(file.path, $"{_dir}/{filename_name(file.path)}"); if(file_exists_empty(PROJECT.thumbnail)) - file_copy(PROJECT.thumbnail, DIRECTORY + "steamUGC/thumbnail.png"); - json_save_struct(DIRECTORY + "steamUGC/" + filename_name_only(file.path) + ".meta", file.meta); + file_copy(PROJECT.thumbnail, $"{_dir}/thumbnail.png"); + json_save_struct($"{_dir}/{filename_name_only(file.path)}.meta", file.meta); - STEAM_UGC_PUBLISH_ID = file.meta.file_id; + STEAM_UGC_PUBLISH_ID = file.meta.file_id; STEAM_UGC_UPDATE_HANDLE = steam_ugc_start_item_update(STEAM_APP_ID, STEAM_UGC_PUBLISH_ID); steam_ugc_set_item_title(STEAM_UGC_UPDATE_HANDLE, STEAM_UGC_ITEM_FILE.name); @@ -56,7 +58,7 @@ function steam_ugc_update_project(update_preview = false, update_note = "Updated steam_ugc_project_generate(PROJECT.thumbnail); steam_ugc_set_item_tags(STEAM_UGC_UPDATE_HANDLE, tgs); - steam_ugc_set_item_content(STEAM_UGC_UPDATE_HANDLE, DIRECTORY + "steamUGC"); + steam_ugc_set_item_content(STEAM_UGC_UPDATE_HANDLE, _dir); if(file_exists_empty(TEMPDIR + "steamUGCthumbnail.png")) steam_ugc_set_item_preview(STEAM_UGC_UPDATE_HANDLE, TEMPDIR + "steamUGCthumbnail.png"); diff --git a/scripts/theme_definition/theme_definition.gml b/scripts/theme_definition/theme_definition.gml index bdc8616fb..77ec3548a 100644 --- a/scripts/theme_definition/theme_definition.gml +++ b/scripts/theme_definition/theme_definition.gml @@ -69,6 +69,7 @@ function Theme() constructor { folder = s_folder_24; frame_range = s_frame_range; gear = s_gear_24; + gear_16 = s_gear_16; grad_blend = s_grad_blend; group_s = s_group_16; group = s_group_24; diff --git a/scripts/timeline_data/timeline_data.gml b/scripts/timeline_data/timeline_data.gml index 41a979216..0c53b818b 100644 --- a/scripts/timeline_data/timeline_data.gml +++ b/scripts/timeline_data/timeline_data.gml @@ -96,7 +96,9 @@ function timelineItemNode(node) : timelineItem() constructor { aa = 1; if(mouse_press(mb_left, focus)) show = !show; } - draw_sprite_ui_uniform(THEME.arrow, show? 3 : 0, lx + ui(10), _y + lh / 2, 1, col == -1? CDEF.main_grey : col, aa); + + if(node.isActiveDynamic()) + draw_sprite_ui_uniform(THEME.arrow, show? 3 : 0, lx + ui(10), _y + lh / 2, 1, col == -1? CDEF.main_grey : col, aa); draw_set_text(f_p3, fa_left, fa_center); var nodeName = $"[{node.name}] "; diff --git a/sprites/s_gear_16/3a09c235-6df0-4ae2-bdb3-7f77000112c5.png b/sprites/s_gear_16/3a09c235-6df0-4ae2-bdb3-7f77000112c5.png new file mode 100644 index 000000000..fe0441ac0 Binary files /dev/null and b/sprites/s_gear_16/3a09c235-6df0-4ae2-bdb3-7f77000112c5.png differ diff --git a/sprites/s_gear_16/layers/3a09c235-6df0-4ae2-bdb3-7f77000112c5/1a9d0e9a-6828-4fb4-949d-8ac643506e79.png b/sprites/s_gear_16/layers/3a09c235-6df0-4ae2-bdb3-7f77000112c5/1a9d0e9a-6828-4fb4-949d-8ac643506e79.png new file mode 100644 index 000000000..fe0441ac0 Binary files /dev/null and b/sprites/s_gear_16/layers/3a09c235-6df0-4ae2-bdb3-7f77000112c5/1a9d0e9a-6828-4fb4-949d-8ac643506e79.png differ diff --git a/sprites/s_gear_16/s_gear_16.yy b/sprites/s_gear_16/s_gear_16.yy new file mode 100644 index 000000000..20645a7cf --- /dev/null +++ b/sprites/s_gear_16/s_gear_16.yy @@ -0,0 +1,90 @@ +{ + "$GMSprite":"", + "%Name":"s_gear_16", + "bboxMode":0, + "bbox_bottom":14, + "bbox_left":1, + "bbox_right":14, + "bbox_top":1, + "collisionKind":1, + "collisionTolerance":0, + "DynamicTexturePage":false, + "edgeFiltering":false, + "For3D":false, + "frames":[ + {"$GMSpriteFrame":"","%Name":"3a09c235-6df0-4ae2-bdb3-7f77000112c5","name":"3a09c235-6df0-4ae2-bdb3-7f77000112c5","resourceType":"GMSpriteFrame","resourceVersion":"2.0",}, + ], + "gridX":0, + "gridY":0, + "height":16, + "HTile":false, + "layers":[ + {"$GMImageLayer":"","%Name":"1a9d0e9a-6828-4fb4-949d-8ac643506e79","blendMode":0,"displayName":"default","isLocked":false,"name":"1a9d0e9a-6828-4fb4-949d-8ac643506e79","opacity":100.0,"resourceType":"GMImageLayer","resourceVersion":"2.0","visible":true,}, + ], + "name":"s_gear_16", + "nineSlice":null, + "origin":4, + "parent":{ + "name":"icon", + "path":"folders/theme/icon.yy", + }, + "preMultiplyAlpha":false, + "resourceType":"GMSprite", + "resourceVersion":"2.0", + "sequence":{ + "$GMSequence":"", + "%Name":"s_gear_16", + "autoRecord":true, + "backdropHeight":768, + "backdropImageOpacity":0.5, + "backdropImagePath":"", + "backdropWidth":1366, + "backdropXOffset":0.0, + "backdropYOffset":0.0, + "events":{ + "$KeyframeStore":"", + "Keyframes":[], + "resourceType":"KeyframeStore", + "resourceVersion":"2.0", + }, + "eventStubScript":null, + "eventToFunction":{}, + "length":1.0, + "lockOrigin":false, + "moments":{ + "$KeyframeStore":"", + "Keyframes":[], + "resourceType":"KeyframeStore", + "resourceVersion":"2.0", + }, + "name":"s_gear_16", + "playback":1, + "playbackSpeed":30.0, + "playbackSpeedType":0, + "resourceType":"GMSequence", + "resourceVersion":"2.0", + "showBackdrop":true, + "showBackdropImage":false, + "timeUnits":1, + "tracks":[ + {"$GMSpriteFramesTrack":"","builtinName":0,"events":[],"inheritsTrackColour":true,"interpolation":1,"isCreationTrack":false,"keyframes":{"$KeyframeStore":"","Keyframes":[ + {"$Keyframe":"","Channels":{ + "0":{"$SpriteFrameKeyframe":"","Id":{"name":"3a09c235-6df0-4ae2-bdb3-7f77000112c5","path":"sprites/s_gear_16/s_gear_16.yy",},"resourceType":"SpriteFrameKeyframe","resourceVersion":"2.0",}, + },"Disabled":false,"id":"8635300c-8a73-4359-b1b7-96fd026586fd","IsCreationKey":false,"Key":0.0,"Length":1.0,"resourceType":"Keyframe","resourceVersion":"2.0","Stretch":false,}, + ],"resourceType":"KeyframeStore","resourceVersion":"2.0",},"modifiers":[],"name":"frames","resourceType":"GMSpriteFramesTrack","resourceVersion":"2.0","spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, + ], + "visibleRange":null, + "volume":1.0, + "xorigin":8, + "yorigin":8, + }, + "swatchColours":null, + "swfPrecision":0.5, + "textureGroupId":{ + "name":"Default", + "path":"texturegroups/Default", + }, + "type":0, + "VTile":false, + "width":16, +} \ No newline at end of file diff --git a/sprites/s_icon_accept_16/75811aa7-54ad-43d9-b492-26bcbd1e4b0f.png b/sprites/s_icon_accept_16/75811aa7-54ad-43d9-b492-26bcbd1e4b0f.png deleted file mode 100644 index d13012907..000000000 Binary files a/sprites/s_icon_accept_16/75811aa7-54ad-43d9-b492-26bcbd1e4b0f.png and /dev/null differ diff --git a/sprites/s_icon_accept_16/80af80c7-6975-45d6-bcfe-3d54cf57e8a9.png b/sprites/s_icon_accept_16/80af80c7-6975-45d6-bcfe-3d54cf57e8a9.png new file mode 100644 index 000000000..d88a8d0e7 Binary files /dev/null and b/sprites/s_icon_accept_16/80af80c7-6975-45d6-bcfe-3d54cf57e8a9.png differ diff --git a/sprites/s_icon_accept_16/layers/75811aa7-54ad-43d9-b492-26bcbd1e4b0f/68fa398e-a6ec-431b-b778-0f2ff3db29aa.png b/sprites/s_icon_accept_16/layers/75811aa7-54ad-43d9-b492-26bcbd1e4b0f/68fa398e-a6ec-431b-b778-0f2ff3db29aa.png deleted file mode 100644 index d13012907..000000000 Binary files a/sprites/s_icon_accept_16/layers/75811aa7-54ad-43d9-b492-26bcbd1e4b0f/68fa398e-a6ec-431b-b778-0f2ff3db29aa.png and /dev/null differ diff --git a/sprites/s_icon_accept_16/layers/80af80c7-6975-45d6-bcfe-3d54cf57e8a9/a169c6e0-5e28-47e5-b939-74f7e9805786.png b/sprites/s_icon_accept_16/layers/80af80c7-6975-45d6-bcfe-3d54cf57e8a9/a169c6e0-5e28-47e5-b939-74f7e9805786.png new file mode 100644 index 000000000..d88a8d0e7 Binary files /dev/null and b/sprites/s_icon_accept_16/layers/80af80c7-6975-45d6-bcfe-3d54cf57e8a9/a169c6e0-5e28-47e5-b939-74f7e9805786.png differ diff --git a/sprites/s_icon_accept_16/s_icon_accept_16.yy b/sprites/s_icon_accept_16/s_icon_accept_16.yy index 93fa5252f..15534719e 100644 --- a/sprites/s_icon_accept_16/s_icon_accept_16.yy +++ b/sprites/s_icon_accept_16/s_icon_accept_16.yy @@ -2,9 +2,9 @@ "$GMSprite":"", "%Name":"s_icon_accept_16", "bboxMode":0, - "bbox_bottom":13, - "bbox_left":1, - "bbox_right":14, + "bbox_bottom":14, + "bbox_left":0, + "bbox_right":15, "bbox_top":2, "collisionKind":1, "collisionTolerance":0, @@ -12,14 +12,14 @@ "edgeFiltering":false, "For3D":false, "frames":[ - {"$GMSpriteFrame":"","%Name":"75811aa7-54ad-43d9-b492-26bcbd1e4b0f","name":"75811aa7-54ad-43d9-b492-26bcbd1e4b0f","resourceType":"GMSpriteFrame","resourceVersion":"2.0",}, + {"$GMSpriteFrame":"","%Name":"80af80c7-6975-45d6-bcfe-3d54cf57e8a9","name":"80af80c7-6975-45d6-bcfe-3d54cf57e8a9","resourceType":"GMSpriteFrame","resourceVersion":"2.0",}, ], "gridX":0, "gridY":0, "height":16, "HTile":false, "layers":[ - {"$GMImageLayer":"","%Name":"68fa398e-a6ec-431b-b778-0f2ff3db29aa","blendMode":0,"displayName":"default","isLocked":false,"name":"68fa398e-a6ec-431b-b778-0f2ff3db29aa","opacity":100.0,"resourceType":"GMImageLayer","resourceVersion":"2.0","visible":true,}, + {"$GMImageLayer":"","%Name":"a169c6e0-5e28-47e5-b939-74f7e9805786","blendMode":0,"displayName":"default","isLocked":false,"name":"a169c6e0-5e28-47e5-b939-74f7e9805786","opacity":100.0,"resourceType":"GMImageLayer","resourceVersion":"2.0","visible":true,}, ], "name":"s_icon_accept_16", "nineSlice":null, @@ -69,8 +69,8 @@ "tracks":[ {"$GMSpriteFramesTrack":"","builtinName":0,"events":[],"inheritsTrackColour":true,"interpolation":1,"isCreationTrack":false,"keyframes":{"$KeyframeStore":"","Keyframes":[ {"$Keyframe":"","Channels":{ - "0":{"$SpriteFrameKeyframe":"","Id":{"name":"75811aa7-54ad-43d9-b492-26bcbd1e4b0f","path":"sprites/s_icon_accept_16/s_icon_accept_16.yy",},"resourceType":"SpriteFrameKeyframe","resourceVersion":"2.0",}, - },"Disabled":false,"id":"d2c08c0f-e33e-41d3-96aa-349b2d0b6c88","IsCreationKey":false,"Key":0.0,"Length":1.0,"resourceType":"Keyframe","resourceVersion":"2.0","Stretch":false,}, + "0":{"$SpriteFrameKeyframe":"","Id":{"name":"80af80c7-6975-45d6-bcfe-3d54cf57e8a9","path":"sprites/s_icon_accept_16/s_icon_accept_16.yy",},"resourceType":"SpriteFrameKeyframe","resourceVersion":"2.0",}, + },"Disabled":false,"id":"8f7891f5-e252-4fdc-809f-b5cd5f618276","IsCreationKey":false,"Key":0.0,"Length":1.0,"resourceType":"Keyframe","resourceVersion":"2.0","Stretch":false,}, ],"resourceType":"KeyframeStore","resourceVersion":"2.0",},"modifiers":[],"name":"frames","resourceType":"GMSpriteFramesTrack","resourceVersion":"2.0","spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, ], "visibleRange":null, diff --git a/sprites/s_tool_side/s_tool_side.yy b/sprites/s_tool_side/s_tool_side.yy index cd62decae..e796c1827 100644 --- a/sprites/s_tool_side/s_tool_side.yy +++ b/sprites/s_tool_side/s_tool_side.yy @@ -42,7 +42,7 @@ ], "top":4, }, - "origin":4, + "origin":0, "parent":{ "name":"UI", "path":"folders/theme/UI.yy", @@ -94,8 +94,8 @@ ], "visibleRange":null, "volume":1.0, - "xorigin":6, - "yorigin":6, + "xorigin":0, + "yorigin":0, }, "swatchColours":null, "swfPrecision":0.5,