Author Topic: Cutscene problem - attaching the camera to a fighter  (Read 4677 times)

0 Members and 1 Guest are viewing this topic.

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Cutscene problem - attaching the camera to a fighter
I'm currently trying to set-up a cutscene with FRED where the player is to see the patrol flight of another wing from the perspective of one of those fighters...
Patrol 3 is Herc II with initial orders to fly waypoints parallel to Patrol 1 & 2 which fly respective waypoints

EDIT: I forgot - I'm running on 3.6.10 RC2 for fs2_open.exe

First I tired it with the "set-camera-host" - event was set up just like this:
Code: [Select]
- when
   |____ ture
   |
   |____set camera host
             |___ Patrol 3
             |___ weapons
problem is that the camera is no in the center of the fighter, as if the second argument would do nothing at all ....

Am I missing something here?
Or is this just another chase for Mantis?
Or do I have to wait for 3.6.11?





ps. I tried to work around the problem the following way but it does not work either (camera is constantly shaking from the rapid repositioning; would not adjust for itself if fighter turned) - but still that was more close to the solution I wanted...
Code: [Select]
- every-time
   |____ ture
   |
   |____set camera position
             |___+
                 |_ get object x
                      |_ Patrol 3
                 |_ 2
             |___-
                 |_ get object y
                      |_ Patrol 3
                 |_ 1
             |___+
                 |_ get object z
                      |_ Patrol 3
                 |_ 2
« Last Edit: July 14, 2009, 03:22:31 pm by 0rph3u5 »
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Re: Cutscene problem - set-camera-host
The xyz is relative to the world. I've not managed to get a camera to match perspectives with a fighter yet but i'll upload a quick mission later on when I get home from work. It might help you out.
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - set-camera-host
I've not managed to get a camera to match perspectives with a fighter yet

I dont want the perspective to be an exact match it should be more like this (well without being stuck in the side of the Herc):
[EDIT: now better perspective]

[EDIT2: attachments deleted]
« Last Edit: July 17, 2009, 10:24:50 am by 0rph3u5 »
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - set-camera-host
Okay... with the help of Mobius and a lot of patience I've achived a nearly working solution....
you still see the camera reseting all the time since there are always objects in the view-field...
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline Skullar

  • 29
Re: Cutscene problem - attaching the camera to a fighter
are you updating a campaign or is this for something new ?

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - attaching the camera to a fighter
Can you send me the fs2 file you are messing with ? I want to see what you are doing, and wanna give it a try myself :)

Not until the campaign is done; its for a plot-critical cutscene
Spoiler:
its so crictical I dont dare to úse these tags to talk about it

are you updating a campaign or is this for something new ?

its for "The Lost Generation" - I need to re-create some good-old FS2 moments as cutscenes to drive the story of that campaign onwards
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 
Re: Cutscene problem - attaching the camera to a fighter
We can't help you without sighting some of these files - it's too hard to try and figure out what you're doing.
The other way to get help is to jump on #hard-light and ask for directions from there.

EDIT: Better still, boil it down to a really simple case that folks can then work from.
« Last Edit: July 17, 2009, 04:48:59 am by portej05 »
STRONGTEA. Why can't the x86 be sane?

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - attaching the camera to a fighter
this is not about some fancy FREDing operation; it is quite simple  and a description of the situation is given in post #1....

simply set up an event a la when-ture-set_camera_host etc. and see for yourselves

"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Re: Cutscene problem - attaching the camera to a fighter
That'll only do it the once. You need to everytime it. Wait til later i'll post an old concept of different camera usage.
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - attaching the camera to a fighter
That'll only do it the once. You need to everytime it. Wait til later i'll post an old concept of different camera usage.

unless you are refering to the workaround:

As I have seen it it is quite the contrary:
set_camera_host attaches the camera to the object until the said otherwise; I had it working with a moving object but not at the right point (read post #1 damn you!), problem with that sexp is that the second argument does not appear to do anything at all the way I did this....
which leads to the camera being stuck right in the middle of the Herc here....

once I get home I'll re-enable that event and make another screenshot of it so you see what I mean.
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Re: Cutscene problem - attaching the camera to a fighter
Use mathematical modifiers on the x y z bits of the get object coordinates.
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - attaching the camera to a fighter
here come the perspective shots + the respective sexps...

Notes on picture no. 1 - the WORKAROUND:
- get-object-y/z are are the same as ...-x except the numbers in the mathematical operators are different
- the accumulation of mathematical operators comes due to the fact that FRED does not acknowledge eg. 2.5 as number in operators (though I'm not quite sure here whetever this does anything or not)
- you cannot see the camera reseting everytime

Notes on picture no. 2 - the REAL DEAL:
- the weapons sub-system of the Herc II (and as well that of the Herc II HTL) is suposed to be somewhere above the left shoulder of the pilot....

[attachment deleted by MSC
« Last Edit: July 17, 2009, 10:34:10 am by 0rph3u5 »
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Re: Cutscene problem - attaching the camera to a fighter
Try something like this. I've decided against uploading my mission as it uses numerous additional ships, hud effects, subtitle graphics and sound files... It's frickin sweet as an intro though....


In short, try to add a + to the right axises/axees/axiis??? and tweak through trial and erro (or just get the eye point position using PCS2.)


EDIT- "Camera off" is chained to whatever time you see fit.

[attachment deleted by MSC
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline Tomo

  • 28
Re: Cutscene problem - attaching the camera to a fighter
According to the SCP SEXP Wiki, set-camera-position works in World-Space (Mission Space), which means Dekker's solution doesn't work at all.

Turn the ship upside down, and the camera will not follow the roll - as 0rph3u5 mentioned.

FRED doesn't have matrix operators, which means that set-camera-position simply can't be used for this effect.
The FRED-only solution must be set-camera-host, but that SEXP doesn't seem to be documented in the Wiki.

An alternative solution would be to do it as a script, as that does allow you to work in model space and then transform to world-space. To be honest, that looks to be the only genuine solution at present if set-camera-host isn't working for subsystems.

 

Offline Colonol Dekker

  • HLP is my mistress
  • 213
  • Aken Tigh Dekker- you've probably heard me
    • My old squad sub-domain
Re: Cutscene problem - attaching the camera to a fighter
Maybe host could use a "attach to eyepoint" thing moving forward in development.
Campaigns I've added my distinctiveness to-
- Blue Planet: Battle Captains
-Battle of Neptune
-Between the Ashes 2
-Blue planet: Age of Aquarius
-FOTG?
-Inferno R1
-Ribos: The aftermath / -Retreat from Deneb
-Sol: A History
-TBP EACW teaser
-Earth Brakiri war
-TBP Fortune Hunters (I think?)
-TBP Relic
-Trancsend (Possibly?)
-Uncharted Territory
-Vassagos Dirge
-War Machine
(Others lost to the mists of time and no discernible audit trail)

Your friendly Orestes tactical controller.

Secret bomb God.
That one time I got permabanned and got to read who was being bitxhy about me :p....
GO GO DEKKER RANGERSSSS!!!!!!!!!!!!!!!!!
President of the Scooby Doo Model Appreciation Society
The only good Zod is a dead Zod
NEWGROUNDS COMEDY GOLD, UPDATED DAILY
http://badges.steamprofile.com/profile/default/steam/76561198011784807.png

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - attaching the camera to a fighter
Dekker's solution is simply the same as my workaround - I can say that without having tried yet 'cause Both are the same

I go the way

[X] + (a + b/c) = [X] + n ; n is the number returned from n = a + b/c

while he goes

0 + [X] + n = [X] + n ; n is a number

though I'm bad in maths I can say for sure that is the same equation; though mine as the advantage that the range of number is greater if FRED really acknowledges b/c to return a number other than 01) in chases c > b 2)....

-------------------------------------------------------------------------

Now to the intersting part.... I've developed another workaround I was too afraid to touch yet
BUT BE WARNED: this workaround will only work in nebula enviorment or with respective background changes and fade-in/-out...

since one can expand set-camera-postion from simply 3 arguments (simply coordinates) to 5 arguments (coordinates, movement time and acceleration time)3) one could let the camera move aside the fighter at the same speed (given you have limited the fighters speed with cap-waypoints-speed or otherwise)....
but that requires some calcuations (you have to calculate the time of movement so the camera speed will matche the fighter's speed; a matter of c = d * t-1, or the derived t = d * c-1) and it would not respond to the fighter maneuvering around (unless that is also that way scripted - if that is possible at all), would require bit more of tiral and error and would not work if the FRED does not acknowelde numbers smaller than 1 to be different from zero in events2)

1) dunno if it fixed yet but FRED has the unpleasent ability to set all numbers it does not fully reckognise to be not different 0 (as it happens to be if you tried to randomize negative numbers)
2) FRED does not reckognize non-Natural Numbers (eg 2.5) as numbers if entered normally into a number field of a sexp  - it comes up with "no a number" in such chases; hence that damn workaround in pciture 1
3) acutally its six possilbe arguments...

EDIT: here comes a test picture - mind that I just entered some random numbers (10000 & 1000) - that made the camera speed right past the Hercs and allowed that to catch up later...

[attachment deleted by MSC
« Last Edit: July 18, 2009, 09:32:45 am by 0rph3u5 »
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline Tomo

  • 28
Re: Cutscene problem - attaching the camera to a fighter
Just had a quick scan through the code, and "set-camera-host" should be doing what is required.

I'm going to build a mini-mission now to see if it's working at all.

Edit:
Right, it does in fact do exactly what it says on the tin. It sets the camera to the origin of the stated sub-object, with the same orientation as the sub-object.
But... That's not actually what anybody would want, because the origin is almost always inside said sub-object.

So, it needs more data - it needs an offset in sub-object coordinates (X,Y,Z), so you can (for example) put the camera next to a turret and not have it always be physically inside.
« Last Edit: July 21, 2009, 01:23:05 pm by Tomo »

 

Offline Angelus

  • 210
  • The Angriest Angel
Re: Cutscene problem - attaching the camera to a fighter
What about editing the eyepoint of an ship, to the desired location and add the ship via .tbm, and adjust fov?
That's how i created some of the "gun-cam" views in my BtrL mission.

Yeah, it's not the most elegant approach, but it saves time and you avoid the agonizing headache that comes after working for hours/ days on a thing that refuses to work properly.

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Cutscene problem - attaching the camera to a fighter
I'm going to Mantis the probelm with set-camera-host now....

I'm still open for more alternative solutions BTW

What about editing the eyepoint of an ship, to the desired location and add the ship via .tbm, and adjust fov?
That's how i created some of the "gun-cam" views in my BtrL mission.

Yeah, it's not the most elegant approach, but it saves time and you avoid the agonizing headache that comes after working for hours/ days on a thing that refuses to work properly.

possible but work intensive - I'll keep it in mind if everything fails
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."