mirror of
https://github.com/Ttanasart-pt/Pixel-Composer.git
synced 2025-01-23 19:38:05 +01:00
Input prefetct, structurize display data,
This commit is contained in:
parent
9380d2d77c
commit
387105fb53
337 changed files with 1798 additions and 1770 deletions
|
@ -35,7 +35,7 @@ event_inherited();
|
|||
var hh = ui(100);
|
||||
var pad = ui(16);
|
||||
|
||||
var arr = target.inputs[| 0].getValue();
|
||||
var arr = target.getInputData(0);
|
||||
if(array_length(arr) != array_length(target.spr))
|
||||
target.updatePaths(arr);
|
||||
|
||||
|
@ -112,7 +112,7 @@ event_inherited();
|
|||
if(menu > -1) {
|
||||
menuCall("image_array_edit_menu",,, [
|
||||
menuItem(__txt("Remove"), function() {
|
||||
var arr = target.inputs[| 0].getValue();
|
||||
var arr = target.getInputData(0);
|
||||
array_delete(arr, menuOn, 1);
|
||||
target.inputs[| 0].setValue(arr);
|
||||
})
|
||||
|
@ -127,7 +127,7 @@ event_inherited();
|
|||
function rearrange(oldindex, newindex) {
|
||||
if(oldindex == newindex) return;
|
||||
|
||||
var arr = target.inputs[| 0].getValue();
|
||||
var arr = target.getInputData(0);
|
||||
var val = arr[oldindex];
|
||||
array_delete(arr, oldindex, 1);
|
||||
array_insert(arr, newindex, val);
|
||||
|
@ -138,7 +138,7 @@ event_inherited();
|
|||
sortAsc = true;
|
||||
function sortByName() {
|
||||
if(!target) return 0;
|
||||
var arr = target.inputs[| 0].getValue();
|
||||
var arr = target.getInputData(0);
|
||||
|
||||
array_sort(arr, bool(sortAsc));
|
||||
sortAsc = !sortAsc;
|
||||
|
|
|
@ -33,7 +33,7 @@ if !target exit;
|
|||
key_release();
|
||||
if(path != "") {
|
||||
var paths = paths_to_array(path);
|
||||
var arr = target.inputs[| 0].getValue();
|
||||
var arr = target.getInputData(0);
|
||||
|
||||
for( var i = 0, n = array_length(paths); i < n; i++ )
|
||||
array_push(arr, paths[i]);
|
||||
|
|
|
@ -292,12 +292,12 @@ enum CAMERA_PROJ {
|
|||
}
|
||||
|
||||
function _3d_gizmo(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
|
||||
var _gpos = inputs[| global_pos].getValue();
|
||||
var _gsca = inputs[| global_sca].getValue();
|
||||
var _gpos = getInputData(global_pos);
|
||||
var _gsca = getInputData(global_sca);
|
||||
|
||||
var _pos = inputs[| input_pos].getValue();
|
||||
var _rot = inputs[| input_rot].getValue();
|
||||
var _sca = inputs[| input_sca].getValue();
|
||||
var _pos = getInputData(input_pos);
|
||||
var _rot = getInputData(input_rot);
|
||||
var _sca = getInputData(input_sca);
|
||||
|
||||
var cx = _x + _gpos[0] * _s;
|
||||
var cy = _y + _gpos[1] * _s;
|
||||
|
|
|
@ -19,7 +19,7 @@ function __Node_3D_Combine(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
|
||||
inputs[| 4] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector)
|
||||
.setUnitRef( function() { return inputs[| 2].getValue(); }, VALUE_UNIT.reference)
|
||||
.setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference)
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 5] = nodeValue("Render scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ])
|
||||
|
@ -31,11 +31,11 @@ function __Node_3D_Combine(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 7] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01])
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 8] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01])
|
||||
.setDisplay(VALUE_DISPLAY.slider)
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 9] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white)
|
||||
|
@ -49,7 +49,7 @@ function __Node_3D_Combine(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 12] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 90, 1 ])
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 90, 1 ] })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 13] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
@ -124,14 +124,14 @@ function __Node_3D_Combine(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
}
|
||||
|
||||
static submit_vertex = function() {
|
||||
var _lpos = inputs[| 1].getValue();
|
||||
var _lrot = inputs[| 2].getValue();
|
||||
var _lsca = inputs[| 3].getValue();
|
||||
var _lpos = getInputData(1);
|
||||
var _lrot = getInputData(2);
|
||||
var _lsca = getInputData(3);
|
||||
|
||||
_3d_local_transform(_lpos, _lrot, _lsca);
|
||||
|
||||
for( var i = input_fix_len; i < ds_list_size(inputs) - 1; i++ ) {
|
||||
var sv = inputs[| i].getValue();
|
||||
var sv = getInputData(i);
|
||||
|
||||
if(is_array(sv)) {
|
||||
for( var j = 0; j < array_length(sv); j++ ) {
|
||||
|
@ -146,23 +146,23 @@ function __Node_3D_Combine(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _lpos = inputs[| 1].getValue();
|
||||
var _lrot = inputs[| 2].getValue();
|
||||
var _lsca = inputs[| 3].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var _lpos = getInputData(1);
|
||||
var _lrot = getInputData(2);
|
||||
var _lsca = getInputData(3);
|
||||
|
||||
var _pos = inputs[| 4].getValue();
|
||||
var _sca = inputs[| 5].getValue();
|
||||
var _pos = getInputData(4);
|
||||
var _sca = getInputData(5);
|
||||
|
||||
var _ldir = inputs[| 6].getValue();
|
||||
var _lhgt = inputs[| 7].getValue();
|
||||
var _lint = inputs[| 8].getValue();
|
||||
var _lclr = inputs[| 9].getValue();
|
||||
var _aclr = inputs[| 10].getValue();
|
||||
var _ldir = getInputData( 6);
|
||||
var _lhgt = getInputData( 7);
|
||||
var _lint = getInputData( 8);
|
||||
var _lclr = getInputData( 9);
|
||||
var _aclr = getInputData(10);
|
||||
|
||||
var _proj = inputs[| 11].getValue();
|
||||
var _fov = inputs[| 12].getValue();
|
||||
var _dimS = inputs[| 13].getValue();
|
||||
var _proj = getInputData(11);
|
||||
var _fov = getInputData(12);
|
||||
var _dimS = getInputData(13);
|
||||
|
||||
inputs[| 12].setVisible(_proj);
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ function __Node_3D_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
|
||||
inputs[| 4] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector)
|
||||
.setUnitRef( function() { return inputs[| 0].getValue(); }, VALUE_UNIT.reference);
|
||||
.setUnitRef( function() { return getInputData(0); }, VALUE_UNIT.reference);
|
||||
|
||||
inputs[| 5] = nodeValue("Render scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -24,10 +24,10 @@ function __Node_3D_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 7] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 8] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 9] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
|
@ -41,14 +41,14 @@ function __Node_3D_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 13] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 14] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
|
||||
inputs[| 15] = nodeValue("Displacement map", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, noone);
|
||||
|
||||
inputs[| 16] = nodeValue("Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 4, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] });
|
||||
|
||||
input_display_list = [ 11,
|
||||
["Output", true], 0, 14,
|
||||
|
@ -85,9 +85,9 @@ function __Node_3D_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
}
|
||||
|
||||
static submit_vertex = function() {
|
||||
var _lpos = inputs[| 1].getValue();
|
||||
var _lrot = inputs[| 2].getValue();
|
||||
var _lsca = inputs[| 3].getValue();
|
||||
var _lpos = getInputData(1);
|
||||
var _lrot = getInputData(2);
|
||||
var _lsca = getInputData(3);
|
||||
|
||||
_3d_local_transform(_lpos, _lrot, _lsca);
|
||||
|
||||
|
@ -98,7 +98,7 @@ function __Node_3D_Displace(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
}
|
||||
|
||||
static step = function() {
|
||||
var _proj = inputs[| 12].getValue();
|
||||
var _proj = getInputData(12);
|
||||
inputs[| 13].setVisible(_proj);
|
||||
}
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ function __Node_3D_Export(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
.setVisible(true, true);
|
||||
|
||||
inputs[| 1] = nodeValue("Path", self, JUNCTION_CONNECT.input, VALUE_TYPE.path, "", "Export location without '.obj' extension." )
|
||||
.setDisplay(VALUE_DISPLAY.path_save, ["*.obj", ""]);
|
||||
.setDisplay(VALUE_DISPLAY.path_save, { filter: "*.obj" });
|
||||
|
||||
inputs[| 2] = nodeValue("Export texture", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true );
|
||||
|
||||
|
@ -19,9 +19,9 @@ function __Node_3D_Export(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
static onInspector1Update = function() { export(); }
|
||||
|
||||
static export = function() {
|
||||
var vert = inputs[| 0].getValue();
|
||||
var path = inputs[| 1].getValue();
|
||||
var text = inputs[| 2].getValue();
|
||||
var vert = getInputData(0);
|
||||
var path = getInputData(1);
|
||||
var text = getInputData(2);
|
||||
|
||||
if(array_length(vert) == 0) return;
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ function __Node_3D_Extrude(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
|
||||
inputs[| 5] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector)
|
||||
.setUnitRef( function() { return inputs[| 1].getValue(); }, VALUE_UNIT.reference);
|
||||
.setUnitRef( function() { return getInputData(1); }, VALUE_UNIT.reference);
|
||||
|
||||
inputs[| 6] = nodeValue("Render rotation", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0, 0 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -26,19 +26,16 @@ function __Node_3D_Extrude(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
||||
inputs[| 8] = nodeValue("Manual generate", self, JUNCTION_CONNECT.input, VALUE_TYPE.trigger, 0)
|
||||
.setDisplay(VALUE_DISPLAY.button, [ function() {
|
||||
generateMesh();
|
||||
doUpdate();
|
||||
}, "Generate"] );
|
||||
.setDisplay(VALUE_DISPLAY.button, { name: "Generate", onClick: function() { generateMesh(); doUpdate(); } });
|
||||
|
||||
inputs[| 9] = nodeValue("Light direction", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 10] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 11] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 12] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
inputs[| 13] = nodeValue("Ambient color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_grey);
|
||||
|
@ -52,7 +49,7 @@ function __Node_3D_Extrude(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 17] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 18] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
||||
|
@ -108,7 +105,7 @@ function __Node_3D_Extrude(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
}
|
||||
|
||||
static generateMesh = function() {
|
||||
var _ins = inputs[| 0].getValue();
|
||||
var _ins = getInputData(0);
|
||||
if(!is_array(_ins)) _ins = [ _ins ];
|
||||
|
||||
for( var i = 0, n = array_length(vertexObjects); i < n; i++ ) {
|
||||
|
|
|
@ -9,7 +9,7 @@ function Node_3D_Light(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
inputs[| in_d3d + 1] = nodeValue("Color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
inputs[| in_d3d + 2] = nodeValue("Intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
in_light = ds_list_size(inputs);
|
||||
|
||||
|
|
|
@ -2,21 +2,21 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
name = "3D Object";
|
||||
|
||||
inputs[| 0] = nodeValue("Path", self, JUNCTION_CONNECT.input, VALUE_TYPE.path, "")
|
||||
.setDisplay(VALUE_DISPLAY.path_load, [ "*.obj", "" ])
|
||||
.setDisplay(VALUE_DISPLAY.path_load, { filter: "*.obj" })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 1] = nodeValue("Generate", self, JUNCTION_CONNECT.input, VALUE_TYPE.trigger, 0)
|
||||
.setDisplay(VALUE_DISPLAY.button, [ function() {
|
||||
.setDisplay(VALUE_DISPLAY.button, { name: "Generate", onClick: function() {
|
||||
updateObj();
|
||||
doUpdate();
|
||||
}, "Generate"] );
|
||||
} });
|
||||
|
||||
inputs[| 2] = nodeValue("Dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, DEF_SURF)
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
||||
inputs[| 3] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector)
|
||||
.setUnitRef( function() { return inputs[| 2].getValue(); }, VALUE_UNIT.reference);
|
||||
.setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference);
|
||||
|
||||
inputs[| 4] = nodeValue("Render rotation", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0, 0 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -29,11 +29,11 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 7] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01])
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 8] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01])
|
||||
.setDisplay(VALUE_DISPLAY.slider)
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 9] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white)
|
||||
|
@ -59,7 +59,7 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 16] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 90, 1 ])
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 90, 1 ] })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 17] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
@ -137,10 +137,10 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
}
|
||||
|
||||
static updateObj = function(updateMat = true) {
|
||||
var _path = inputs[| 0].getValue();
|
||||
var _path = getInputData(0);
|
||||
if(!file_exists(_path)) return;
|
||||
|
||||
var _flip = inputs[| 12].getValue();
|
||||
var _flip = getInputData(12);
|
||||
var _dir = filename_dir(_path);
|
||||
var _pathMtl = string_copy(_path, 1, string_length(_path) - 4) + ".mtl";
|
||||
|
||||
|
@ -175,9 +175,9 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
}
|
||||
|
||||
static submit_vertex = function() {
|
||||
var _lpos = inputs[| 14].getValue();
|
||||
var _lrot = inputs[| 13].getValue();
|
||||
var _lsca = inputs[| 11].getValue();
|
||||
var _lpos = getInputData(14);
|
||||
var _lrot = getInputData(13);
|
||||
var _lsca = getInputData(11);
|
||||
|
||||
_3d_local_transform(_lpos, _lrot, _lsca);
|
||||
|
||||
|
@ -185,7 +185,7 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
if(i >= array_length(materialIndex)) continue;
|
||||
|
||||
var mIndex = materialIndex[i];
|
||||
var tex = inputs[| input_length + mIndex].getValue();
|
||||
var tex = getInputData(input_length + mIndex);
|
||||
|
||||
if(!is_surface(tex)) continue;
|
||||
vertex_submit(VB[i], pr_trianglelist, surface_get_texture(tex));
|
||||
|
@ -208,24 +208,24 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
do_reset_material = false;
|
||||
}
|
||||
|
||||
var _dim = inputs[| 2].getValue();
|
||||
var _pos = inputs[| 3].getValue();
|
||||
//var _rot = inputs[| 4].getValue();
|
||||
var _sca = inputs[| 5].getValue();
|
||||
var _dim = getInputData(2);
|
||||
var _pos = getInputData(3);
|
||||
//var _rot = getInputData(4);
|
||||
var _sca = getInputData(5);
|
||||
|
||||
var _ldir = inputs[| 6].getValue();
|
||||
var _lhgt = inputs[| 7].getValue();
|
||||
var _lint = inputs[| 8].getValue();
|
||||
var _lclr = inputs[| 9].getValue();
|
||||
var _aclr = inputs[| 10].getValue();
|
||||
var _ldir = getInputData(6);
|
||||
var _lhgt = getInputData(7);
|
||||
var _lint = getInputData(8);
|
||||
var _lclr = getInputData(9);
|
||||
var _aclr = getInputData(10);
|
||||
|
||||
var _lpos = inputs[| 14].getValue();
|
||||
var _lrot = inputs[| 13].getValue();
|
||||
var _lsca = inputs[| 11].getValue();
|
||||
var _lpos = getInputData(14);
|
||||
var _lrot = getInputData(13);
|
||||
var _lsca = getInputData(11);
|
||||
|
||||
var _proj = inputs[| 15].getValue();
|
||||
var _fov = inputs[| 16].getValue();
|
||||
var _dimS = inputs[| 17].getValue();
|
||||
var _proj = getInputData(15);
|
||||
var _fov = getInputData(16);
|
||||
var _dimS = getInputData(17);
|
||||
|
||||
inputs[| 16].setVisible(_proj == 1);
|
||||
|
||||
|
@ -248,7 +248,7 @@ function __Node_3D_Obj(_x, _y, _group = noone) : Node(_x, _y, _group) constructo
|
|||
if(j >= array_length(materialIndex)) continue;
|
||||
|
||||
var mIndex = materialIndex[j];
|
||||
var tex = inputs[| input_length + mIndex].getValue();
|
||||
var tex = getInputData(input_length + mIndex);
|
||||
|
||||
if(!is_surface(tex)) continue;
|
||||
vertex_submit(VB[j], pr_trianglelist, surface_get_texture(tex));
|
||||
|
|
|
@ -31,7 +31,7 @@ function __Node_3D_Plane(_x, _y, _group = noone) : Node_Processor(_x, _y, _group
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 9] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 10] = nodeValue("Texture scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
|
|
@ -21,10 +21,10 @@ function __Node_3D_Cone(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 6] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 7] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 8] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
inputs[| 9] = nodeValue("Ambient color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_grey);
|
||||
|
@ -40,7 +40,7 @@ function __Node_3D_Cone(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 13] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 14] = nodeValue("Sides", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 16);
|
||||
|
||||
|
|
|
@ -33,10 +33,10 @@ function __Node_3D_Cube(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 14] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 15] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 16] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
|
@ -53,7 +53,7 @@ function __Node_3D_Cube(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 21] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 22] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
||||
|
|
|
@ -30,10 +30,10 @@ function __Node_3D_Cylinder(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 11] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 12] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 13] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
inputs[| 14] = nodeValue("Ambient color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_grey);
|
||||
|
@ -49,10 +49,10 @@ function __Node_3D_Cylinder(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 18] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 19] = nodeValue("Taper", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 20] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
||||
|
|
|
@ -27,10 +27,10 @@ function __Node_3D_Sphere(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 8] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 9] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 10] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
inputs[| 11] = nodeValue("Ambient color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_grey);
|
||||
|
@ -46,7 +46,7 @@ function __Node_3D_Sphere(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 15] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 16] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
// inputs[| 3] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
// .setDisplay(VALUE_DISPLAY.vector)
|
||||
// .setUnitRef( function() { return inputs[| 2].getValue(); }, VALUE_UNIT.reference);
|
||||
// .setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference);
|
||||
|
||||
// inputs[| 4] = nodeValue("Render rotation", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0, 0 ])
|
||||
// .setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -19,11 +19,11 @@
|
|||
// .rejectArray();
|
||||
|
||||
// inputs[| 7] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
// .setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01])
|
||||
// .setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] })
|
||||
// .rejectArray();
|
||||
|
||||
// inputs[| 8] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
// .setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01])
|
||||
// .setDisplay(VALUE_DISPLAY.slider)
|
||||
// .rejectArray();
|
||||
|
||||
// inputs[| 9] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white)
|
||||
|
@ -37,7 +37,7 @@
|
|||
// .rejectArray();
|
||||
|
||||
// inputs[| 16] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
// .setDisplay(VALUE_DISPLAY.slider, [ 0, 90, 1 ])
|
||||
// .setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 90, 1 ] })
|
||||
// .rejectArray();
|
||||
|
||||
// inputs[| 17] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
@ -115,8 +115,8 @@
|
|||
// materials = [];
|
||||
|
||||
// static updateObj = function(updateMat = true) {
|
||||
// var _path = inputs[| 0].getValue();
|
||||
// var _flip = inputs[| 12].getValue();
|
||||
// var _path = getInputData(0);
|
||||
// var _flip = getInputData(12);
|
||||
// var _dir = filename_dir(_path);
|
||||
// var _pathMtl = string_copy(_path, 1, string_length(_path) - 4) + ".mtl";
|
||||
|
||||
|
@ -151,9 +151,9 @@
|
|||
// }
|
||||
|
||||
// static submit_vertex = function() {
|
||||
// var _lpos = inputs[| 14].getValue();
|
||||
// var _lrot = inputs[| 13].getValue();
|
||||
// var _lsca = inputs[| 11].getValue();
|
||||
// var _lpos = getInputData(14);
|
||||
// var _lrot = getInputData(13);
|
||||
// var _lsca = getInputData(11);
|
||||
|
||||
// _3d_local_transform(_lpos, _lrot, _lsca);
|
||||
|
||||
|
@ -161,7 +161,7 @@
|
|||
// if(i >= array_length(materialIndex)) continue;
|
||||
|
||||
// var mIndex = materialIndex[i];
|
||||
// var tex = inputs[| input_length + mIndex].getValue();
|
||||
// var tex = getInputData(input_length + mIndex);
|
||||
|
||||
// if(!is_surface(tex)) continue;
|
||||
// vertex_submit(VB[i], pr_trianglelist, surface_get_texture(tex));
|
||||
|
@ -184,24 +184,24 @@
|
|||
// do_reset_material = false;
|
||||
// }
|
||||
|
||||
// var _dim = inputs[| 2].getValue();
|
||||
// var _pos = inputs[| 3].getValue();
|
||||
// //var _rot = inputs[| 4].getValue();
|
||||
// var _sca = inputs[| 5].getValue();
|
||||
// var _dim = getInputData(2);
|
||||
// var _pos = getInputData(3);
|
||||
// //var _rot = getInputData(4);
|
||||
// var _sca = getInputData(5);
|
||||
|
||||
// var _ldir = inputs[| 6].getValue();
|
||||
// var _lhgt = inputs[| 7].getValue();
|
||||
// var _lint = inputs[| 8].getValue();
|
||||
// var _lclr = inputs[| 9].getValue();
|
||||
// var _aclr = inputs[| 10].getValue();
|
||||
// var _ldir = getInputData(6);
|
||||
// var _lhgt = getInputData(7);
|
||||
// var _lint = getInputData(8);
|
||||
// var _lclr = getInputData(9);
|
||||
// var _aclr = getInputData(10);
|
||||
|
||||
// var _lpos = inputs[| 14].getValue();
|
||||
// var _lrot = inputs[| 13].getValue();
|
||||
// var _lsca = inputs[| 11].getValue();
|
||||
// var _lpos = getInputData(14);
|
||||
// var _lrot = getInputData(13);
|
||||
// var _lsca = getInputData(11);
|
||||
|
||||
// var _proj = inputs[| 15].getValue();
|
||||
// var _fov = inputs[| 16].getValue();
|
||||
// var _dimS = inputs[| 17].getValue();
|
||||
// var _proj = getInputData(15);
|
||||
// var _fov = getInputData(16);
|
||||
// var _dimS = getInputData(17);
|
||||
|
||||
// inputs[| 16].setVisible(_proj == 1);
|
||||
|
||||
|
@ -224,7 +224,7 @@
|
|||
// if(i >= array_length(materialIndex)) continue;
|
||||
|
||||
// var mIndex = materialIndex[i];
|
||||
// var tex = inputs[| input_length + mIndex].getValue();
|
||||
// var tex = getInputData(input_length + mIndex);
|
||||
|
||||
// if(!is_surface(tex)) continue;
|
||||
// vertex_submit(VB[i], pr_trianglelist, surface_get_texture(tex));
|
||||
|
|
|
@ -15,7 +15,7 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
|
||||
inputs[| 4] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector)
|
||||
.setUnitRef( function() { return inputs[| 0].getValue(); }, VALUE_UNIT.reference);
|
||||
.setUnitRef( function() { return getInputData(0); }, VALUE_UNIT.reference);
|
||||
|
||||
inputs[| 5] = nodeValue("Render scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -24,10 +24,10 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 7] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 8] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 9] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
|
@ -64,7 +64,7 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 21] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 22] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
||||
|
@ -94,24 +94,24 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
}
|
||||
|
||||
static submit_vertex = function() {
|
||||
var _lpos = inputs[| 1].getValue();
|
||||
var _lrot = inputs[| 2].getValue();
|
||||
var _lsca = inputs[| 3].getValue();
|
||||
var _lpos = getInputData(1);
|
||||
var _lrot = getInputData(2);
|
||||
var _lsca = getInputData(3);
|
||||
|
||||
var sv = inputs[| 11].getValue();
|
||||
var sv = getInputData(11);
|
||||
if(sv == noone) return;
|
||||
|
||||
var _samo = inputs[| 12].getValue();
|
||||
var _patt = inputs[| 16].getValue();
|
||||
var _samo = getInputData(12);
|
||||
var _patt = getInputData(16);
|
||||
|
||||
var _srot = inputs[| 14].getValue();
|
||||
var _ssca = inputs[| 15].getValue();
|
||||
var _srot = getInputData(14);
|
||||
var _ssca = getInputData(15);
|
||||
|
||||
var _spos = inputs[| 13].getValue();
|
||||
var _spos = getInputData(13);
|
||||
|
||||
var _raxs = inputs[| 17].getValue();
|
||||
var _rrad = inputs[| 18].getValue();
|
||||
var _rrot = inputs[| 19].getValue();
|
||||
var _raxs = getInputData(17);
|
||||
var _rrad = getInputData(18);
|
||||
var _rrot = getInputData(19);
|
||||
|
||||
_3d_local_transform(_lpos, _lrot, _lsca);
|
||||
for( var i = 0; i < _samo; i++ ) {
|
||||
|
@ -151,8 +151,8 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
}
|
||||
|
||||
static step = function() {
|
||||
var _proj = inputs[| 20].getValue();
|
||||
var _patt = inputs[| 16].getValue();
|
||||
var _proj = getInputData(20);
|
||||
var _patt = getInputData(16);
|
||||
|
||||
inputs[| 13].setVisible(_patt == 0);
|
||||
|
||||
|
@ -163,25 +163,25 @@ function __Node_3D_Repeat(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _lpos = inputs[| 1].getValue();
|
||||
var _lrot = inputs[| 2].getValue();
|
||||
var _lsca = inputs[| 3].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var _lpos = getInputData(1);
|
||||
var _lrot = getInputData(2);
|
||||
var _lsca = getInputData(3);
|
||||
|
||||
var _pos = inputs[| 4].getValue();
|
||||
var _sca = inputs[| 5].getValue();
|
||||
var _pos = getInputData(4);
|
||||
var _sca = getInputData(5);
|
||||
|
||||
var _ldir = inputs[| 6].getValue();
|
||||
var _lhgt = inputs[| 7].getValue();
|
||||
var _lint = inputs[| 8].getValue();
|
||||
var _lclr = inputs[| 9].getValue();
|
||||
var _aclr = inputs[| 10].getValue();
|
||||
var _ldir = getInputData(6);
|
||||
var _lhgt = getInputData(7);
|
||||
var _lint = getInputData(8);
|
||||
var _lclr = getInputData(9);
|
||||
var _aclr = getInputData(10);
|
||||
|
||||
var _proj = inputs[| 20].getValue();
|
||||
var _fov = inputs[| 21].getValue();
|
||||
var _dimS = inputs[| 22].getValue();
|
||||
var _proj = getInputData(20);
|
||||
var _fov = getInputData(21);
|
||||
var _dimS = getInputData(22);
|
||||
|
||||
var _patt = inputs[| 16].getValue();
|
||||
var _patt = getInputData(16);
|
||||
|
||||
for( var i = 0, n = array_length(output_display_list) - 1; i < n; i++ ) {
|
||||
var ind = output_display_list[i];
|
||||
|
|
|
@ -15,7 +15,7 @@ function __Node_3D_Transform(_x, _y, _group = noone) : Node_Processor(_x, _y, _g
|
|||
|
||||
inputs[| 4] = nodeValue("Render position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.5 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector)
|
||||
.setUnitRef( function() { return inputs[| 2].getValue(); }, VALUE_UNIT.reference);
|
||||
.setUnitRef( function() { return getInputData(2); }, VALUE_UNIT.reference);
|
||||
|
||||
inputs[| 5] = nodeValue("Render scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -24,10 +24,10 @@ function __Node_3D_Transform(_x, _y, _group = noone) : Node_Processor(_x, _y, _g
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 7] = nodeValue("Light height", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-1, 1, 0.01] });
|
||||
|
||||
inputs[| 8] = nodeValue("Light intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 9] = nodeValue("Light color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
|
@ -41,7 +41,7 @@ function __Node_3D_Transform(_x, _y, _group = noone) : Node_Processor(_x, _y, _g
|
|||
.rejectArray();
|
||||
|
||||
inputs[| 13] = nodeValue("Field of view", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 60)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 1, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 1, 90, 1 ] });
|
||||
|
||||
inputs[| 14] = nodeValue("Scale view with dimension", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true)
|
||||
|
||||
|
@ -69,11 +69,11 @@ function __Node_3D_Transform(_x, _y, _group = noone) : Node_Processor(_x, _y, _g
|
|||
}
|
||||
|
||||
static submit_vertex = function() {
|
||||
var _lpos = inputs[| 1].getValue();
|
||||
var _lrot = inputs[| 2].getValue();
|
||||
var _lsca = inputs[| 3].getValue();
|
||||
var _lpos = getInputData(1);
|
||||
var _lrot = getInputData(2);
|
||||
var _lsca = getInputData(3);
|
||||
|
||||
var sv = inputs[| 11].getValue();
|
||||
var sv = getInputData(11);
|
||||
if(sv == noone) return;
|
||||
|
||||
_3d_local_transform(_lpos, _lrot, _lsca);
|
||||
|
@ -86,7 +86,7 @@ function __Node_3D_Transform(_x, _y, _group = noone) : Node_Processor(_x, _y, _g
|
|||
}
|
||||
|
||||
static step = function() {
|
||||
var _proj = inputs[| 12].getValue();
|
||||
var _proj = getInputData(12);
|
||||
inputs[| 13].setVisible(_proj);
|
||||
}
|
||||
|
||||
|
|
|
@ -126,11 +126,11 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
|
||||
inputs[| 39] = nodeValue("Bounce amount", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5 )
|
||||
.rejectArray()
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 40] = nodeValue("Bounce friction", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.1, "Apply horizontal friction once particle stop bouncing." )
|
||||
.rejectArray()
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 41] = nodeValue("Position wiggle", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0 ] )
|
||||
.setDisplay(VALUE_DISPLAY.vector, { label: [ "Amplitude", "Period" ], linkable: false, per_line: true })
|
||||
|
@ -352,12 +352,12 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
}
|
||||
|
||||
render();
|
||||
seed = inputs[| 32].getValue();
|
||||
seed = getInputData(32);
|
||||
|
||||
var _wigg_pos = inputs[| 41].getValue();
|
||||
var _wigg_rot = inputs[| 42].getValue();
|
||||
var _wigg_sca = inputs[| 43].getValue();
|
||||
var _wigg_dir = inputs[| 20].getValue();
|
||||
var _wigg_pos = getInputData(41);
|
||||
var _wigg_rot = getInputData(42);
|
||||
var _wigg_sca = getInputData(43);
|
||||
var _wigg_dir = getInputData(20);
|
||||
|
||||
wiggle_maps.wig_psx.check(_wigg_pos[0], _wigg_pos[1], seed + 10);
|
||||
wiggle_maps.wig_psy.check(_wigg_pos[0], _wigg_pos[1], seed + 20);
|
||||
|
@ -366,8 +366,8 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
wiggle_maps.wig_scy.check(_wigg_sca[0], _wigg_sca[1], seed + 50);
|
||||
wiggle_maps.wig_dir.check(_wigg_dir[0], _wigg_dir[1], seed + 60);
|
||||
|
||||
var _curve_sca = inputs[| 11].getValue();
|
||||
var _curve_alp = inputs[| 14].getValue();
|
||||
var _curve_sca = getInputData(11);
|
||||
var _curve_alp = getInputData(14);
|
||||
|
||||
curve_scale = new curveMap(_curve_sca, PROJECT.animator.frames_total);
|
||||
curve_alpha = new curveMap(_curve_alp, PROJECT.animator.frames_total);
|
||||
|
@ -377,7 +377,7 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
surface_free_safe(surface_cache[$ keys[i]]);
|
||||
surface_cache = {};
|
||||
|
||||
var _loop = inputs[| 21].getValue();
|
||||
var _loop = getInputData(21);
|
||||
if(!_loop) return;
|
||||
|
||||
for(var i = 0; i < PROJECT.animator.frames_total; i++) {
|
||||
|
@ -385,7 +385,7 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
updateParticleForward();
|
||||
}
|
||||
|
||||
seed = inputs[| 32].getValue();
|
||||
seed = getInputData(32);
|
||||
} #endregion
|
||||
|
||||
function checkPartPool() { #region
|
||||
|
@ -449,12 +449,12 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
static onStep = function() {}
|
||||
|
||||
static step = function() { #region
|
||||
var _inSurf = inputs[| 0].getValue();
|
||||
var _dist = inputs[| 4].getValue();
|
||||
var _scatt = inputs[| 24].getValue();
|
||||
var _dirAng = inputs[| 29].getValue();
|
||||
var _turn = inputs[| 34].getValue();
|
||||
var _colGnd = inputs[| 37].getValue();
|
||||
var _inSurf = getInputData(0);
|
||||
var _dist = getInputData(4);
|
||||
var _scatt = getInputData(24);
|
||||
var _dirAng = getInputData(29);
|
||||
var _turn = getInputData(34);
|
||||
var _colGnd = getInputData(37);
|
||||
|
||||
inputs[| 6].setVisible(!_dirAng);
|
||||
|
||||
|
@ -476,7 +476,7 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
|
||||
if(is_array(_inSurf)) {
|
||||
inputs[| 22].setVisible(true);
|
||||
var _type = inputs[| 22].getValue();
|
||||
var _type = getInputData(22);
|
||||
if(_type == 2) {
|
||||
inputs[| 23].setVisible(true);
|
||||
inputs[| 26].setVisible(true);
|
||||
|
@ -496,7 +496,7 @@ function Node_VFX_Spawner_Base(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
|
||||
static update = function(frame = PROJECT.animator.current_frame) { #region
|
||||
checkPartPool();
|
||||
var _spawn_type = inputs[| 16].getValue();
|
||||
var _spawn_type = getInputData(16);
|
||||
if(_spawn_type == 0) inputs[| 1].name = "Spawn delay";
|
||||
else inputs[| 1].name = "Spawn frame";
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
#macro STRAND_EFFECTOR_PRE \
|
||||
var _str = inputs[| 0].getValue(); \
|
||||
var _typ = inputs[| 1].getValue(); \
|
||||
var _pos = inputs[| 2].getValue(); \
|
||||
var _ran = inputs[| 3].getValue(); \
|
||||
var _dir = inputs[| 4].getValue(); \
|
||||
var _fal = inputs[| 5].getValue(); var fal = _ran * _fal; \
|
||||
var _str = getInputData(0); \
|
||||
var _typ = getInputData(1); \
|
||||
var _pos = getInputData(2); \
|
||||
var _ran = getInputData(3); \
|
||||
var _dir = getInputData(4); \
|
||||
var _fal = getInputData(5); var fal = _ran * _fal; \
|
||||
\
|
||||
if(_str == noone) return; \
|
||||
var __str = _str; \
|
||||
|
@ -55,7 +55,7 @@ function _Node_Strand_Affector(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 5] = nodeValue("Falloff", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.2)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
outputs[| 0] = nodeValue("Strand", self, JUNCTION_CONNECT.output, VALUE_TYPE.strands, noone);
|
||||
|
||||
|
@ -66,11 +66,11 @@ function _Node_Strand_Affector(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
];
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) {
|
||||
var _typ = inputs[| 1].getValue();
|
||||
var _pos = inputs[| 2].getValue();
|
||||
var _ran = inputs[| 3].getValue();
|
||||
var _dir = inputs[| 4].getValue();
|
||||
var _fal = inputs[| 5].getValue();
|
||||
var _typ = getInputData(1);
|
||||
var _pos = getInputData(2);
|
||||
var _ran = getInputData(3);
|
||||
var _dir = getInputData(4);
|
||||
var _fal = getInputData(5);
|
||||
|
||||
var px = _x + _pos[0] * _s;
|
||||
var py = _y + _pos[1] * _s;
|
||||
|
@ -148,7 +148,7 @@ function _Node_Strand_Affector(_x, _y, _group = noone) : Node(_x, _y, _group) co
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _typ = inputs[| 1].getValue();
|
||||
var _typ = getInputData(1);
|
||||
inputs[| 4].setVisible(_typ == 1);
|
||||
|
||||
STRAND_EFFECTOR_PRE
|
||||
|
|
|
@ -116,15 +116,15 @@ function areaBox(_onModify, _unit = noone) : widget() constructor {
|
|||
} #endregion
|
||||
|
||||
static drawParam = function(params) { #region
|
||||
return draw(params.x + params.w / 2, params.y + ui(40), params.data, params.extra_data, params.m);
|
||||
return draw(params.x + params.w / 2, params.y + ui(40), params.data, params.display_data, params.m);
|
||||
} #endregion
|
||||
|
||||
static draw = function(_x, _y, _data, _extra_data, _m) {
|
||||
static draw = function(_x, _y, _data, _display_data, _m) {
|
||||
x = _x;
|
||||
y = _y;
|
||||
w = 0;
|
||||
h = ui(204);
|
||||
mode = _extra_data.area_type;
|
||||
mode = _display_data.area_type;
|
||||
|
||||
var _bx = _x - ui(48);
|
||||
var _by = _y + ui(64 - 48);
|
||||
|
@ -218,7 +218,7 @@ function areaBox(_onModify, _unit = noone) : widget() constructor {
|
|||
break;
|
||||
}
|
||||
|
||||
_extra_data.area_type = (mode + 1) % 3;
|
||||
_display_data.area_type = (mode + 1) % 3;
|
||||
} #endregion
|
||||
}
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ function argumentRenderer(_typeArray = []) {
|
|||
var _h = 0;
|
||||
|
||||
_jType.editWidget.setFocusHover(_focus, _hover);
|
||||
_jType.editWidget.draw(tx, ty, ui(128), _th, _jType.display_data[_jType.showValue()], _m, argument_renderer.rx, argument_renderer.ry);
|
||||
_jType.editWidget.draw(tx, ty, ui(128), _th, _jType.display_data.data[_jType.showValue()], _m, argument_renderer.rx, argument_renderer.ry);
|
||||
|
||||
var _jName = inputs[| i + 0];
|
||||
_jName.editWidget.setFocusHover(_focus, _hover);
|
||||
|
|
|
@ -9,14 +9,14 @@ function Biterator(node) : VCT(node) constructor {
|
|||
dimension = VCT_var(VALUE_TYPE.integer, 0);
|
||||
shape = VCT_var(VALUE_TYPE.integer, 0);
|
||||
|
||||
shape_par[0] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, [- 8, 8, 1]);
|
||||
shape_par[1] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, [- 8, 8, 1]);
|
||||
shape_par[2] = VCT_var(VALUE_TYPE.integer, 2).setDisplay(VALUE_DISPLAY.slider, [ 0, 4, 1]);
|
||||
shape_par[3] = VCT_var(VALUE_TYPE.integer, 2).setDisplay(VALUE_DISPLAY.slider, [ 0, 4, 1]);
|
||||
shape_par[4] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, [ -4, 4, 1]);
|
||||
shape_par[5] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, [ -4, 4, 1]);
|
||||
shape_par[0] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, { range: [- 8, 8, 1] });
|
||||
shape_par[1] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, { range: [- 8, 8, 1] });
|
||||
shape_par[2] = VCT_var(VALUE_TYPE.integer, 2).setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 1] });
|
||||
shape_par[3] = VCT_var(VALUE_TYPE.integer, 2).setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 1] });
|
||||
shape_par[4] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, { range: [ -4, 4, 1] });
|
||||
shape_par[5] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, { range: [ -4, 4, 1] });
|
||||
|
||||
shape_par[5] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, [ -4, 4, 1]);
|
||||
shape_par[5] = VCT_var(VALUE_TYPE.integer, 0).setDisplay(VALUE_DISPLAY.slider, { range: [ -4, 4, 1] });
|
||||
|
||||
for( var i = 0; i < 3; i++ )
|
||||
color[i] = VCT_var(VALUE_TYPE.color, c_white);
|
||||
|
@ -31,7 +31,7 @@ function Biterator(node) : VCT(node) constructor {
|
|||
for( var i = 0; i < 4; i++ )
|
||||
kernel_toggle[i] = VCT_var(VALUE_TYPE.boolean, 0);
|
||||
for( var i = 0; i < 8; i++ )
|
||||
kernel_value[i] = VCT_var(VALUE_TYPE.integer, 1).setDisplay(VALUE_DISPLAY.slider, [1, 4, 1]);
|
||||
kernel_value[i] = VCT_var(VALUE_TYPE.integer, 1).setDisplay(VALUE_DISPLAY.slider, { range: [1, 4, 1] });
|
||||
|
||||
function process() {
|
||||
var _dimension = dimension.get();
|
||||
|
|
|
@ -72,8 +72,8 @@ function hlsl_document_parser(prompt, node = noone) {
|
|||
var lines = string_split(prompt, "\n");
|
||||
|
||||
for( var i = node.input_fix_len, n = ds_list_size(node.inputs); i < n; i += node.data_length ) {
|
||||
var _arg_name = node.inputs[| i + 0].getValue();
|
||||
var _arg_type = node.inputs[| i + 1].getValue();
|
||||
var _arg_name = node.getInputData(i + 0);
|
||||
var _arg_type = node.getInputData(i + 1);
|
||||
|
||||
if(_arg_type == 7) {
|
||||
array_push(params, [ _arg_name + "Object", "Texture2D" ]);
|
||||
|
|
|
@ -231,7 +231,7 @@ function drawWidget(xx, yy, ww, _m, jun, global_var = true, _hover = false, _foc
|
|||
}
|
||||
|
||||
var _show = jun.showValue();
|
||||
var param = new widgetParam(editBoxX, editBoxY, editBoxW, editBoxH, _show, jun.extra_data, _m, rx, ry);
|
||||
var param = new widgetParam(editBoxX, editBoxY, editBoxW, editBoxH, _show, jun.display_data, _m, rx, ry);
|
||||
|
||||
switch(jun.type) {
|
||||
case VALUE_TYPE.integer :
|
||||
|
@ -266,9 +266,9 @@ function drawWidget(xx, yy, ww, _m, jun, global_var = true, _hover = false, _foc
|
|||
#endregion
|
||||
} else if(jun.display_type == VALUE_DISPLAY.label) { #region label
|
||||
draw_set_text(f_p1, fa_left, fa_top, COLORS._main_text_sub);
|
||||
draw_text_add(xx + ui(16), _hsy, jun.display_data);
|
||||
draw_text_add(xx + ui(16), _hsy, jun.display_data.data);
|
||||
|
||||
widH = string_height(jun.display_data);
|
||||
widH = string_height(jun.display_data.data);
|
||||
#endregion
|
||||
} else
|
||||
widH = 0;
|
||||
|
|
|
@ -26,7 +26,7 @@ function Node_2D_light(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
inputs[| 3] = nodeValue("Range", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 16);
|
||||
|
||||
inputs[| 4] = nodeValue("Intensity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 5] = nodeValue("Color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
|
@ -37,25 +37,25 @@ function Node_2D_light(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
||||
inputs[| 8] = nodeValue("Sweep", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 15)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-80, 80, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-80, 80, 1] });
|
||||
|
||||
inputs[| 9] = nodeValue("Sweep end", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-80, 80, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-80, 80, 1] });
|
||||
|
||||
inputs[| 10] = nodeValue("Banding", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 16, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [0, 16, 1] });
|
||||
|
||||
inputs[| 11] = nodeValue("Attenuation", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0, "Control how light fade out over distance.")
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, ["Quadratic", "Invert quadratic", "Linear"]);
|
||||
|
||||
inputs[| 12] = nodeValue("Radial banding", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 16, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [0, 16, 1] });
|
||||
|
||||
inputs[| 13] = nodeValue("Radial start", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| 14] = nodeValue("Radial band ratio", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 15] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 15;
|
||||
|
@ -72,11 +72,11 @@ function Node_2D_light(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
attribute_surface_depth();
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) {
|
||||
var _shape = inputs[| 1].getValue();
|
||||
var _shape = getInputData(1);
|
||||
|
||||
switch(_shape) {
|
||||
case LIGHT_SHAPE_2D.point :
|
||||
var pos = inputs[| 2].getValue();
|
||||
var pos = getInputData(2);
|
||||
var px = _x + pos[0] * _s;
|
||||
var py = _y + pos[1] * _s;
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
global.SKY_SPHERE = new __3dUVSphere(0.5, 16, 8, true);
|
||||
|
||||
inputs[| in_d3d + 0] = nodeValue("FOV", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 60 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 10, 90, 1 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 10, 90, 1 ] });
|
||||
|
||||
inputs[| in_d3d + 1] = nodeValue("Clipping Distance", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 10 ] )
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -40,7 +40,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
.setDisplay(VALUE_DISPLAY.enum_button, [ "None", "CW", "CCW" ]);
|
||||
|
||||
inputs[| in_d3d + 8] = nodeValue("Orthographic Scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0.01, 4, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0.01, 4, 0.01 ] });
|
||||
|
||||
inputs[| in_d3d + 9] = nodeValue("Postioning Mode", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0 )
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, [ "Position + Rotation", "Position + Lookat", "Lookat + Rotation" ] );
|
||||
|
@ -55,7 +55,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
||||
inputs[| in_d3d + 13] = nodeValue("Vertical Angle", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 45 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 90, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [0, 90, 1] });
|
||||
|
||||
inputs[| in_d3d + 14] = nodeValue("Distance", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 4 );
|
||||
|
||||
|
@ -70,7 +70,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
inputs[| in_d3d + 19] = nodeValue("AO Bias", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.05 );
|
||||
|
||||
inputs[| in_d3d + 20] = nodeValue("AO Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1. )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0.01, 4, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0.01, 4, 0.01 ] });
|
||||
|
||||
inputs[| in_d3d + 21] = nodeValue("Round Normal", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0 );
|
||||
|
||||
|
@ -94,7 +94,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
tool_lookat = new NodeTool( "Move Target", THEME.tools_3d_transform_object );
|
||||
|
||||
static getToolSettings = function() { #region
|
||||
var _posm = inputs[| in_d3d + 9].getValue();
|
||||
var _posm = getInputData(in_d3d + 9);
|
||||
|
||||
switch(_posm) {
|
||||
case 0 : return tool_settings;
|
||||
|
@ -133,9 +133,9 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
} #endregion
|
||||
|
||||
static step = function() { #region
|
||||
var _proj = inputs[| in_d3d + 3].getValue();
|
||||
var _posm = inputs[| in_d3d + 9].getValue();
|
||||
var _ao = inputs[| in_d3d + 17].getValue();
|
||||
var _proj = getInputData(in_d3d + 3);
|
||||
var _posm = getInputData(in_d3d + 9);
|
||||
var _ao = getInputData(in_d3d + 17);
|
||||
|
||||
inputs[| in_d3d + 0].setVisible(_proj == 0);
|
||||
inputs[| in_d3d + 8].setVisible(_proj == 1);
|
||||
|
@ -340,7 +340,7 @@ function Node_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _group)
|
|||
} #endregion
|
||||
|
||||
static getPreviewObjects = function() { #region
|
||||
var _posm = inputs[| in_d3d + 9].getValue();
|
||||
var _posm = getInputData(in_d3d + 9);
|
||||
|
||||
var _scene = array_safe_get(all_inputs, in_d3d + 4, noone);
|
||||
if(is_array(_scene))
|
||||
|
|
|
@ -6,10 +6,10 @@ function Node_3D_Material(_x, _y, _group = noone) : Node_3D(_x, _y, _group) cons
|
|||
.setVisible(true, true);
|
||||
|
||||
inputs[| 1] = nodeValue("Diffuse", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 2] = nodeValue("Specular", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 3] = nodeValue("Shininess", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1 );
|
||||
|
||||
|
@ -18,10 +18,10 @@ function Node_3D_Material(_x, _y, _group = noone) : Node_3D(_x, _y, _group) cons
|
|||
inputs[| 5] = nodeValue("Normal Map", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, noone );
|
||||
|
||||
inputs[| 6] = nodeValue("Normal Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 2, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 2, 0.01 ] });
|
||||
|
||||
inputs[| 7] = nodeValue("Roughness", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
outputs[| 0] = nodeValue("Material", self, JUNCTION_CONNECT.output, VALUE_TYPE.d3Material, noone);
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ function Node_3D_Mesh_Cube(_x, _y, _group = noone) : Node_3D_Mesh(_x, _y, _group
|
|||
]
|
||||
|
||||
static step = function() { #region
|
||||
var _mat_side = inputs[| in_mesh + 0].getValue();
|
||||
var _mat_side = getInputData(in_mesh + 0);
|
||||
|
||||
inputs[| in_mesh + 1].name = _mat_side? "Material Top" : "Material";
|
||||
inputs[| in_mesh + 1].setVisible(true, true);
|
||||
|
|
|
@ -26,7 +26,7 @@ function Node_3D_Mesh_Obj(_x, _y, _group = noone) : Node_3D_Mesh(_x, _y, _group)
|
|||
object_class = __3dObject;
|
||||
|
||||
inputs[| in_mesh + 0] = nodeValue("File Path", self, JUNCTION_CONNECT.input, VALUE_TYPE.path, "" )
|
||||
.setDisplay(VALUE_DISPLAY.path_load, [ "*.obj", "" ])
|
||||
.setDisplay(VALUE_DISPLAY.path_load, { filter: "*.obj" })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| in_mesh + 1] = nodeValue("Flip UV", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true, "Flip UV axis, can be use to fix some texture mapping error.")
|
||||
|
@ -51,7 +51,7 @@ function Node_3D_Mesh_Obj(_x, _y, _group = noone) : Node_3D_Mesh(_x, _y, _group)
|
|||
insp1UpdateIcon = [ THEME.refresh, 1, COLORS._main_value_positive ];
|
||||
|
||||
static onInspector1Update = function() {
|
||||
var _path = inputs[| in_mesh + 0].getValue();
|
||||
var _path = getInputData(in_mesh + 0);
|
||||
updateObj(_path);
|
||||
}
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ function Node_3DSurf(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co
|
|||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
||||
inputs[| 2] = nodeValue("Vertical Angle", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 45 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 90, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [0, 90, 1] });
|
||||
|
||||
inputs[| 3] = nodeValue("Distance", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 4 );
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ function Node_9Slice(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co
|
|||
|
||||
static onValueFromUpdate = function(index) {
|
||||
if(index == 0) {
|
||||
var s = inputs[| 0].getValue();
|
||||
var s = getInputData(0);
|
||||
if(is_array(s)) s = s[0];
|
||||
inputs[| 1].setValue([surface_get_width_safe(s), surface_get_height_safe(s)]);
|
||||
}
|
||||
|
|
|
@ -8,8 +8,8 @@ function Node_PCX_Array_Get(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) c
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _ind = inputs[| 1].getValue();
|
||||
var _arr = getInputData(0);
|
||||
var _ind = getInputData(1);
|
||||
|
||||
outputs[| 0].setValue(new __funcTree("@", _arr, _ind));
|
||||
}
|
||||
|
|
|
@ -10,9 +10,9 @@ function Node_PCX_Array_Set(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) c
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _ind = inputs[| 1].getValue();
|
||||
var _val = inputs[| 2].getValue();
|
||||
var _arr = getInputData(0);
|
||||
var _ind = getInputData(1);
|
||||
var _val = getInputData(2);
|
||||
|
||||
outputs[| 0].setValue(new __funcTree("=", [ _arr, _ind ], _val));
|
||||
}
|
||||
|
|
|
@ -10,9 +10,9 @@ function Node_PCX_Condition(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) c
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _cond = inputs[| 0].getValue();
|
||||
var _true = inputs[| 1].getValue();
|
||||
var _fals = inputs[| 2].getValue();
|
||||
var _cond = getInputData(0);
|
||||
var _true = getInputData(1);
|
||||
var _fals = getInputData(2);
|
||||
|
||||
var _fn = new __funcIf();
|
||||
_fn.condition = _cond;
|
||||
|
|
|
@ -75,7 +75,7 @@ function Node_PCX_Equation(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) co
|
|||
array_resize(input_display_list, input_display_len);
|
||||
|
||||
for( var i = input_fix_len; i < ds_list_size(inputs); i += data_length ) {
|
||||
var varName = inputs[| i].getValue();
|
||||
var varName = getInputData(i);
|
||||
|
||||
if(varName != "") {
|
||||
ds_list_add(_in, inputs[| i + 0]);
|
||||
|
@ -103,20 +103,20 @@ function Node_PCX_Equation(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) co
|
|||
if(LOADING || APPENDING) return;
|
||||
|
||||
if(safe_mod(index - input_fix_len, data_length) == 0) //Variable name
|
||||
inputs[| index + 1].name = inputs[| index].getValue();
|
||||
inputs[| index + 1].name = getInputData(index);
|
||||
|
||||
refreshDynamicInput();
|
||||
} #endregion
|
||||
|
||||
static update = function() { #region
|
||||
var eq = inputs[| 0].getValue();
|
||||
var eq = getInputData(0);
|
||||
var fn = evaluateFunctionTree(eq);
|
||||
|
||||
var _fnL = new __funcList();
|
||||
|
||||
for( var i = input_fix_len; i < array_length(_data); i += data_length ) {
|
||||
var _pName = inputs[| i + 0].getValue();
|
||||
var _pVal = inputs[| i + 1].getValue();
|
||||
var _pName = getInputData(i + 0);
|
||||
var _pVal = getInputData(i + 1);
|
||||
|
||||
_fnL.addFunction(new __funcTree("=", _pName, _pVal));
|
||||
}
|
||||
|
@ -127,7 +127,7 @@ function Node_PCX_Equation(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) co
|
|||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) { #region
|
||||
draw_set_text(f_h5, fa_center, fa_center, COLORS._main_text);
|
||||
var str = inputs[| 0].getValue();
|
||||
var str = getInputData(0);
|
||||
|
||||
var bbox = drawGetBbox(xx, yy, _s);
|
||||
var ss = string_scale(str, bbox.w, bbox.h);
|
||||
|
|
|
@ -17,10 +17,10 @@ function Node_PCX_fn_Math(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) con
|
|||
static syms = [ "+", "-", "*", "/", "$", "%", "abs", -1, "round", "floor", "ceil",
|
||||
-1, "sin", "cos", "tan", "arcsin", "arccos", "arctan", -1, "min", "max", "clamp", -1, "lerp" ];
|
||||
|
||||
var _opr = inputs[| 0].getValue();
|
||||
var _x = inputs[| 1].getValue();
|
||||
var _y = inputs[| 2].getValue();
|
||||
var _z = inputs[| 3].getValue();
|
||||
var _opr = getInputData(0);
|
||||
var _x = getInputData(1);
|
||||
var _y = getInputData(2);
|
||||
var _z = getInputData(3);
|
||||
var _sym = syms[_opr];
|
||||
|
||||
switch(_sym) {
|
||||
|
|
|
@ -12,9 +12,9 @@ function Node_PCX_fn_Random(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) c
|
|||
input_display_list = [ 2, 0, 1 ];
|
||||
|
||||
static update = function() {
|
||||
var _min = inputs[| 0].getValue();
|
||||
var _max = inputs[| 1].getValue();
|
||||
var _int = inputs[| 2].getValue();
|
||||
var _min = getInputData(0);
|
||||
var _max = getInputData(1);
|
||||
var _int = getInputData(2);
|
||||
|
||||
outputs[| 0].setValue(new __funcTree(_int? "irandom" : "random", [ _min, _max ]));
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@ function Node_PCX_fn_Surface_Height(_x, _y, _group = noone) : Node_PCX(_x, _y, _
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _surf = inputs[| 0].getValue();
|
||||
var _surf = getInputData(0);
|
||||
outputs[| 0].setValue(new __funcTree("surface_get_height", [ _surf ]));
|
||||
}
|
||||
}
|
|
@ -6,7 +6,7 @@ function Node_PCX_fn_Surface_Width(_x, _y, _group = noone) : Node_PCX(_x, _y, _g
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _surf = inputs[| 0].getValue();
|
||||
var _surf = getInputData(0);
|
||||
outputs[| 0].setValue(new __funcTree("surface_get_width", [ _surf ]));
|
||||
}
|
||||
}
|
|
@ -7,7 +7,7 @@ function Node_PCX_fn_var(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) cons
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _def = inputs[| 0].getValue();
|
||||
var _def = getInputData(0);
|
||||
|
||||
outputs[| 0].setValue(new __funcTree("≔", display_name, _def));
|
||||
}
|
||||
|
|
|
@ -8,8 +8,8 @@ function Node_PCX_var(_x, _y, _group = noone) : Node_PCX(_x, _y, _group) constru
|
|||
outputs[| 0] = nodeValue("PCX", self, JUNCTION_CONNECT.output, VALUE_TYPE.PCXnode, noone);
|
||||
|
||||
static update = function() {
|
||||
var _name = inputs[| 0].getValue();
|
||||
var _val = inputs[| 1].getValue();
|
||||
var _name = getInputData(0);
|
||||
var _val = getInputData(1);
|
||||
|
||||
outputs[| 0].setValue(new __funcTree("=", _name, _val));
|
||||
}
|
||||
|
|
|
@ -5,9 +5,9 @@ function Node_VCT(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) const
|
|||
vct = new VCT(self);
|
||||
|
||||
inputs[| 0] = nodeValue("Editor", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.button, [ function() {
|
||||
.setDisplay(VALUE_DISPLAY.button, { name: "Editor", onClick: function() {
|
||||
vct.createDialog();
|
||||
}, "Editor" ]);
|
||||
} });
|
||||
|
||||
outputs[| 0] = nodeValue("Surface out", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
|
||||
|
||||
|
@ -26,14 +26,14 @@ function Node_VCT(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) const
|
|||
|
||||
inputs[| index] = nodeValue(name, self, JUNCTION_CONNECT.input, _var.type, 0)
|
||||
.setDisplay(_var.disp, _var.disp_data);
|
||||
inputs[| index].extra_data.key = key;
|
||||
inputs[| index].display_data.key = key;
|
||||
|
||||
array_append(input_display_list, [ index ]);
|
||||
}
|
||||
|
||||
static processData = function(_outSurf, _data, _output_index, _array_index) {
|
||||
for( var i = 1; i < array_length(_data); i++ )
|
||||
vct[$ inputs[| i].extra_data.key].setDirect(_data[i]);
|
||||
vct[$ inputs[| i].display_data.key].setDirect(_data[i]);
|
||||
|
||||
var params = {
|
||||
frame: PROJECT.animator.current_frame
|
||||
|
@ -54,6 +54,6 @@ function Node_VCT(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) const
|
|||
vct.deserialize(load_map.vct);
|
||||
|
||||
//for(var i = input_fix_len; i < array_length(_inputs); i += data_length)
|
||||
// createNewInput(_inputs[i].extra_data.key);
|
||||
// createNewInput(_inputs[i].display_data.key);
|
||||
}
|
||||
}
|
|
@ -3,10 +3,10 @@ function Node_VFX_Wind(_x, _y, _group = noone) : Node_VFX_effector(_x, _y, _grou
|
|||
node_draw_icon = s_node_vfx_wind;
|
||||
|
||||
function onAffect(part, str) {
|
||||
var _vect = current_data[4];
|
||||
var _sten = current_data[5];
|
||||
var _rot_range = current_data[6];
|
||||
var _sca_range = current_data[7];
|
||||
var _vect = getInputData(4);
|
||||
var _sten = getInputData(5);
|
||||
var _rot_range = getInputData(6);
|
||||
var _sca_range = getInputData(7);
|
||||
var _rot = random_range(_rot_range[0], _rot_range[1]);
|
||||
var _sca = [ random_range(_sca_range[0], _sca_range[1]), random_range(_sca_range[2], _sca_range[3]) ];
|
||||
|
||||
|
|
|
@ -44,21 +44,19 @@ function Node_VFX_effector(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
|
||||
outputs[| 0] = nodeValue("Particles", self, JUNCTION_CONNECT.output, VALUE_TYPE.particle, -1 );
|
||||
|
||||
current_data = [];
|
||||
|
||||
UPDATE_PART_FORWARD
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) {
|
||||
inputs[| 1].drawOverlay(active, _x, _y, _s, _mx, _my, _snx, _sny);
|
||||
|
||||
var area = inputs[| 1].getValue();
|
||||
var area = getInputData(1);
|
||||
var cx = _x + area[0] * _s;
|
||||
var cy = _y + area[1] * _s;
|
||||
var cw = area[2] * _s;
|
||||
var ch = area[3] * _s;
|
||||
var cs = area[4];
|
||||
|
||||
var fall = inputs[| 3].getValue() * _s;
|
||||
var fall = getInputData(3) * _s;
|
||||
var x0 = cx - cw + fall;
|
||||
var x1 = cx + cw - fall;
|
||||
var y0 = cy - ch + fall;
|
||||
|
@ -95,9 +93,9 @@ function Node_VFX_effector(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
function affect(part) {
|
||||
if(!part.active) return;
|
||||
|
||||
var _area = current_data[1];
|
||||
var _fall = current_data[2];
|
||||
var _fads = current_data[3];
|
||||
var _area = getInputData(1);
|
||||
var _fall = getInputData(2);
|
||||
var _fads = getInputData(3);
|
||||
|
||||
var _area_x = _area[0];
|
||||
var _area_y = _area[1];
|
||||
|
@ -142,13 +140,10 @@ function Node_VFX_effector(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var val = inputs[| 0].getValue();
|
||||
var val = getInputData(0);
|
||||
outputs[| 0].setValue(val);
|
||||
if(val == -1) return;
|
||||
|
||||
for( var i = 0; i < ds_list_size(inputs); i++ )
|
||||
current_data[i] = inputs[| i].getValue();
|
||||
|
||||
if(!is_array(val) || array_length(val) == 0) return;
|
||||
if(!is_array(val[0])) val = [ val ];
|
||||
for( var i = 0, n = array_length(val); i < n; i++ )
|
||||
|
|
|
@ -30,15 +30,15 @@ function Node_VFX_Override(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
outputs[| 0] = nodeValue("Particles", self, JUNCTION_CONNECT.output, VALUE_TYPE.particle, -1 );
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var parts = inputs[| 0].getValue();
|
||||
var parts = getInputData(0);
|
||||
if(!is_array(parts)) return;
|
||||
|
||||
var _pos = inputs[| 1].getValue();
|
||||
var _sca = inputs[| 2].getValue();
|
||||
var _rot = inputs[| 3].getValue();
|
||||
var _col = inputs[| 4].getValue();
|
||||
var _alp = inputs[| 5].getValue();
|
||||
var _srf = inputs[| 6].getValue();
|
||||
var _pos = getInputData(1);
|
||||
var _sca = getInputData(2);
|
||||
var _rot = getInputData(3);
|
||||
var _col = getInputData(4);
|
||||
var _alp = getInputData(5);
|
||||
var _srf = getInputData(6);
|
||||
|
||||
for( var i = 0, n = array_length(parts); i < n; i++ ) {
|
||||
var part = parts[i];
|
||||
|
|
|
@ -60,7 +60,7 @@ function Node_VFX_Renderer(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
}
|
||||
|
||||
static step = function() {
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var _outSurf = outputs[| 0].getValue();
|
||||
|
||||
_outSurf = surface_verify(_outSurf, _dim[0], _dim[1], attrDepth());
|
||||
|
|
|
@ -48,8 +48,6 @@ function Node_VFX_Spawner(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y
|
|||
if(ds_list_empty(vt.value_to)) return;
|
||||
|
||||
var pv = part.getPivot();
|
||||
for( var i = 0; i < ds_list_size(inputs); i++ )
|
||||
current_data[i] = inputs[| i].getValue();
|
||||
|
||||
for( var i = 0; i < ds_list_size(vt.value_to); i++ ) {
|
||||
var _n = vt.value_to[| i];
|
||||
|
@ -63,8 +61,6 @@ function Node_VFX_Spawner(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y
|
|||
if(ds_list_empty(vt.value_to)) return;
|
||||
|
||||
var pv = part.getPivot();
|
||||
for( var i = 0; i < ds_list_size(inputs); i++ )
|
||||
current_data[i] = inputs[| i].getValue();
|
||||
|
||||
for( var i = 0; i < ds_list_size(vt.value_to); i++ ) {
|
||||
var _n = vt.value_to[| i];
|
||||
|
@ -78,8 +74,6 @@ function Node_VFX_Spawner(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y
|
|||
if(ds_list_empty(vt.value_to)) return;
|
||||
|
||||
var pv = part.getPivot();
|
||||
for( var i = 0; i < ds_list_size(inputs); i++ )
|
||||
current_data[i] = inputs[| i].getValue();
|
||||
|
||||
for( var i = 0; i < ds_list_size(vt.value_to); i++ ) {
|
||||
var _n = vt.value_to[| i];
|
||||
|
@ -89,7 +83,7 @@ function Node_VFX_Spawner(_x, _y, _group = noone) : Node_VFX_Spawner_Base(_x, _y
|
|||
} #endregion
|
||||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) { #region
|
||||
var spr = inputs[| 0].getValue();
|
||||
var spr = getInputData(0);
|
||||
|
||||
if(spr == 0) {
|
||||
if(!is_surface(def_surface))
|
||||
|
|
|
@ -45,7 +45,7 @@ function Node_VFX_Variable(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
.setVisible(false);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var parts = inputs[| 0].getValue();
|
||||
var parts = getInputData(0);
|
||||
if(!is_array(parts)) return;
|
||||
|
||||
var _val = [];
|
||||
|
|
|
@ -4,12 +4,12 @@ function Node_Alpha_Cutoff(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 1] = nodeValue("Minimum", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.2, "Any pixel with less alpha (more transparent) than this will be removed.")
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 2] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 3] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 4] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 4;
|
||||
|
|
|
@ -7,7 +7,7 @@ function Node_Anim_Curve(_x, _y, _group = noone) : Node_Processor(_x, _y, _group
|
|||
|
||||
inputs[| 0] = nodeValue("Curve", self, JUNCTION_CONNECT.input, VALUE_TYPE.curve, CURVE_DEF_01);
|
||||
inputs[| 1] = nodeValue("Progress", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 2] = nodeValue("Minimum", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0);
|
||||
inputs[| 3] = nodeValue("Maximum", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1);
|
||||
|
|
|
@ -20,25 +20,25 @@ function Node_Animation_Control(_x, _y, _group = noone) : Node(_x, _y, _group) c
|
|||
inputs[| 6] = nodeValue("Skip Frames Count", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 1);
|
||||
|
||||
static step = function() {
|
||||
if(inputs[| 0].getValue())
|
||||
if(getInputData(0))
|
||||
PROJECT.animator.toggle();
|
||||
|
||||
if(inputs[| 1].getValue())
|
||||
if(getInputData(1))
|
||||
PROJECT.animator.pause();
|
||||
|
||||
if(inputs[| 2].getValue())
|
||||
if(getInputData(2))
|
||||
PROJECT.animator.resume();
|
||||
|
||||
if(inputs[| 3].getValue()) {
|
||||
if(getInputData(3)) {
|
||||
PROJECT.animator.stop();
|
||||
PROJECT.animator.play();
|
||||
}
|
||||
|
||||
if(inputs[| 4].getValue())
|
||||
if(getInputData(4))
|
||||
PROJECT.animator.render();
|
||||
|
||||
if(inputs[| 5].getValue()) {
|
||||
var fr = inputs[| 6].getValue();
|
||||
if(getInputData(5)) {
|
||||
var fr = getInputData(6);
|
||||
PROJECT.animator.setFrame(PROJECT.animator.current_frame + fr);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
||||
inputs[| 4] = nodeValue("Bone scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0.1, 2, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0.1, 2, 0.01 ] });
|
||||
|
||||
outputs[| 0] = nodeValue("Surface out", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
|
||||
|
||||
|
@ -64,7 +64,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
for(var i = input_fix_len; i < amo; i += data_length) {
|
||||
index++;
|
||||
var _surf = current_data[i];
|
||||
var _id = inputs[| i].extra_data.bone_id;
|
||||
var _id = inputs[| i].display_data.bone_id;
|
||||
if(_id == "") continue;
|
||||
|
||||
if(ds_map_exists(surfMap, _id))
|
||||
|
@ -142,7 +142,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
TOOLTIP = [ _surf, VALUE_TYPE.surface ];
|
||||
if(mouse_press(mb_left, _focus)) {
|
||||
layer_dragging = _sid;
|
||||
inputs[| input_fix_len + _sid * data_length].extra_data.bone_id = "";
|
||||
inputs[| input_fix_len + _sid * data_length].display_data.bone_id = "";
|
||||
}
|
||||
|
||||
draw_set_color(COLORS._main_accent);
|
||||
|
@ -173,7 +173,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
|
||||
if(layer_dragging != noone && hovering && mouse_release(mb_left)) {
|
||||
var _lind = input_fix_len + layer_dragging * data_length;
|
||||
inputs[| _lind].extra_data.bone_id = hovering.ID;
|
||||
inputs[| _lind].display_data.bone_id = hovering.ID;
|
||||
|
||||
layer_dragging = noone;
|
||||
triggerRender();
|
||||
|
@ -302,7 +302,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
}
|
||||
}
|
||||
|
||||
var binded = inputs[| _inp].extra_data.bone_id != "";
|
||||
var binded = inputs[| _inp].display_data.bone_id != "";
|
||||
|
||||
if(layer_dragging == noone || layer_dragging == index) {
|
||||
var _bx = _x + 24;
|
||||
|
@ -390,7 +390,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
inputs[| index + 0] = nodeValue("Surface", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
inputs[| index + 0].surface_index = index;
|
||||
inputs[| index + 0].hover_effect = 0;
|
||||
inputs[| index + 0].extra_data.bone_id = "";
|
||||
inputs[| index + 0].display_data.bone_id = "";
|
||||
|
||||
inputs[| index + 1] = nodeValue("Transform", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0, 0, 1, 1 ] )
|
||||
.setDisplay(VALUE_DISPLAY.transform);
|
||||
|
@ -469,7 +469,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
static setBone = function() { #region
|
||||
ds_map_clear(boneMap);
|
||||
|
||||
var _b = inputs[| 1].getValue();
|
||||
var _b = getInputData(1);
|
||||
bone = _b;
|
||||
if(bone == noone) return;
|
||||
|
||||
|
@ -490,11 +490,11 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
} #endregion
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
|
||||
var dim = inputs[| 0].getValue();
|
||||
var _bind = inputs[| 2].getValue();
|
||||
var dim = getInputData(0);
|
||||
var _bind = getInputData(2);
|
||||
|
||||
var _dpos = inputs[| 3].getValue();
|
||||
var _dsca = inputs[| 4].getValue();
|
||||
var _dpos = getInputData(3);
|
||||
var _dsca = getInputData(4);
|
||||
|
||||
if(bone == noone) return;
|
||||
|
||||
|
@ -529,7 +529,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
|
||||
_tran = array_clone(_tran);
|
||||
|
||||
var _bone = inputs[| surf_dragging].extra_data.bone_id;
|
||||
var _bone = inputs[| surf_dragging].display_data.bone_id;
|
||||
_bone = boneMap[? _bone];
|
||||
|
||||
if(drag_type == NODE_COMPOSE_DRAG.move) {
|
||||
|
@ -599,7 +599,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
var _surf = array_safe_get(current_data, index);
|
||||
if(!_surf || is_array(_surf)) continue;
|
||||
|
||||
var _bone = inputs[| index].extra_data.bone_id;
|
||||
var _bone = inputs[| index].display_data.bone_id;
|
||||
if(!ds_map_exists(boneMap, _bone)) {
|
||||
//print($"Bone not found {_bone}");
|
||||
continue;
|
||||
|
@ -664,7 +664,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
var _surf = array_safe_get(current_data, index);
|
||||
if(!_surf || is_array(_surf)) continue;
|
||||
|
||||
var _bone = inputs[| index].extra_data.bone_id;
|
||||
var _bone = inputs[| index].display_data.bone_id;
|
||||
if(!ds_map_exists(boneMap, _bone))
|
||||
continue;
|
||||
|
||||
|
@ -812,7 +812,7 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
var _s = use_data? _bind[i].surface.get() : _data[datInd];
|
||||
if(!is_surface(_s)) continue;
|
||||
|
||||
var _b = use_data? _bind[i].bone : inputs[| datInd].extra_data.bone_id;
|
||||
var _b = use_data? _bind[i].bone : inputs[| datInd].display_data.bone_id;
|
||||
|
||||
if(!ds_map_exists(boneMap, _b)) {
|
||||
//print($"Bone not exist {_bone} from map {ds_map_size(boneMap)}")
|
||||
|
@ -874,14 +874,14 @@ function Node_Armature_Bind(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
} #endregion
|
||||
|
||||
static resetTransform = function(surfIndex) { #region
|
||||
var _bind = inputs[| 2].getValue();
|
||||
var _bind = getInputData(2);
|
||||
var use_data = _bind != noone;
|
||||
|
||||
var _surf = inputs[| surfIndex + 0].getValue();
|
||||
var _tran = inputs[| surfIndex + 1].getValue();
|
||||
var _arot = inputs[| surfIndex + 2].getValue();
|
||||
var _surf = getInputData(surfIndex + 0);
|
||||
var _tran = getInputData(surfIndex + 1);
|
||||
var _arot = getInputData(surfIndex + 2);
|
||||
|
||||
var _b = use_data? _bind[i].bone : inputs[| surfIndex].extra_data.bone_id;
|
||||
var _b = use_data? _bind[i].bone : inputs[| surfIndex].display_data.bone_id;
|
||||
if(!ds_map_exists(boneMap, _b)) return;
|
||||
|
||||
_b = boneMap[? _b];
|
||||
|
|
|
@ -36,7 +36,7 @@ function Node_Armature_Pose(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
|
||||
inputs[| index] = nodeValue(bone != noone? bone.name : "bone", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0, 0, 0, 1 ] )
|
||||
.setDisplay(VALUE_DISPLAY.transform);
|
||||
inputs[| index].extra_data.bone_id = bone != noone? bone.ID : noone;
|
||||
inputs[| index].display_data.bone_id = bone != noone? bone.ID : noone;
|
||||
|
||||
if(bone != noone)
|
||||
boneMap[? bone.ID] = inputs[| index];
|
||||
|
@ -48,7 +48,7 @@ function Node_Armature_Pose(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
|
||||
static setBone = function() { #region
|
||||
//print("Setting dem bones...");
|
||||
var _b = inputs[| 0].getValue();
|
||||
var _b = getInputData(0);
|
||||
if(_b == noone) return;
|
||||
|
||||
var _bones = [];
|
||||
|
@ -224,7 +224,7 @@ function Node_Armature_Pose(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
|
||||
bone_prev = noone;
|
||||
static step = function() { #region
|
||||
var _b = inputs[| 0].getValue();
|
||||
var _b = getInputData(0);
|
||||
if(_b == noone) return;
|
||||
if(bone_prev != _b) {
|
||||
setBone();
|
||||
|
@ -237,7 +237,7 @@ function Node_Armature_Pose(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
} #endregion
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) { #region
|
||||
var _b = inputs[| 0].getValue();
|
||||
var _b = getInputData(0);
|
||||
if(_b == noone) return;
|
||||
|
||||
var _bone_pose = _b.clone();
|
||||
|
@ -310,7 +310,7 @@ function Node_Armature_Pose(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
static doApplyDeserialize = function() { #region
|
||||
for( var i = input_fix_len; i < ds_list_size(inputs); i += data_length ) {
|
||||
var inp = inputs[| i];
|
||||
var idx = struct_try_get(inp.extra_data, "bone_id");
|
||||
var idx = struct_try_get(inp.display_data, "bone_id");
|
||||
|
||||
boneMap[? idx] = inp;
|
||||
}
|
||||
|
|
|
@ -12,7 +12,7 @@ function Node_Armature_Sample(_x, _y, _group = noone) : Node(_x, _y, _group) con
|
|||
inputs[| 1] = nodeValue("Bone name", self, JUNCTION_CONNECT.input, VALUE_TYPE.text, "");
|
||||
|
||||
inputs[| 2] = nodeValue("Sample point", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
outputs[| 0] = nodeValue("Position", self, JUNCTION_CONNECT.output, VALUE_TYPE.integer, [ 0, 0 ])
|
||||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
@ -33,16 +33,16 @@ function Node_Armature_Sample(_x, _y, _group = noone) : Node(_x, _y, _group) con
|
|||
#endregion
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
|
||||
var _b = inputs[| 0].getValue();
|
||||
var _b = getInputData(0);
|
||||
|
||||
if(_b == noone) return;
|
||||
_b.draw(attributes, false, _x, _y, _s, _mx, _my);
|
||||
} #endregion
|
||||
|
||||
static update = function() { #region
|
||||
var _bone = inputs[| 0].getValue();
|
||||
var _name = inputs[| 1].getValue();
|
||||
var _prog = inputs[| 2].getValue();
|
||||
var _bone = getInputData(0);
|
||||
var _name = getInputData(1);
|
||||
var _prog = getInputData(2);
|
||||
|
||||
if(_bone == noone) return;
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ function Node_Armature_Path(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
#endregion
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
|
||||
var _b = inputs[| 0].getValue();
|
||||
var _b = getInputData(0);
|
||||
|
||||
if(_b == noone) return;
|
||||
_b.draw(attributes, false, _x, _y, _s, _mx, _my);
|
||||
|
@ -77,7 +77,7 @@ function Node_Armature_Path(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
} #endregion
|
||||
|
||||
static update = function() { #region
|
||||
var _bone = inputs[| 0].getValue();
|
||||
var _bone = getInputData(0);
|
||||
if(_bone == noone) return;
|
||||
|
||||
lines = [];
|
||||
|
|
|
@ -5,7 +5,7 @@ function Node_Array(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
|
|||
w = 96;
|
||||
|
||||
inputs[| 0] = nodeValue("Type", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0 )
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, [ "Any", "Surface", "Number", "Color", "Text" ], { update_hover: false })
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, { data: [ "Any", "Surface", "Number", "Color", "Text" ], update_hover: false })
|
||||
.rejectArray();
|
||||
|
||||
inputs[| 1] = nodeValue("Spread array", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false )
|
||||
|
@ -66,7 +66,7 @@ function Node_Array(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
|
|||
attributes.spread_value = false;
|
||||
|
||||
static getType = function() {
|
||||
var _type = inputs[| 0].getValue();
|
||||
var _type = getInputData(0);
|
||||
|
||||
switch(_type) {
|
||||
case 1 : return VALUE_TYPE.surface;
|
||||
|
@ -152,10 +152,10 @@ function Node_Array(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
|
|||
outputs[| 0].type = _typ;
|
||||
var res = [];
|
||||
var ind = 0;
|
||||
var spd = inputs[| 1].getValue();
|
||||
var spd = getInputData(1);
|
||||
|
||||
for( var i = input_fix_len; i < ds_list_size(inputs) - 1; i++ ) {
|
||||
var val = inputs[| i].getValue();
|
||||
var val = getInputData(i);
|
||||
|
||||
if(is_array(val) && spd)
|
||||
array_append(res, val);
|
||||
|
|
|
@ -52,7 +52,7 @@ function Node_Array_Add(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
if(inputs[| 0].value_from == noone) {
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
|
@ -62,14 +62,14 @@ function Node_Array_Add(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
|
||||
if(!is_array(_arr)) return;
|
||||
var _type = inputs[| 0].value_from.type;
|
||||
var spd = inputs[| 1].getValue();
|
||||
var spd = getInputData(1);
|
||||
|
||||
inputs[| 0].type = _type;
|
||||
outputs[| 0].type = _type;
|
||||
|
||||
var _out = array_clone(_arr);
|
||||
for( var i = input_fix_len; i < ds_list_size(inputs) - 1; i += data_length ) {
|
||||
var _val = inputs[| i].getValue();
|
||||
var _val = getInputData(i);
|
||||
inputs[| i].type = _type;
|
||||
|
||||
if(is_array(_val) && spd)
|
||||
|
|
|
@ -26,9 +26,9 @@ function Node_Array_Copy(_x, _y, _group = noone) : Node(_x, _y, _group) construc
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _ind = inputs[| 1].getValue();
|
||||
var _siz = inputs[| 2].getValue();
|
||||
var _arr = getInputData(0);
|
||||
var _ind = getInputData(1);
|
||||
var _siz = getInputData(2);
|
||||
|
||||
if(!is_array(_arr)) return;
|
||||
var res = [];
|
||||
|
|
|
@ -15,8 +15,8 @@ function Node_Array_CSV_Parse(_x, _y, _group = noone) : Node(_x, _y, _group) con
|
|||
.setArrayDepth(1);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _str = inputs[| 0].getValue();
|
||||
var _skp = inputs[| 1].getValue();
|
||||
var _str = getInputData(0);
|
||||
var _skp = getInputData(1);
|
||||
|
||||
var _lines = string_splice(_str, "\n");
|
||||
var _arr = [];
|
||||
|
|
|
@ -16,14 +16,14 @@ function Node_Array_Find(_x, _y, _group = noone) : Node(_x, _y, _group) construc
|
|||
outputs[| 0] = nodeValue("Index", self, JUNCTION_CONNECT.output, VALUE_TYPE.integer, 0);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
inputs[| 1].type = VALUE_TYPE.any;
|
||||
|
||||
if(!is_array(_arr)) return;
|
||||
|
||||
var value = inputs[| 1].getValue();
|
||||
var value = getInputData(1);
|
||||
|
||||
if(inputs[| 0].value_from != noone) {
|
||||
var type = inputs[| 0].value_from.type;
|
||||
|
|
|
@ -55,12 +55,12 @@ function Node_Array_Get(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
if(!is_array(_arr)) return;
|
||||
|
||||
var index = inputs[| 1].getValue();
|
||||
var _ovf = inputs[| 2].getValue();
|
||||
var index = getInputData(1);
|
||||
var _ovf = getInputData(2);
|
||||
var res = is_array(index)? array_create(array_length(index)) : 0;
|
||||
|
||||
if(is_array(index)) {
|
||||
|
@ -74,7 +74,7 @@ function Node_Array_Get(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) {
|
||||
draw_set_text(f_h3, fa_center, fa_center, COLORS._main_text);
|
||||
var idx = inputs[| 1].getValue();
|
||||
var idx = getInputData(1);
|
||||
|
||||
var str = string(idx);
|
||||
var bbox = drawGetBbox(xx, yy, _s);
|
||||
|
|
|
@ -20,7 +20,7 @@ function Node_Array_Insert(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
outputs[| 0] = nodeValue("Array", self, JUNCTION_CONNECT.output, VALUE_TYPE.any, 0);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
inputs[| 2].type = VALUE_TYPE.any;
|
||||
|
@ -28,9 +28,9 @@ function Node_Array_Insert(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
|
||||
if(!is_array(_arr)) return;
|
||||
|
||||
var index = inputs[| 1].getValue();
|
||||
var value = inputs[| 2].getValue();
|
||||
var spred = inputs[| 3].getValue();
|
||||
var index = getInputData(1);
|
||||
var value = getInputData(2);
|
||||
var spred = getInputData(3);
|
||||
var _len = array_length(_arr);
|
||||
|
||||
if(inputs[| 0].value_from != noone) {
|
||||
|
@ -63,7 +63,7 @@ function Node_Array_Insert(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) {
|
||||
draw_set_text(f_h3, fa_center, fa_center, COLORS._main_text);
|
||||
var idx = inputs[| 1].getValue();
|
||||
var idx = getInputData(1);
|
||||
|
||||
var str = string(idx);
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ function Node_Array_Length(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
outputs[| 0] = nodeValue("Size", self, JUNCTION_CONNECT.output, VALUE_TYPE.integer, 0);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
inputs[| 0].type = inputs[| 0].value_from == noone? VALUE_TYPE.any : inputs[| 0].value_from.type;
|
||||
|
||||
if(!is_array(_arr) || array_length(_arr) == 0) {
|
||||
|
|
|
@ -16,9 +16,9 @@ function Node_Array_Range(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
outputs[| 0] = nodeValue("Array", self, JUNCTION_CONNECT.output, VALUE_TYPE.float, []);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var st = inputs[| 0].getValue();
|
||||
var ed = inputs[| 1].getValue();
|
||||
var step = inputs[| 2].getValue();
|
||||
var st = getInputData(0);
|
||||
var ed = getInputData(1);
|
||||
var step = getInputData(2);
|
||||
var arr = [];
|
||||
|
||||
if((step > 0 && st <= ed) || (step < 0 && st >= ed)) {
|
||||
|
@ -31,9 +31,9 @@ function Node_Array_Range(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) {
|
||||
draw_set_text(f_p0, fa_center, fa_center, COLORS._main_text);
|
||||
var str = inputs[| 0].getValue();
|
||||
var edd = inputs[| 1].getValue();
|
||||
var stp = inputs[| 2].getValue();
|
||||
var str = getInputData(0);
|
||||
var edd = getInputData(1);
|
||||
var stp = getInputData(2);
|
||||
|
||||
var str = "[" + string(str) + ", " + string(str + stp) + ", ... ," + string(edd) + "]";
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ function Node_Array_Remove(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
outputs[| 0] = nodeValue("Array", self, JUNCTION_CONNECT.output, VALUE_TYPE.any, 0);
|
||||
|
||||
static step = function() {
|
||||
var type = inputs[| 1].getValue();
|
||||
var type = getInputData(1);
|
||||
|
||||
inputs[| 2].setVisible(type == 0, type == 0);
|
||||
inputs[| 3].setVisible(type == 1, type == 1);
|
||||
|
@ -43,13 +43,13 @@ function Node_Array_Remove(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
if(!is_array(_arr)) return;
|
||||
|
||||
var type = inputs[| 1].getValue();
|
||||
var index = inputs[| 2].getValue();
|
||||
var value = inputs[| 3].getValue();
|
||||
var spred = inputs[| 4].getValue();
|
||||
var type = getInputData(1);
|
||||
var index = getInputData(2);
|
||||
var value = getInputData(3);
|
||||
var spred = getInputData(4);
|
||||
|
||||
_arr = array_clone(_arr);
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ function Node_Array_Reverse(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
outputs[| 0] = nodeValue("Array", self, JUNCTION_CONNECT.output, VALUE_TYPE.any, 0);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
outputs[| 0].type = VALUE_TYPE.any;
|
||||
|
|
|
@ -17,7 +17,7 @@ function Node_Array_Set(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
outputs[| 0] = nodeValue("Array", self, JUNCTION_CONNECT.output, VALUE_TYPE.any, 0);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
inputs[| 2].type = VALUE_TYPE.any;
|
||||
|
@ -25,8 +25,8 @@ function Node_Array_Set(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
|
||||
if(!is_array(_arr)) return;
|
||||
|
||||
var index = inputs[| 1].getValue();
|
||||
var value = inputs[| 2].getValue();
|
||||
var index = getInputData(1);
|
||||
var value = getInputData(2);
|
||||
var _len = array_length(_arr);
|
||||
|
||||
if(inputs[| 0].value_from != noone) {
|
||||
|
@ -53,7 +53,7 @@ function Node_Array_Set(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) {
|
||||
draw_set_text(f_h3, fa_center, fa_center, COLORS._main_text);
|
||||
var idx = inputs[| 1].getValue();
|
||||
var idx = getInputData(1);
|
||||
var str = string(idx);
|
||||
var bbox = drawGetBbox(xx, yy, _s);
|
||||
var ss = string_scale(str, bbox.w, bbox.h);
|
||||
|
|
|
@ -14,8 +14,8 @@ function Node_Array_Shift(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
outputs[| 0] = nodeValue("Array", self, JUNCTION_CONNECT.output, VALUE_TYPE.any, 0);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _shf = inputs[| 1].getValue();
|
||||
var _arr = getInputData(0);
|
||||
var _shf = getInputData(1);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
outputs[| 0].type = VALUE_TYPE.any;
|
||||
|
|
|
@ -13,8 +13,8 @@ function Node_Array_Shuffle(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
outputs[| 0] = nodeValue("Shuffled array", self, JUNCTION_CONNECT.output, VALUE_TYPE.any, []);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var arr = inputs[| 0].getValue();
|
||||
var sed = inputs[| 1].getValue();
|
||||
var arr = getInputData(0);
|
||||
var sed = getInputData(1);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
outputs[| 0].type = VALUE_TYPE.any;
|
||||
|
|
|
@ -19,8 +19,8 @@ function Node_Array_Sort(_x, _y, _group = noone) : Node(_x, _y, _group) construc
|
|||
static sortDes = function(v1, v2) { return v1[1] > v2[1]; }
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var arr = inputs[| 0].getValue();
|
||||
var asc = inputs[| 1].getValue();
|
||||
var arr = getInputData(0);
|
||||
var asc = getInputData(1);
|
||||
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
outputs[| 0].type = VALUE_TYPE.any;
|
||||
|
|
|
@ -49,7 +49,7 @@ function Node_Array_Zip(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
if(inputs[| 0].value_from == noone) {
|
||||
inputs[| 0].type = VALUE_TYPE.any;
|
||||
|
@ -65,7 +65,7 @@ function Node_Array_Zip(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
var len = 1;
|
||||
var val = [];
|
||||
for( var i = 0; i < ds_list_size(inputs) - 1; i += data_length ) {
|
||||
val[i] = inputs[| i].getValue();
|
||||
val[i] = getInputData(i);
|
||||
inputs[| i].type = inputs[| i].value_from == noone? inputs[| i].value_from.type : VALUE_TYPE.any;
|
||||
if(!is_array(val[i])) {
|
||||
val[i] = [ val[i] ];
|
||||
|
|
|
@ -30,10 +30,10 @@ function Node_ASE_File_Read(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
w = 128;
|
||||
|
||||
inputs[| 0] = nodeValue("Path", self, JUNCTION_CONNECT.input, VALUE_TYPE.path, "")
|
||||
.setDisplay(VALUE_DISPLAY.path_load, ["*.ase, *.aseprite", ""]);
|
||||
.setDisplay(VALUE_DISPLAY.path_load, { filter: "*.ase, *.aseprite" });
|
||||
|
||||
inputs[| 1] = nodeValue("Generate layers", self, JUNCTION_CONNECT.input, VALUE_TYPE.trigger, 0)
|
||||
.setDisplay(VALUE_DISPLAY.button, [ function() { refreshLayers(); }, "Generate"] );
|
||||
.setDisplay(VALUE_DISPLAY.button, { name: "Generate", onClick: function() { refreshLayers(); } });
|
||||
|
||||
inputs[| 2] = nodeValue("Current tag", self, JUNCTION_CONNECT.input, VALUE_TYPE.text, "");
|
||||
|
||||
|
@ -88,7 +88,7 @@ function Node_ASE_File_Read(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
});
|
||||
|
||||
tag_renderer = new Inspector_Custom_Renderer(function(_x, _y, _w, _m, _hover, _focus) {
|
||||
var current_tag = inputs[| 2].getValue();
|
||||
var current_tag = getInputData(2);
|
||||
var amo = array_length(tags);
|
||||
var abx = ui(24);
|
||||
var lb_h = line_get_height(f_p0);
|
||||
|
@ -138,7 +138,7 @@ function Node_ASE_File_Read(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
if(_hover && point_in_rectangle(_m[0], _m[1], _x + 8, _yy, _x + _w - 8, _yy + hh)) {
|
||||
draw_sprite_stretched_ext(THEME.node_bg_name, 1, _x + 8, _yy, _w - 16, hh, c_white, 0.1);
|
||||
if(mouse_click(mb_left, _focus)) {
|
||||
var _currTag = inputs[| 2].getValue();
|
||||
var _currTag = getInputData(2);
|
||||
var _tagName = tag[? "Name"];
|
||||
inputs[| 2].setValue(_currTag == _tagName? "" : _tagName);
|
||||
}
|
||||
|
@ -185,7 +185,7 @@ function Node_ASE_File_Read(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
var nh = (array_length(layers) - 1) / 2 * _nh;
|
||||
var ny = y - nh;
|
||||
|
||||
var use_cel = inputs[| 3].getValue();
|
||||
var use_cel = getInputData(3);
|
||||
|
||||
var lvs = [];
|
||||
for( var i = 0, n = array_length(layers); i < n; i++ ) {
|
||||
|
@ -287,7 +287,7 @@ function Node_ASE_File_Read(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
insp1UpdateIcon = [ THEME.refresh, 1, COLORS._main_value_positive ];
|
||||
|
||||
static onInspector1Update = function() {
|
||||
var path = inputs[| 0].getValue();
|
||||
var path = getInputData(0);
|
||||
if(path == "") return;
|
||||
updatePaths(path);
|
||||
update();
|
||||
|
@ -300,8 +300,8 @@ function Node_ASE_File_Read(_x, _y, _group = noone) : Node(_x, _y, _group) const
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var path = inputs[| 0].getValue();
|
||||
var current_tag = inputs[| 2].getValue();
|
||||
var path = getInputData(0);
|
||||
var current_tag = getInputData(2);
|
||||
if(path_current != path) updatePaths(path);
|
||||
if(ds_map_empty(content)) return;
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ function Node_ASE_layer(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
}
|
||||
|
||||
static findLayer = function() {
|
||||
var data = inputs[| 0].getValue();
|
||||
var data = getInputData(0);
|
||||
if(data == noone) return;
|
||||
|
||||
var layer_index = 0;
|
||||
|
@ -35,7 +35,7 @@ function Node_ASE_layer(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var data = inputs[| 0].getValue();
|
||||
var data = getInputData(0);
|
||||
if(data == noone) return;
|
||||
|
||||
if(_name != display_name) {
|
||||
|
@ -46,7 +46,7 @@ function Node_ASE_layer(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
if(layer_object == noone) return;
|
||||
var cel = layer_object.getCel(PROJECT.animator.current_frame - data._tag_delay);
|
||||
|
||||
var celDim = inputs[| 1].getValue();
|
||||
var celDim = getInputData(1);
|
||||
var ww = data.content[? "Width"];
|
||||
var hh = data.content[? "Height"];
|
||||
var cw = cel? cel.data[? "Width"] : 1;
|
||||
|
|
|
@ -13,8 +13,8 @@ function Node_Atlas_Draw(_x, _y, _group = noone) : Node(_x, _y, _group) construc
|
|||
attribute_interpolation(true);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var dim = inputs[| 0].getValue();
|
||||
var atl = inputs[| 1].getValue();
|
||||
var dim = getInputData(0);
|
||||
var atl = getInputData(1);
|
||||
|
||||
if(atl == noone) return;
|
||||
if(is_array(atl) && array_length(atl) == 0) return;
|
||||
|
|
|
@ -26,7 +26,7 @@ function Node_Atlas_Get(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
.setArrayDepth(1);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var atl = inputs[| 0].getValue();
|
||||
var atl = getInputData(0);
|
||||
|
||||
if(atl == noone) return;
|
||||
if(is_array(atl) && array_length(atl) == 0) return;
|
||||
|
|
|
@ -28,7 +28,7 @@ function Node_Atlas_Set(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
outputs[| 0] = nodeValue("Atlas", self, JUNCTION_CONNECT.output, VALUE_TYPE.atlas, noone);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var atl = inputs[| 0].getValue();
|
||||
var atl = getInputData(0);
|
||||
|
||||
if(atl == noone) return;
|
||||
if(is_array(atl) && array_length(atl) == 0) return;
|
||||
|
@ -36,12 +36,12 @@ function Node_Atlas_Set(_x, _y, _group = noone) : Node(_x, _y, _group) construct
|
|||
if(!is_array(atl))
|
||||
atl = [ atl ];
|
||||
|
||||
var surf = inputs[| 1].getValue();
|
||||
var posi = inputs[| 2].getValue();
|
||||
var rota = inputs[| 3].getValue();
|
||||
var scal = inputs[| 4].getValue();
|
||||
var blns = inputs[| 5].getValue();
|
||||
var alph = inputs[| 6].getValue();
|
||||
var surf = getInputData(1);
|
||||
var posi = getInputData(2);
|
||||
var rota = getInputData(3);
|
||||
var scal = getInputData(4);
|
||||
var blns = getInputData(5);
|
||||
var alph = getInputData(6);
|
||||
|
||||
var use = [ 0 ];
|
||||
for( var i = 1; i < 7; i++ ) use[i] = inputs[| i].value_from != noone;
|
||||
|
|
|
@ -18,13 +18,13 @@ function Node_Audio_Window(_x, _y, _group = noone) : Node(_x, _y, _group) constr
|
|||
.setArrayDepth(1);
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _arr = inputs[| 0].getValue();
|
||||
var _arr = getInputData(0);
|
||||
|
||||
if(!is_array(_arr) || array_length(_arr) < 1) return;
|
||||
if(!is_array(_arr[0])) return;
|
||||
|
||||
var sam = inputs[| 1].getValue();
|
||||
var siz = inputs[| 2].getValue();
|
||||
var sam = getInputData(1);
|
||||
var siz = getInputData(2);
|
||||
var res = [];
|
||||
var off = frame / PROJECT.animator.framerate * sam;
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ function Node_Average(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
inputs[| 1] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 2] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 3] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 3;
|
||||
|
|
|
@ -24,7 +24,7 @@ function Node_Bevel(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con
|
|||
inputs[| 5] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 6] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 7] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 7;
|
||||
|
|
|
@ -13,7 +13,7 @@ function Node_Blend(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con
|
|||
.setDisplay(VALUE_DISPLAY.enum_scroll, BLEND_TYPES );
|
||||
|
||||
inputs[| 3] = nodeValue("Opacity", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 4] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ function Node_Blinker(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
inputs[| 2] = nodeValue("Seed", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, irandom_range( 100000, 999999 ))
|
||||
|
||||
inputs[| 3] = nodeValue("Amount", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 4] = nodeValue("Target Colors", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, DEF_PALETTE )
|
||||
.setDisplay(VALUE_DISPLAY.palette);
|
||||
|
|
|
@ -10,20 +10,20 @@ function Node_Bloom(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con
|
|||
|
||||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
inputs[| 1] = nodeValue("Size", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 3, "Bloom blur radius.")
|
||||
.setDisplay(VALUE_DISPLAY.slider, [1, 32, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 1] });
|
||||
|
||||
inputs[| 2] = nodeValue("Tolerance", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5, "How bright a pixel should be to start blooming.")
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 3] = nodeValue("Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, .25, "Blend intensity.")
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 2, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 2, 0.01] });
|
||||
|
||||
inputs[| 4] = nodeValue("Bloom mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 5] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 6] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 7] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 7;
|
||||
|
|
|
@ -3,7 +3,7 @@ function Node_Blur(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons
|
|||
|
||||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
inputs[| 1] = nodeValue("Size", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 3)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [1, 32, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 1] });
|
||||
|
||||
inputs[| 2] = nodeValue("Oversample mode", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0, "How to deal with pixel outside the surface.\n - Empty: Use empty pixel\n - Clamp: Repeat edge pixel\n - Repeat: Repeat texture.")
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, [ "Empty", "Clamp", "Repeat" ]);
|
||||
|
@ -15,7 +15,7 @@ function Node_Blur(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) cons
|
|||
inputs[| 5] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 6] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 7] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 7;
|
||||
|
|
|
@ -8,12 +8,12 @@ function Node_Blur_Bokeh(_x, _y, _group = noone) : Node_Processor(_x, _y, _group
|
|||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 1] = nodeValue("Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.2)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 16, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [0, 16, 0.01] });
|
||||
|
||||
inputs[| 2] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 3] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 4] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 4;
|
||||
|
|
|
@ -10,15 +10,15 @@ function Node_Blur_Contrast(_x, _y, _group = noone) : Node_Processor(_x, _y, _gr
|
|||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 1] = nodeValue("Size", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 3)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [1, 32, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 1] });
|
||||
|
||||
inputs[| 2] = nodeValue("Threshold", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.2, "Brightness different to be blur together.")
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 3] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 4] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 5] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 5;
|
||||
|
|
|
@ -4,7 +4,7 @@ function Node_Blur_Directional(_x, _y, _group = noone) : Node_Processor(_x, _y,
|
|||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 1] = nodeValue("Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.2)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 0.1, 0.001]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [0, 0.1, 0.001] });
|
||||
|
||||
inputs[| 2] = nodeValue("Direction", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
@ -12,7 +12,7 @@ function Node_Blur_Directional(_x, _y, _group = noone) : Node_Processor(_x, _y,
|
|||
inputs[| 3] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 4] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 5] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 5;
|
||||
|
|
|
@ -16,7 +16,7 @@ function Node_Blur_Radial(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
|||
inputs[| 4] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 5] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 6] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 6;
|
||||
|
@ -33,7 +33,7 @@ function Node_Blur_Radial(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
|||
attribute_interpolation();
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
|
||||
var pos = inputs[| 2].getValue();
|
||||
var pos = getInputData(2);
|
||||
var px = _x + pos[0] * _s;
|
||||
var py = _y + pos[1] * _s;
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ function Node_Blur_Simple(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
|||
|
||||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
inputs[| 1] = nodeValue("Size", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 3)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [1, 32, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 1] });
|
||||
|
||||
inputs[| 2] = nodeValue("Oversample mode", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0, "How to deal with pixel outside the surface.\n - Empty: Use empty pixel\n - Clamp: Repeat edge pixel\n - Repeat: Repeat texture.")
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, [ "Empty", "Clamp", "Repeat" ]);
|
||||
|
@ -27,7 +27,7 @@ function Node_Blur_Simple(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
|||
inputs[| 6] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 7] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 8] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 8;
|
||||
|
|
|
@ -20,7 +20,7 @@ function Node_Blur_Zoom(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
inputs[| 6] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 7] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 8] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 8;
|
||||
|
@ -36,7 +36,7 @@ function Node_Blur_Zoom(_x, _y, _group = noone) : Node_Processor(_x, _y, _group)
|
|||
attribute_oversample();
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
|
||||
var pos = inputs[| 2].getValue();
|
||||
var pos = getInputData(2);
|
||||
var px = _x + pos[0] * _s;
|
||||
var py = _y + pos[1] * _s;
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ function Node_Boolean(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
hover_state = 0;
|
||||
hover_state_to = 0;
|
||||
|
||||
wd_checkBox = new checkBox( function() { inputs[| 0].setValue(!inputs[| 0].getValue()); } );
|
||||
wd_checkBox = new checkBox( function() { inputs[| 0].setValue(!getInputData(0)); } );
|
||||
wd_checkBox.spr = THEME.node_checkbox;
|
||||
|
||||
inputs[| 0] = nodeValue("Value", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false)
|
||||
|
@ -30,7 +30,7 @@ function Node_Boolean(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
}
|
||||
|
||||
static pointIn = function(_x, _y, _mx, _my, _s) {
|
||||
var align = inputs[| 2].getValue();
|
||||
var align = getInputData(2);
|
||||
var xx = x * _s + _x;
|
||||
var yy = (y - (!align * 20)) * _s + _y;
|
||||
|
||||
|
@ -43,7 +43,7 @@ function Node_Boolean(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
|
||||
static drawNodeBase = function(xx, yy, _s) {
|
||||
if(!active) return;
|
||||
var hid = inputs[| 1].getValue();
|
||||
var hid = getInputData(1);
|
||||
|
||||
if(hid) {
|
||||
hover_state = lerp_float(hover_state, hover_state_to, 3);
|
||||
|
@ -63,8 +63,8 @@ function Node_Boolean(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
var _name = display_name == ""? name : display_name;
|
||||
if(_name == "") return;
|
||||
|
||||
var hid = inputs[| 1].getValue();
|
||||
var align = inputs[| 2].getValue();
|
||||
var hid = getInputData(1);
|
||||
var align = getInputData(2);
|
||||
|
||||
if(align == 0) {
|
||||
draw_set_text(f_p2, fa_center, fa_bottom, COLORS._main_text);
|
||||
|
@ -79,7 +79,7 @@ function Node_Boolean(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) {
|
||||
draw_set_text(f_h5, fa_center, fa_center, COLORS._main_text);
|
||||
var val = inputs[| 0].getValue();
|
||||
var val = getInputData(0);
|
||||
var bbox = drawGetBbox(xx, yy, _s);
|
||||
|
||||
wd_checkBox.setFocusHover(_focus, _hover);
|
||||
|
|
|
@ -8,15 +8,15 @@ function Node_BW(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) constr
|
|||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 1] = nodeValue("Brightness", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ -1, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ -1, 1, 0.01] });
|
||||
|
||||
inputs[| 2] = nodeValue("Contrast", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ -1, 4, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ -1, 4, 0.01] });
|
||||
|
||||
inputs[| 3] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 4] = nodeValue("Mix", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 5] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 5;
|
||||
|
|
|
@ -37,7 +37,7 @@ function Node_Cache(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
|
|||
if(recoverCache()) return;
|
||||
if(!inputs[| 0].value_from) return;
|
||||
|
||||
var _surf = inputs[| 0].getValue();
|
||||
var _surf = getInputData(0);
|
||||
cacheCurrentFrame(_surf);
|
||||
}
|
||||
|
||||
|
|
|
@ -44,9 +44,9 @@ function Node_Cache_Array(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
|
||||
static update = function() {
|
||||
var ss = [];
|
||||
var str = inputs[| 1].getValue();
|
||||
var lst = inputs[| 2].getValue();
|
||||
var stp = inputs[| 3].getValue();
|
||||
var str = getInputData(1);
|
||||
var lst = getInputData(2);
|
||||
var stp = getInputData(3);
|
||||
|
||||
if(str < 0) str = 1;
|
||||
if(lst < 0) lst = PROJECT.animator.frames_total;
|
||||
|
@ -67,7 +67,7 @@ function Node_Cache_Array(_x, _y, _group = noone) : Node(_x, _y, _group) constru
|
|||
if(!PROJECT.animator.is_playing) return;
|
||||
if(!inputs[| 0].value_from) return;
|
||||
|
||||
var _surf = inputs[| 0].getValue();
|
||||
var _surf = getInputData(0);
|
||||
cacheCurrentFrame(_surf);
|
||||
}
|
||||
|
||||
|
|
|
@ -3,11 +3,13 @@ function Node_Camera(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co
|
|||
preview_alpha = 0.5;
|
||||
|
||||
inputs[| 0] = nodeValue("Background", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
onSurfaceSize = function() { return getInputData(0, DEF_SURF); };
|
||||
inputs[| 1] = nodeValue("Focus area", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, [ 0, 0, 16, 16, AREA_SHAPE.rectangle ])
|
||||
.setDisplay(VALUE_DISPLAY.area, function() { return getDimension(0); });
|
||||
.setDisplay(VALUE_DISPLAY.area, { onSurfaceSize });
|
||||
|
||||
inputs[| 2] = nodeValue("Zoom", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0.01, 4, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0.01, 4, 0.01 ] });
|
||||
|
||||
inputs[| 3] = nodeValue("Oversample mode", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0, "How to deal with pixel outside the surface.\n - Empty: Use empty pixel\n - Clamp: Repeat edge pixel\n - Repeat: Repeat texture.")
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, [ "Empty", "Repeat", "Repeat X", "Repeat Y" ]);
|
||||
|
@ -93,7 +95,7 @@ function Node_Camera(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) co
|
|||
refreshDynamicInput();
|
||||
}
|
||||
|
||||
static getPreviewValues = function() { return inputs[| 0].getValue(); }
|
||||
static getPreviewValues = function() { return getInputData(0); }
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) {
|
||||
if(array_length(current_data) == 0) return;
|
||||
|
|
|
@ -8,10 +8,10 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
|
||||
inputs[| 1] = nodeValue("Color", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white );
|
||||
inputs[| 2] = nodeValue("Brush size", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 1 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [1, 32, 1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [1, 32, 1] });
|
||||
|
||||
inputs[| 3] = nodeValue("Fill threshold", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 4] = nodeValue("Fill type", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.enum_scroll, ["4 connect", "8 connect", "Entire canvas"]);
|
||||
|
@ -26,12 +26,12 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
inputs[| 8] = nodeValue("Background", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, -1);
|
||||
|
||||
inputs[| 9] = nodeValue("Background alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1.)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 10] = nodeValue("Render background", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
|
||||
inputs[| 11] = nodeValue("Alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1 )
|
||||
.setDisplay(VALUE_DISPLAY.slider, [0, 1, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
outputs[| 0] = nodeValue("Surface out", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
|
||||
|
||||
|
@ -101,7 +101,7 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
}
|
||||
|
||||
function apply_surface() {
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var cDep = attrDepth();
|
||||
|
||||
if(!is_surface(canvas_surface)) {
|
||||
|
@ -129,7 +129,7 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
}
|
||||
|
||||
function apply_draw_surface() {
|
||||
var _alp = inputs[| 11].getValue();
|
||||
var _alp = getInputData(11);
|
||||
|
||||
storeAction();
|
||||
|
||||
|
@ -285,7 +285,7 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
} #endregion
|
||||
|
||||
function flood_fill_scanline(_x, _y, _surf, _thres, _corner = false) { #region
|
||||
var _alp = inputs[| 11].getValue();
|
||||
var _alp = getInputData(11);
|
||||
|
||||
var colorFill = draw_get_color() + (255 << 24);
|
||||
var colorBase = get_color_buffer(_x, _y);
|
||||
|
@ -375,7 +375,7 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
} #endregion
|
||||
|
||||
function canvas_fill(_x, _y, _surf, _thres) { #region
|
||||
var _alp = inputs[| 11].getValue();
|
||||
var _alp = getInputData(11);
|
||||
|
||||
var w = surface_get_width_safe(_surf);
|
||||
var h = surface_get_height_safe(_surf);
|
||||
|
@ -412,13 +412,13 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
mouse_cur_x = round((_mx - _x) / _s - 0.5);
|
||||
mouse_cur_y = round((_my - _y) / _s - 0.5);
|
||||
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _col = inputs[| 1].getValue();
|
||||
var _siz = inputs[| 2].getValue();
|
||||
var _thr = inputs[| 3].getValue();
|
||||
var _fill_type = inputs[| 4].getValue();
|
||||
var _prev = inputs[| 5].getValue();
|
||||
var _brush = inputs[| 6].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var _col = getInputData(1);
|
||||
var _siz = getInputData(2);
|
||||
var _thr = getInputData(3);
|
||||
var _fill_type = getInputData(4);
|
||||
var _prev = getInputData(5);
|
||||
var _brush = getInputData(6);
|
||||
|
||||
if(key_mod_press(ALT)) return;
|
||||
|
||||
|
@ -674,10 +674,10 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
gpu_set_colorwriteenable(true, true, true, true);
|
||||
|
||||
#region preview
|
||||
var _bg = inputs[| 8].getValue();
|
||||
var _bga = inputs[| 9].getValue();
|
||||
var _bgr = inputs[| 10].getValue();
|
||||
var _alp = inputs[| 11].getValue();
|
||||
var _bg = getInputData(8);
|
||||
var _bga = getInputData(9);
|
||||
var _bgr = getInputData(10);
|
||||
var _alp = getInputData(11);
|
||||
|
||||
var __s = surface_get_target();
|
||||
|
||||
|
@ -761,10 +761,10 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
}
|
||||
|
||||
static update = function(frame = PROJECT.animator.current_frame) {
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _bg = inputs[| 8].getValue();
|
||||
var _bga = inputs[| 9].getValue();
|
||||
var _bgr = inputs[| 10].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var _bg = getInputData(8);
|
||||
var _bga = getInputData(9);
|
||||
var _bgr = getInputData(10);
|
||||
|
||||
var cDep = attrDepth();
|
||||
apply_surface();
|
||||
|
@ -794,7 +794,7 @@ function Node_Canvas(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
|
|||
var buff = buffer_base64_decode(load_map.surface);
|
||||
canvas_buffer = buffer_decompress(buff);
|
||||
|
||||
var _dim = inputs[| 0].getValue();
|
||||
var _dim = getInputData(0);
|
||||
var _outSurf = outputs[| 0].getValue();
|
||||
_outSurf = surface_verify(_outSurf, _dim[0], _dim[1], attrDepth());
|
||||
canvas_surface = surface_create_from_buffer(_dim[0], _dim[1], canvas_buffer);
|
||||
|
|
|
@ -14,7 +14,7 @@ function Node_Checker(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
.setDisplay(VALUE_DISPLAY.vector);
|
||||
|
||||
inputs[| 1] = nodeValue("Amount", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 2)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [1, 16, 0.1]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [1, 16, 0.1] });
|
||||
|
||||
inputs[| 2] = nodeValue("Angle", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
|
||||
.setDisplay(VALUE_DISPLAY.rotation);
|
||||
|
@ -37,7 +37,7 @@ function Node_Checker(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) c
|
|||
attribute_surface_depth();
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) {
|
||||
var pos = inputs[| 3].getValue();
|
||||
var pos = getInputData(3);
|
||||
var px = _x + pos[0] * _s;
|
||||
var py = _y + pos[1] * _s;
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ function Node_Chromatic_Aberration(_x, _y, _group = noone) : Node_Processor(_x,
|
|||
.setUnitRef(function(index) { return getDimension(index); }, VALUE_UNIT.reference);
|
||||
|
||||
inputs[| 2] = nodeValue("Strength", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [-16, 16, 0.01]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [-16, 16, 0.01] });
|
||||
|
||||
inputs[| 3] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 3;
|
||||
|
@ -24,7 +24,7 @@ function Node_Chromatic_Aberration(_x, _y, _group = noone) : Node_Processor(_x,
|
|||
attribute_interpolation();
|
||||
|
||||
static drawOverlay = function(active, _x, _y, _s, _mx, _my, _snx, _sny) {
|
||||
var pos = inputs[| 1].getValue();
|
||||
var pos = getInputData(1);
|
||||
var px = _x + pos[0] * _s;
|
||||
var py = _y + pos[1] * _s;
|
||||
|
||||
|
|
|
@ -133,7 +133,7 @@ function Node_Collection(_x, _y, _group = noone) : Node(_x, _y, _group) construc
|
|||
if(!draw_input_overlay) return;
|
||||
for(var i = custom_input_index; i < ds_list_size(inputs); i++) {
|
||||
var _in = inputs[| i];
|
||||
var _show = _in.from.inputs[| 6].getValue();
|
||||
var _show = _in.from.getInputData(6);
|
||||
|
||||
if(!_show) continue;
|
||||
_in.drawOverlay(active, _x, _y, _s, _mx, _my, _snx, _sny);
|
||||
|
|
|
@ -15,7 +15,7 @@ function Node_Color(_x, _y, _group = noone) : Node_Processor(_x, _y, _group) con
|
|||
var bbox = drawGetBbox(xx, yy, _s);
|
||||
if(bbox.h < 1) return;
|
||||
|
||||
var col = inputs[| 0].getValue();
|
||||
var col = getInputData(0);
|
||||
|
||||
if(is_array(col)) {
|
||||
drawPalette(col, bbox.x0, bbox.y0, bbox.w, bbox.h);
|
||||
|
|
|
@ -19,32 +19,32 @@ function Node_Color_adjust(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 1] = nodeValue("Brightness", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ -1, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ -1, 1, 0.01 ] });
|
||||
|
||||
inputs[| 2] = nodeValue("Contrast", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 3] = nodeValue("Hue", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ -1, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ -1, 1, 0.01 ] });
|
||||
|
||||
inputs[| 4] = nodeValue("Saturation", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ -1, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ -1, 1, 0.01 ] });
|
||||
|
||||
inputs[| 5] = nodeValue("Value", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ -1, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ -1, 1, 0.01 ] });
|
||||
|
||||
inputs[| 6] = nodeValue("Blend", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, c_white);
|
||||
|
||||
inputs[| 7] = nodeValue("Blend alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 8] = nodeValue("Mask", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, 0);
|
||||
|
||||
inputs[| 9] = nodeValue("Alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 1, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider);
|
||||
|
||||
inputs[| 10] = nodeValue("Exposure", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1)
|
||||
.setDisplay(VALUE_DISPLAY.slider, [ 0, 4, 0.01 ]);
|
||||
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 4, 0.01 ] });
|
||||
|
||||
inputs[| 11] = nodeValue("Active", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, true);
|
||||
active_index = 11;
|
||||
|
@ -72,7 +72,7 @@ function Node_Color_adjust(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
attribute_surface_depth();
|
||||
|
||||
static step = function() {
|
||||
var type = inputs[| 12].getValue();
|
||||
var type = getInputData(12);
|
||||
|
||||
inputs[| 0].setVisible(type == 0, type == 0);
|
||||
inputs[| 8].setVisible(type == 0, type == 0);
|
||||
|
@ -170,7 +170,7 @@ function Node_Color_adjust(_x, _y, _group = noone) : Node_Processor(_x, _y, _gro
|
|||
} #endregion
|
||||
|
||||
static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) { #region
|
||||
var type = inputs[| 12].getValue();
|
||||
var type = getInputData(12);
|
||||
if(type == 0) return;
|
||||
|
||||
var bbox = drawGetBbox(xx, yy, _s);
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue