Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → Cutscenes Cog
Cutscenes Cog
2002-02-03, 5:57 PM #1
Does anyone know how to make a a cog that shows a ship moving from one place to another. Then it shows another room and finally it displays some text and exits the level. Could you please post the actual code. Thanks!!
"Intelligent people know of what they speak; fools speak of what they know."

- Minchas Shabbos Pirkei Avos 3:18 / Ethics Of The Fathers
2002-02-03, 7:07 PM #2
Sounds like fun!

Code:
#02/2002 GBK
Symbols
Message Startup
Thing Ship
Thing Player			Local
Thing Cam0
Thing Cam1
Int Ship_targetframe=1
Flex Ship_movespeed=2.0
Flex Roomwait0=1.0
Flex Roomwait1=2.0
End
Code
Startup:
Player = JKgetlocalplayer();
Setactorflags(Player, 0xa00008);
Setcamerafocus(0, Cam0);
Movetoframe(Ship, Ship_targetframe, Ship_movespeed);
Waitforstop(Ship);
Setcamerafocus(0, Cam1);
Sleep(Roomwait0);
JKstringclear();
JKstringconcatasciistring("YOUR TEXT HERE.");
JKstringoutput(Player, -1);
Sleep(Roomwait1);
JKendlevel(1);
Stop;
End



Credit me... [http://forums.massassi.net/html/biggrin.gif]


------------------
Success is the inverse relationship between effort, gain, and loss.
And when the moment is right, I'm gonna fly a kite.
2002-02-04, 4:30 AM #3
It works except that it only shows where the second camera sees, it never show the first camera's Point-of-view
"Intelligent people know of what they speak; fools speak of what they know."

- Minchas Shabbos Pirkei Avos 3:18 / Ethics Of The Fathers
2002-02-04, 9:39 AM #4
I just tested it, it works fine for me.

BUT, I think I know what could be causing your problem:

The cog will show the first view while the ship is in transit. AS SOON as it reaches the 'targetframe', the view will shift to the second camera.

SO, ensure that your ship actully has frames, and that those frames are set up properly.

------------------
Success is the inverse relationship between effort, gain, and loss.
And when the moment is right, I'm gonna fly a kite.
2002-02-04, 12:24 PM #5
How do I set up and add frames? (I think there would just be two frames for my purposes) BTW, could you rewrite the code with frames. I'm trying to get better at cogs, so an example will help. Thanks.
"Intelligent people know of what they speak; fools speak of what they know."

- Minchas Shabbos Pirkei Avos 3:18 / Ethics Of The Fathers
2002-02-04, 12:47 PM #6
You don't set up the frames in the cog - you set them up on the 3do. Go take a look at the doors and elevators tutorial. They show you how to set up frames.

------------------
Have Lightsaber Will Travel JK Editing tips, troubleshooting information, resources and more.

The Massassi A SW Galaxies Player Association
Have Lightsaber Will Travel JK Editing tips, troubleshooting information, resources and more.
www.swgalaxies.net For all your Star Wars Galaxies needs
The Massassi A SW Galaxies Player Association
2002-02-04, 1:17 PM #7
It is still skipping the first camera for some reaon. Anybody have any ideas?
"Intelligent people know of what they speak; fools speak of what they know."

- Minchas Shabbos Pirkei Avos 3:18 / Ethics Of The Fathers
2002-02-04, 8:11 PM #8
As I attempted to explain in my previous post, there is a very specific reason it is skipping the first camera:

IF you dont have your frames set up properly, it will skip the first camera sequence.

I will now attempt to explain the correct use of frames.

This assumes you are using JED.

 

Add your ship.

Open the item editor for the ship. [Enter]

Click on 'Add value'.

Leave it as "Thingflags", and press Enter.

Click on 'Add value' again.

Change it to 'Numframes'.

Now, insert '2' into that new field.

(So, it should now have a 'Numframes | 2' at the bottom...)

Click on 'Add value'.

Change it to 'Frame'.

Click on 'Add value' again.

Change it to 'Frame'.


(Now, you should have 4 new values in the editor, "Thingflags, Numframes, Frame, Frame". If you dont, redo the previous steps.)


NOW, the fun part.


Move your ship to the position it should be when the cutscene ends.

Go to the item editor for your ship.

Click on 'Copy as frame'.

Move the ship to it's starting position.

Click on the SECOND 'Frame', in the item editor.

Press 'Ctrl + V', or Right-click and select 'Paste'.

(You should see a string of numbers appear, if nothing, redo the last few steps.)

Click on 'Copy as frame'.

Click on the FIRST 'Frame'.

Press 'Ctrl + V', or Right-click and select 'Paste'.

Press Enter.

Load the cog editor, and the cutscene cog, and ensure that the 'Ship_targetframe' variable is set to 1.

Test the level.


If you follow these instructions carefully, it should work.


Good luck..

------------------
Success is the inverse relationship between effort, gain, and loss.

[This message has been edited by GBK (edited February 04, 2002).]
And when the moment is right, I'm gonna fly a kite.
2002-02-05, 3:46 PM #9
Thanks, GBK, it worked! Now I'm finally starting to get cogs.

Well, that's all folks! [http://forums.massassi.net/html/wink.gif]
"Intelligent people know of what they speak; fools speak of what they know."

- Minchas Shabbos Pirkei Avos 3:18 / Ethics Of The Fathers

↑ Up to the top!