ramokz / phantom-camera

👻🎥 Control the movement and dynamically tween 2D & 3D cameras. Built for Godot 4. Inspired by Cinemachine.
https://phantom-camera.dev/
MIT License
2.17k stars 71 forks source link

Handling phantomCamerahosts with swapping character scenes #219

Open swapmasterx opened 7 months ago

swapmasterx commented 7 months ago

Issue description

While its not currently an issue with multiplayer implementation where changing character controllers (changing from playable character to spectator character on death) causes the "Only one PhantomCameraHost can exist in a scene Multiple PhantomCameraHosts will be supported in https://github.com/MarcusSkov/phantom-camera/issues/26" error to occur. While I did see the links contents I'm wondering if there is a work around for switching character controllers while not encountering this issue while waiting for that update the time being. (since only one cam controller should be active anyhow.)

Steps to reproduce

(Optional) Minimal reproduction project

I'm new to coding so I'm not sure what I can pull out and the issue will still be replicable. If you can't replicate the error above though I can upload the full project on request.

ramokz commented 7 months ago

Think the solution you're looking for depends on how you've set up your scene.

You mention multiplayer, and to paraphrase what you've said just to make sure I understand it correctly, is your goal to you switch between 2 cameras. One for when the player is alive to another upon reaching 0 hp?