[Stack] Fix output surface not clearing.

This commit is contained in:
Tanasart 2024-12-27 09:04:09 +07:00
parent 5e6983681d
commit 8ae0dc2a57
23 changed files with 29 additions and 28 deletions

View file

@ -9,7 +9,7 @@ function __NodeValue_Object_Generic(_name, _node, _type, _value, _tooltip = "")
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -42,10 +42,10 @@
globalvar HOTKEYS, HOTKEY_CONTEXT;
LATEST_VERSION = 1_18_00_0;
VERSION = 1_18_06_0;
VERSION = 1_18_06_2;
SAVE_VERSION = 1_18_05_0;
VERSION_STRING = MAC? "1.18.003m" : "1.18.6";
BUILD_NUMBER = 1_18_06_0;
VERSION_STRING = MAC? "1.18.003m" : "1.18.6.2";
BUILD_NUMBER = 1_18_06_2;
PREF_VERSION = 1_17_1;
var _vsp = string_split(VERSION_STRING, ".");

View file

@ -86,10 +86,13 @@ function Node_Stack(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
var oh = hh + _padd[PADDING.top] + _padd[PADDING.bottom];
var _outSurf = outputs[0].getValue();
_outSurf = surface_verify(_outSurf, ow, oh, attrDepth());
_outSurf = surface_verify(_outSurf, ow, oh, attrDepth());
for( var i = 0, n = array_length(temp_surface); i < n; i++ )
for( var i = 0, n = array_length(temp_surface); i < n; i++ ) {
temp_surface[i] = surface_verify(temp_surface[i], ow, oh, attrDepth());
surface_clear(temp_surface[i]);
}
blend_temp_surface = temp_surface[2];
var atlas = [];
@ -143,9 +146,7 @@ function Node_Stack(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
surface_set_target(_outSurf);
DRAW_CLEAR
BLEND_OVERRIDE
draw_surface_safe(temp_surface[ppind]);
BLEND_NORMAL
surface_reset_target();

View file

@ -1206,7 +1206,7 @@ function NodeValue(_name, _node, _connect, _type, _value, _tooltip = "") constru
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
var dis = nod.display_type;

View file

@ -70,7 +70,7 @@ function __NodeValue_Area(_name, _node, _value, _data = {}) : NodeValue(_name, _
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return valueProcess(val, nod, applyUnit, arrIndex);
}

View file

@ -7,7 +7,7 @@ function __NodeValue_Color(_name, _node, _value, _tooltip = "") : NodeValue(_nam
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -7,7 +7,7 @@ function __NodeValue_Curve(_name, _node, _value) : NodeValue(_name, _node, CONNE
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -11,7 +11,7 @@ function __NodeValue_D3Material(_name, _node, _value, _tooltip = "") : NodeValue
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
var dis = nod.display_type;

View file

@ -15,7 +15,7 @@ function __NodeValue_Dimension(_node, value) : NodeValue("Dimension", _node, CON
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
if(typ != VALUE_TYPE.surface) {

View file

@ -8,7 +8,7 @@ function __NodeValue_Enum_Button(_name, _node, _value, _data) : NodeValue(_name,
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -8,7 +8,7 @@ function __NodeValue_Enum_Scroll(_name, _node, _value, _data) : NodeValue(_name,
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -12,7 +12,7 @@ function __NodeValue_Float(_name, _node, _value, _tooltip = "") : NodeValue(_nam
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
var dis = nod.display_type;

View file

@ -7,7 +7,7 @@ function __NodeValue_Gradient(_name, _node, _value, _tooltip = "") : NodeValue(_
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
if(is_instanceof(val, gradientObject)) return val;
if(nod.type != VALUE_TYPE.color) return val;

View file

@ -13,7 +13,7 @@ function __NodeValue_Int(_name, _node, _value, _tooltip = "") : NodeValue(_name,
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
var dis = nod.display_type;

View file

@ -18,7 +18,7 @@ function __NodeValue_Padding(_name, _node, _value, _tooltip = "") : NodeValue(_n
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var _d = array_get_depth(val);
__nod = nod;

View file

@ -9,7 +9,7 @@ function __NodeValue_Palette(_name, _node, _value, _tooltip = "") : NodeValue(_n
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
if(!is_array(val)) val = [ val ];
return val;

View file

@ -8,7 +8,7 @@ function __NodeValue_Quaternion(_name, _node, _value, _tooltip = "") : __NodeVal
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
var dis = nod.display_type;

View file

@ -8,7 +8,7 @@ function __NodeValue_Rotation(_name, _node, _value, _tooltip = "") : NodeValue(_
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
if(typ == VALUE_TYPE.text) val = toNumber(val);

View file

@ -9,7 +9,7 @@ function __NodeValue_Rotation_Random(_name, _node, _value, _tooltip = "") : __No
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) {
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
if(!is_array(val)) return [ 0, val, val, 0, 0 ];
if(array_length(val) == 2) return [ 0, val[0], val[1], 0, 0 ];

View file

@ -9,7 +9,7 @@ function __NodeValue_Surface(_name, _node, _value, _tooltip = "") : NodeValue(_n
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
draw_junction_index = VALUE_TYPE.surface;
if(is_instanceof(val, SurfaceAtlas) || (array_valid(val) && is_instanceof(val[0], SurfaceAtlas)))

View file

@ -7,7 +7,7 @@ function __NodeValue_Text(_name, _node, _value, _tooltip = "") : NodeValue(_name
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -7,7 +7,7 @@ function __NodeValue_Trigger(_name, _node, _value, _tooltip = "") : NodeValue(_n
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
return val;
}

View file

@ -19,7 +19,7 @@ function __NodeValue_Vec2(_name, _node, _value, _data = {}) : NodeValue(_name, _
static getValue = function(_time = CURRENT_FRAME, applyUnit = true, arrIndex = 0, useCache = false, log = false) { //// Get value
getValueRecursive(self.__curr_get_val, _time);
var val = __curr_get_val[0];
var nod = __curr_get_val[1]; if(!is(nod, Node)) return val;
var nod = __curr_get_val[1]; if(!is(nod, NodeValue)) return val;
var typ = nod.type;
if(typ != VALUE_TYPE.surface) {