diff --git a/PixelComposer.resource_order b/PixelComposer.resource_order index c146af096..7bea213f3 100644 --- a/PixelComposer.resource_order +++ b/PixelComposer.resource_order @@ -2217,6 +2217,7 @@ {"name":"s_node_palette_sort","order":3,"path":"sprites/s_node_palette_sort/s_node_palette_sort.yy",}, {"name":"s_node_particle_effector","order":13,"path":"sprites/s_node_particle_effector/s_node_particle_effector.yy",}, {"name":"s_node_particle","order":12,"path":"sprites/s_node_particle/s_node_particle.yy",}, + {"name":"s_node_path_3d_camera","order":28,"path":"sprites/s_node_path_3d_camera/s_node_path_3d_camera.yy",}, {"name":"s_node_path_3d","order":20,"path":"sprites/s_node_path_3d/s_node_path_3d.yy",}, {"name":"s_node_path_anchor","order":1,"path":"sprites/s_node_path_anchor/s_node_path_anchor.yy",}, {"name":"s_node_path_array","order":2,"path":"sprites/s_node_path_array/s_node_path_array.yy",}, diff --git a/PixelComposer.yyp b/PixelComposer.yyp index ccf557c18..7132addf5 100644 --- a/PixelComposer.yyp +++ b/PixelComposer.yyp @@ -1157,6 +1157,7 @@ {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Number/Node_Statistic","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Number/Node_To_Number","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Number/Node_Transform_Array","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, + {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Path/Node_Path_3D_Camera","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Path/Node_Path_3D","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Path/Node_Path_Anchor","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, {"$GMIncludedFile":"","%Name":"info.json","CopyToMask":-1,"filePath":"datafiles/data/Nodes/Internal/Values/Path/Node_Path_Array","name":"info.json","resourceType":"GMIncludedFile","resourceVersion":"2.0",}, @@ -3561,6 +3562,7 @@ {"id":{"name":"s_node_palette","path":"sprites/s_node_palette/s_node_palette.yy",},}, {"id":{"name":"s_node_particle_effector","path":"sprites/s_node_particle_effector/s_node_particle_effector.yy",},}, {"id":{"name":"s_node_particle","path":"sprites/s_node_particle/s_node_particle.yy",},}, + {"id":{"name":"s_node_path_3d_camera","path":"sprites/s_node_path_3d_camera/s_node_path_3d_camera.yy",},}, {"id":{"name":"s_node_path_3d","path":"sprites/s_node_path_3d/s_node_path_3d.yy",},}, {"id":{"name":"s_node_path_anchor","path":"sprites/s_node_path_anchor/s_node_path_anchor.yy",},}, {"id":{"name":"s_node_path_array","path":"sprites/s_node_path_array/s_node_path_array.yy",},}, diff --git a/datafiles/data/Nodes/Internal.zip b/datafiles/data/Nodes/Internal.zip index 3220fea33..7a7f80570 100644 Binary files a/datafiles/data/Nodes/Internal.zip and b/datafiles/data/Nodes/Internal.zip differ diff --git a/datafiles/data/Nodes/Internal/Values/Path/Node_Path_3D_Camera/info.json b/datafiles/data/Nodes/Internal/Values/Path/Node_Path_3D_Camera/info.json index bb620a5ee..e8c7742af 100644 --- a/datafiles/data/Nodes/Internal/Values/Path/Node_Path_3D_Camera/info.json +++ b/datafiles/data/Nodes/Internal/Values/Path/Node_Path_3D_Camera/info.json @@ -2,7 +2,7 @@ "name":"3D Path Camera", "tooltip":"Render a 3D path into 2d space", "baseNode":"Node_Path_3D_Camera", - "spr":"s_node_path_3d", + "spr":"s_node_path_3d_camera", "pxc_version":118080, "io":[ "pathnode" ], } \ No newline at end of file diff --git a/scripts/node_path_3d_camera/node_path_3d_camera.gml b/scripts/node_path_3d_camera/node_path_3d_camera.gml index 6693a96fb..7e9b868e6 100644 --- a/scripts/node_path_3d_camera/node_path_3d_camera.gml +++ b/scripts/node_path_3d_camera/node_path_3d_camera.gml @@ -4,9 +4,9 @@ function Node_Path_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _g object = new __3dCamera_object(); camera = new __3dCamera(); - lookat = new __3dGizmoSphere(0.5, c_ltgray, 1); + lookat = new __3dGizmoSphere(.5, c_ltgray, .5); lookLine = noone; - lookRad = new __3dGizmoCircleZ(0.5, c_yellow, 0.5); + lookRad = new __3dGizmoCircleZ(.5, c_yellow, .5); w = 128; var i = in_d3d; @@ -88,6 +88,12 @@ function Node_Path_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _g static getToolSettings = function() { return curr_posm == 0? tool_settings : []; } static drawOverlay3D = function(active, params, _mx, _my, _snx, _sny, _panel) { + if(is_path) { + var _nodeFrom = inputs[in_d3d + 2].value_from.node; + if(struct_has(_nodeFrom, "drawOverlay3D")) + _nodeFrom.drawOverlay3D(false, params, _mx, _my, _snx, _sny, _panel); + } + var preObj = getPreviewObjects(); if(array_empty(preObj)) return; preObj = preObj[0]; @@ -269,7 +275,7 @@ function Node_Path_3D_Camera(_x, _y, _group = noone) : Node_3D_Object(_x, _y, _g static onDrawNode = function(xx, yy, _mx, _my, _s, _hover, _focus) { var bbox = drawGetBbox(xx, yy, _s); - draw_sprite_bbox_uniform(s_node_path_3d, 0, bbox); + draw_sprite_bbox_uniform(s_node_path_3d_camera, 0, bbox); } static getPreviewObject = function() { return noone; } diff --git a/scripts/node_path_trim/node_path_trim.gml b/scripts/node_path_trim/node_path_trim.gml index 15f3caa05..f9dc6aeb6 100644 --- a/scripts/node_path_trim/node_path_trim.gml +++ b/scripts/node_path_trim/node_path_trim.gml @@ -49,7 +49,6 @@ function Node_Path_Trim(_x, _y, _group = noone) : Node(_x, _y, _group) construct static getBoundary = function(ind = 0) /*=>*/ {return is_path? curr_path.getBoundary(ind) : new BoundingBox( 0, 0, 1, 1 )}; static getPointRatio = function(_rat, ind = 0, out = undefined) { - if(out == undefined) out = new __vec2P(); else { out.x = 0; out.y = 0; } if(!is_path) return out; _rat = lerp(curr_range[0], curr_range[1], _rat); diff --git a/sprites/s_node_path_3d_camera/be23148a-414a-41d6-8ace-64a25fbc38b1.png b/sprites/s_node_path_3d_camera/be23148a-414a-41d6-8ace-64a25fbc38b1.png new file mode 100644 index 000000000..80463a32f Binary files /dev/null and b/sprites/s_node_path_3d_camera/be23148a-414a-41d6-8ace-64a25fbc38b1.png differ diff --git a/sprites/s_node_path_3d_camera/layers/be23148a-414a-41d6-8ace-64a25fbc38b1/3969acaa-d4f5-4634-bd99-4dbe3b79b576.png b/sprites/s_node_path_3d_camera/layers/be23148a-414a-41d6-8ace-64a25fbc38b1/3969acaa-d4f5-4634-bd99-4dbe3b79b576.png new file mode 100644 index 000000000..80463a32f Binary files /dev/null and b/sprites/s_node_path_3d_camera/layers/be23148a-414a-41d6-8ace-64a25fbc38b1/3969acaa-d4f5-4634-bd99-4dbe3b79b576.png differ diff --git a/sprites/s_node_path_3d_camera/s_node_path_3d_camera.yy b/sprites/s_node_path_3d_camera/s_node_path_3d_camera.yy new file mode 100644 index 000000000..3142a5874 --- /dev/null +++ b/sprites/s_node_path_3d_camera/s_node_path_3d_camera.yy @@ -0,0 +1,90 @@ +{ + "$GMSprite":"", + "%Name":"s_node_path_3d_camera", + "bboxMode":0, + "bbox_bottom":61, + "bbox_left":1, + "bbox_right":62, + "bbox_top":2, + "collisionKind":1, + "collisionTolerance":0, + "DynamicTexturePage":false, + "edgeFiltering":false, + "For3D":false, + "frames":[ + {"$GMSpriteFrame":"","%Name":"be23148a-414a-41d6-8ace-64a25fbc38b1","name":"be23148a-414a-41d6-8ace-64a25fbc38b1","resourceType":"GMSpriteFrame","resourceVersion":"2.0",}, + ], + "gridX":0, + "gridY":0, + "height":64, + "HTile":false, + "layers":[ + {"$GMImageLayer":"","%Name":"3969acaa-d4f5-4634-bd99-4dbe3b79b576","blendMode":0,"displayName":"default","isLocked":false,"name":"3969acaa-d4f5-4634-bd99-4dbe3b79b576","opacity":100.0,"resourceType":"GMImageLayer","resourceVersion":"2.0","visible":true,}, + ], + "name":"s_node_path_3d_camera", + "nineSlice":null, + "origin":4, + "parent":{ + "name":"path", + "path":"folders/nodes/icons/value/path.yy", + }, + "preMultiplyAlpha":false, + "resourceType":"GMSprite", + "resourceVersion":"2.0", + "sequence":{ + "$GMSequence":"", + "%Name":"s_node_path_3d_camera", + "autoRecord":true, + "backdropHeight":768, + "backdropImageOpacity":0.5, + "backdropImagePath":"", + "backdropWidth":1366, + "backdropXOffset":0.0, + "backdropYOffset":0.0, + "events":{ + "$KeyframeStore":"", + "Keyframes":[], + "resourceType":"KeyframeStore", + "resourceVersion":"2.0", + }, + "eventStubScript":null, + "eventToFunction":{}, + "length":1.0, + "lockOrigin":false, + "moments":{ + "$KeyframeStore":"", + "Keyframes":[], + "resourceType":"KeyframeStore", + "resourceVersion":"2.0", + }, + "name":"s_node_path_3d_camera", + "playback":1, + "playbackSpeed":30.0, + "playbackSpeedType":0, + "resourceType":"GMSequence", + "resourceVersion":"2.0", + "showBackdrop":true, + "showBackdropImage":false, + "timeUnits":1, + "tracks":[ + {"$GMSpriteFramesTrack":"","builtinName":0,"events":[],"inheritsTrackColour":true,"interpolation":1,"isCreationTrack":false,"keyframes":{"$KeyframeStore":"","Keyframes":[ + {"$Keyframe":"","Channels":{ + "0":{"$SpriteFrameKeyframe":"","Id":{"name":"be23148a-414a-41d6-8ace-64a25fbc38b1","path":"sprites/s_node_path_3d_camera/s_node_path_3d_camera.yy",},"resourceType":"SpriteFrameKeyframe","resourceVersion":"2.0",}, + },"Disabled":false,"id":"2810fec7-d1dc-4a45-aa34-b7a73f95f41a","IsCreationKey":false,"Key":0.0,"Length":1.0,"resourceType":"Keyframe","resourceVersion":"2.0","Stretch":false,}, + ],"resourceType":"KeyframeStore","resourceVersion":"2.0",},"modifiers":[],"name":"frames","resourceType":"GMSpriteFramesTrack","resourceVersion":"2.0","spriteId":null,"trackColour":0,"tracks":[],"traits":0,}, + ], + "visibleRange":null, + "volume":1.0, + "xorigin":32, + "yorigin":32, + }, + "swatchColours":null, + "swfPrecision":0.5, + "textureGroupId":{ + "name":"Default", + "path":"texturegroups/Default", + }, + "type":0, + "VTile":false, + "width":64, +} \ No newline at end of file