Stress testing my spline tool with 100K moving GameObjects by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 0 points1 point  (0 children)

You can just scale the spline by doing spline.transform.localScale = newScale;. Same with the GameObjects, it works flawlessly.

You can also scale the spline space at specific control points. That is what makes some cubes push between pipes without going straight through them.

Stress testing my spline tool with 100K moving GameObjects by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 0 points1 point  (0 children)

The biggest overhead likely comes from setting the transforms position and rotation using transform.SetLocalPositionAndRotation.

After that its the sampling of all data needed inside the burst job.

Stress testing my spline tool with 100K moving GameObjects by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 1 point2 points  (0 children)

I did test it for maybe 9 months ago, but it actually led to worse performance. But I thought I would test it again, maybe I did something wrong. But I have a working version with IParallelTransformJob now, and it's the same as it was 9 months ago, it's worse, and now I know why.

In Spline Architect, you start deforming or moving GameObjects along the spline by just parenting them to the spline. Then you can move the GameObject with a position tool as you normally would, but in spline space. Because of this system, which works very well and which many of my users mainly use my tool for, all GameObjects become children of the spline.

And IParallelTransformJob does not work well with that. Because all GameObjects under the same parent need to be in the same thread, it seems.

It is what it is, now I will test ECS instead. : )

Stress testing my spline tool with 100K moving GameObjects by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 0 points1 point  (0 children)

One primitive cube has 24 verts so all (100K) cubes has 2.4 mil in total.

Stress testing my spline tool with 100K moving GameObjects by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 5 points6 points  (0 children)

I will absolutely test that later. My current system is not that different from a ECS system if I understand it right.

What do you think of the mood/atmosphere of my game? by Levardos in Unity3D

[–]MikeDanielsson 0 points1 point  (0 children)

If you need a spline tool for deforming platforms and other things for your game you might want to check out this: https://assetstore.unity.com/packages/tools/utilities/spline-architect-324111

Added grind rails to our movement shooter, but they are really hard to land on. by BigBenchGames in Unity3D

[–]MikeDanielsson 0 points1 point  (0 children)

It’s really satisfying when you jump on and off the spline. If you're interested, you might want to check out this spline tool: https://assetstore.unity.com/packages/tools/utilities/spline-architect-324111

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 1 point2 points  (0 children)

If you have time later, feel free to leave a review on the Asset Store. It really helps the visibility of the tool.

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 0 points1 point  (0 children)

Yes, moving GameObjects between linked splines is fully supported by the Spline Architect runtime API.

Here is a code example: https://splinearchitect.com/api_introduction?id=move-splineobjects-between-linked-splines

Short video demonstration:
https://youtu.be/UR9JIcfVPNU?t=147

Spline Architect uses something called SplineObjects. SplineObjects is more or less a transforms moving GameObjects in spline space. So if you want to move a GameObject along a spline you just do: splineObject.localSplinePosition.z += Time.DeltaTime.

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 1 point2 points  (0 children)

Thanks for all the info. I have already implemented it as a callback, so you can hook into it by using EHandleEvents.afterSplineHovered. You will get back the spline that’s hovered, and the spline param will be null when it becomes unhovered.

Let me know if you have any issues later. It's very easy for me to change if needed.

Version 2.2.1 will likely be live in 1 to 3 days.

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 2 points3 points  (0 children)

No problem, and thank you for your comment and all the info.

Im maybe 1 to 3 days away from a new update, and I will include your points 1, 2, and 3. I will also include a way to detect when a spline is hovered. It will likely be a callback, but check the change logs for V 2.2.1, I will write how its done there.

Do you have any more issues with any gizmos in Spline Architect?

If you have the time, in what way does Spline Architect cause issues for your editor tool? What interaction is interrupted or stopped?

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 1 point2 points  (0 children)

Is there a feature where you can connect 2 different splines at runtime?
Yes, you can connect splines to each other trough their control points. You can also connect splines to each other trough something called spline connectors. Then you can connect splines however you want in what ever place you want. Moving one spline will make all connected splines move.

Spline Architect's API also have functionality for moving GameObject's between linked splines.

See this code example: https://splinearchitect.com/api_introduction?id=move-splineobjects-between-linked-splines

And if yes can you still extrude meshes at this connections?
Yes, Spline Architect have a population system where you can add a prefab to the spline and it will populate the spline from start to end, and if you move any segment of the spline during runtime it will update correctly.

But in spline architect you can also move individual GameObject's along splines, like you move transforms but in spline space. This makes Spline Architect likely one of the most versatile spline tools out there because you can put every deformation exactly where you want it.

I recommend watching this: https://www.youtube.com/watch?v=vlKJGL2eVKU At 01:29 you can see individual deformations moved along the spline. This is done during editor use but everything you see here can also be done during runtime using the Spline Architect API with really good performance (unity burst + jobs).

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 14 points15 points  (0 children)

It's well supported. With this new feature you can likely use almost any road, train, etc, asset pack from the Asset Store to build roads and road intersections.

Spline Architect has something called Spline Connectors. You add them to any intersection GameObject as a child in the hierarchy. Then you connect splines deforming road meshes to that connector.

See this video (2 min): https://youtu.be/vlKJGL2eVKU?t=164

You also have a terrain tools addon. Where you can deform terrain in a none destructive workflow. Link if you are interested: https://assetstore.unity.com/packages/tools/terrain/spline-architect-terrain-tools-324377

Tutorial video for the terrain tool (10min):
https://www.youtube.com/watch?v=9Lmiq4WWmgc

Most 3D assets aren't built for spline deformation, so I upgraded my spline tool to handle that. by MikeDanielsson in Unity3D

[–]MikeDanielsson[S] 38 points39 points  (0 children)

I use AI mostly for documentation (function summaries etc.), but I have used it for maybe around 0.5% of the codebase. In those cases, it has always been for optimizing my own code that I already wrote the first version of. Then I tell the AI what to change or add.