Jump to content

(Solved) Help with content shown using 2 CAMERA entities


Russell
 Share

Recommended Posts

Hi there team!!

I have one question i hope you can help me with...

I have a level with only 2 cameras for show an animation prologue... Text and Images using POSTRENDER and context system works ok in CAMERA 1.

But when i disable CAMERA1 and enable CAMERA2 for continue animation in another location of the map, TEXT and IMAGES don't appear on CAMERA 2...

Anyone have any tip or idea why is this happening??? If you need more information ask me... I don't know how solve this...

Thank you very much!!

Link to comment
Share on other sites

Place a pivot in the exact rotation and location of your second camera and then write a small script that puts your current camera wherever the cutscene pos is. You need to think of having only one camera at all times. Store information about text/images/post process in script and disable/enable whenever you need it.

  • Thanks 1
Link to comment
Share on other sites

16 minutes ago, Slastraf said:

Place a pivot in the exact rotation and location of your second camera and then write a small script that puts your current camera wherever the cutscene pos is. You need to think of having only one camera at all times. Store information about text/images/post process in script and disable/enable whenever you need it.

Thank you very much for your answer!!

I'm going to try it, even though camera1 is fixed, and camera2 is anchored on a moving platform.

Link to comment
Share on other sites

11 hours ago, Slastraf said:

Place a pivot in the exact rotation and location of your second camera and then write a small script that puts your current camera wherever the cutscene pos is. You need to think of having only one camera at all times. Store information about text/images/post process in script and disable/enable whenever you need it.

I'm trying change position of the CAMERA to the location where the PIVOT is with this script:

Script.Target = nil --entity
Script.Enabled = true --bool

function Script:Teletate(entity, position, normal)--in
	if self.enabled then
		entity:SetPosition(self.Target:GetPosition()) -- Teleports
		self.component:CallOutputs("Teletate")
	end
end

But i don't know why the camera don't change the position, Do you see anything there I am encoding wrong?

Link to comment
Share on other sites

10 minutes ago, Slastraf said:

Check your parameters because you are not using them except entity and i dont know if it collides with sometihg so maybe rename that.  Check if target is set and if the function is called.

Thanks very much, I made it!! Animation made with only one camera. And now Text and Images using POSTRENDER shows all stuff ok!!

Finally i my in my specific i don't need use the Pivot in the location of the camera2 (deleted right now).

In my case for the prologue animation I only need setup Position and Rotation for the one camera with:

function Script:Location2()--in
		self.entity:SetPosition(0.953,2.579,3.319)
		self.entity:SetRotation(0,34,0)
		self.component:CallOutputs("Location2")
end

I know, is very specific and not very usefull for another situations. But at this moment I only need this.

I only needed one more thing, and that was attach the camera to the moving platform of the camera2 to get the effect I need for the animation of the prologue.

Thank you so much for the pivot idea Slastraf. Even if I have not used it in this animation prologue, it will be valid for other places.

Link to comment
Share on other sites

  • Russell changed the title to (Solved) Help with content shown using 2 CAMERA entities

Ok, good news!!

After several tests, Headaches, and discarded ideas, I have finally recovered the idea and development of the 2 camera entities in my prologue-animation map. ¿Why?

Because at some point of the developtment of the new content for my FotoMuseo 3D, I will need to create an animation with 4 and 6 cameras. All of them with different context effects, screen colours and movements. And the idea of using only one camera entity placing it in 2 to 6 different locations is a bit crazy idea for my development. Yes or yes i need more than one camera.

My problem when I opened this thread was that the TEXT and IMAGES WERE NOT SHOWN on camera2 but YES on camera1.

As I said, after several testsI have already found the source of my problem.

I use global variables for the new DIALOG / SUBTITLE SYSTEM that I am working on in FotoMuseo 3D. And when the dialog/subtitutle1 is disabled via code (not using a button as usual when we are playing the map), it did not empty the variable again. With which the rest of the contents that should be shown in camera2 are not seen in whole rest of animation.

Finally, my headache it was something as simple like a badly coded variable in the animation because in the animation we don't use Buttons of the Dialog system.

I have fixed it and now the animation works ok with 2 camera entities like in the beginning and the dialog/subtitle system is improved with non interactive moments of the gameplay.

Thanks Slastraf for your idea, although it has not helped in my specific development, at least it has shown me the way to find the problem that was driving me crazy.

And now I can also change the camera locations via code, something I didn't know how to do either.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...