Closed tiloc closed 2 months ago
FWIW: CineMachine has a predefined tween called "Cut" which simply does a 0 duration hard cut.
Would just be a case of applying a duration value of 0
, no?
That's what the 3d_example_scene
does.
Would just be a case of applying a duration value of
0
, no? That's what the3d_example_scene
does.
yes, I have re-added the tweens now and set the duration to 0. But I'm still not clear, is having a "Tween Resource" meant to be mandatory? I would either expect the add-on to function without one, or give me a warning when I dare to remove it.
It's not mandatory per se, but if you don't specify the tween it will have a default duration.
It's not mandatory per se, but if you don't specify the tween it will have a default duration.
if I look at the source (https://github.com/ramokz/phantom-camera/blob/5e79b9071a1db36a6771225f2276b2d9b944aa66/addons/phantom_camera/scripts/phantom_camera_host/phantom_camera_host.gd#L239) it seems that tween functions are invoked without any check whether a tween actually exists. This will then result in an error here: https://github.com/ramokz/phantom-camera/blob/5e79b9071a1db36a6771225f2276b2d9b944aa66/addons/phantom_camera/scripts/phantom_camera/phantom_camera_3d.gd#L936
It has a default tween resource applied internally if you don't assign one.
Are you encountering any runtime errors?
It has a default tween resource applied internally if you don't assign one.
Are you encountering any runtime errors?
I was when I opened the issue. I fetched another copy of my project from GitHub and now the errors are gone... Weird, will close for now, as no longer reproducible. Not sure what Godot's behaviour regarding exports is supposed to be, as I used "Clear" in the inspector to delete that default tween and that's when the errors began to appear. But now I deleted the default tween again and no errors.
Issue description
I want to do hard camera cuts with no tweening when moving from camera to camera. I have therefore deleted the tweening from the inspector. Now I am getting these error messages: res://addons/phantom_camera/scripts/phantom_camera/phantom_camera_3d.gd:945 - Invalid get index 'duration' (on base: 'null instance').
Looking at the source code it seems that something in the code assumes that tweening is always there?
Steps to reproduce
see above.
(Optional) Minimal reproduction project
No response