Pixel-Composer/scripts/node_iterate/node_iterate.gml

18 lines
547 B
Text
Raw Normal View History

2023-06-01 10:32:21 +02:00
function Node_Iterate(_x, _y, _group = noone) : Node_Iterator(_x, _y, _group) constructor {
name = "Loop";
2022-01-23 04:08:16 +01:00
2024-08-08 06:57:51 +02:00
inputs[0] = nodeValue_Int("Repeat", self, 1 )
2023-07-25 20:12:40 +02:00
.uncache();
2022-01-23 04:08:16 +01:00
2024-08-08 06:57:51 +02:00
custom_input_index = array_length(inputs);
2022-01-23 04:08:16 +01:00
2024-05-03 13:40:46 +02:00
if(NODE_NEW_MANUAL) { #region
2022-12-13 09:20:36 +01:00
var input = nodeBuild("Node_Iterator_Input", -256, -32, self);
var output = nodeBuild("Node_Iterator_Output", 256, -32, self);
2022-12-12 09:08:03 +01:00
2024-08-08 06:57:51 +02:00
input.inputs[2].setValue(4);
output.inputs[1].setFrom(input.outputs[1]);
} #endregion
2022-12-13 09:20:36 +01:00
static getIterationCount = function() { return getInputData(0); }
2022-01-23 04:08:16 +01:00
}