Forums Index >> Modding >> Camera Switcher



Page : <1> :


Hello,

I read this thread about the BrainCam and decided to spruce it up a bit. I used the information from Scuminator, Cyber and Nathan's name toggler.

Put this in a file called camswitcher.cs in the game/server/scripts folder

 

 

//Camera Switcher script by Erik "Ekker" Ruud

Function BirdCam(%val)

{

If(%val)

{

DefaultTankCamera.camFocusDist = 20.0;

DefaultTankCamera.camFocusUpDist = 1.4;

DefaultTankCamera.camBackupDist = 0.0;

DefaultTankCamera.camFloatHeight = 50;

DefaultTankCamera.camSmooth = 0.0;

DefaultTankCamera.camSmoothTurn = 0.2;

DefaultTankCamera.camSmoothUp = 2;

DefaultTankCamera.camNear = 0.5;

}

}

MoveMap.bind(keyboard,"ctrl z",BirdCam);

Function BrainCam(%val)

{

If(%val)

{

DefaultTankCamera.camFocusDist = 20.0;

DefaultTankCamera.camFocusUpDist = 1.4;

DefaultTankCamera.camBackupDist = 0.0;

DefaultTankCamera.camFloatHeight = 2.5;

DefaultTankCamera.camSmooth = 0.0;

DefaultTankCamera.camSmoothTurn = 0.2;

DefaultTankCamera.camSmoothUp = 0.2;

DefaultTankCamera.camNear = 0.5;

}

}

MoveMap.bind(keyboard,"ctrl x",BrainCam);

Function NormalCam(%val)

{

If(%val)

{

DefaultTankCamera.camFocusDist = 10.1;

DefaultTankCamera.camFocusUpDist = 0.9;

DefaultTankCamera.camBackupDist = 6.2;

DefaultTankCamera.camFloatHeight = 6.22;

DefaultTankCamera.camSmooth = 0.33;

DefaultTankCamera.camSmoothTurn = 0.77;

DefaultTankCamera.camSmoothUp = 0.75;

DefaultTankCamera.camNear = 0.5;

}

}

MoveMap.bind(keyboard,"ctrl c",NormalCam);

Function BackCam(%val)

{

If(%val)

{

DefaultTankCamera.camFocusDist = -10.1;

DefaultTankCamera.camFocusUpDist = 0.9;

DefaultTankCamera.camBackupDist = -6.2;

DefaultTankCamera.camFloatHeight = 6.22;

DefaultTankCamera.camSmooth = 0.33;

DefaultTankCamera.camSmoothTurn = 0.77;

DefaultTankCamera.camSmoothUp = 0.75;

DefaultTankCamera.camNear = 0.5;

}

}

MoveMap.bind(keyboard,"ctrl v",BackCam);

 

 

And then add this line to the end of your.mis file to use it.

 

 

Exec("game/server/scripts/camswitcher.cs");

 

 

Bird's Eye Cam (Ctrl-z)

Brain Cam (Ctrl-x)

Reverse Cam (Ctrl-v)

Ctrl-c to return to the normal camera view.

 

Last edited: Tuesday, May 18, 2004 at 3:38:09 PM

Tuesday, May 18, 2004 at 3:30:21 PM

Huh, interesting. Ive never really wanted to play with that camera thing. Makes me dizzy :P ;)

Tuesday, May 18, 2004 at 4:49:28 PM

Great idea! Can't wait to give it a shot.

Tuesday, May 18, 2004 at 5:46:18 PM

Very nice! -z- should definetly add this to the Utilities! :)

 

Tuesday, May 18, 2004 at 6:02:34 PM

I've tested it in solo play and it works well.

I have not tried it on-line yet, I'm not sure if it would affect other player if it is in a mission.

Tuesday, May 18, 2004 at 6:07:33 PM

It's client-side only, so it won't affect anyone but the person using it. And yes, it works very well in online mode!

Great job on a cool script! :)

 

Tuesday, May 18, 2004 at 6:09:15 PM

Nice work.

Tuesday, May 18, 2004 at 6:53:08 PM

Don't u put this line...

 

Exec("game/server/scripts/camswitcher.cs");

 

In the main.cs file?

And good job, and how did u figure that out?

 

Tuesday, May 18, 2004 at 8:04:15 PM

All he did was bind the cameras with a few keys, not hard. But he is the first one to think of it. :)

Tuesday, May 18, 2004 at 8:09:49 PM

Yes, I am having the same problem.

Tuesday, May 18, 2004 at 10:55:21 PM

That is odd, I will have to check it out.

Does your script actually have all those a's in it?

It should have %val

This script was not hard to come up with. As I stated at the beginning, I tooks parts of two other mods and put them together.

I did try putting it in main.cs, but then I get errors when starting a dedicated server. Apparently the server side does not understand MoveMap.bind

Tuesday, May 18, 2004 at 11:23:45 PM

I can't get this to work! I'v tried everything. This is what I did:

Step 1: I copied one of the.cs files in to the same folder.

Step 2: I renamed it to camswitcher.cs

Step 3: I deleted everthing in it.

Step 4: copied and pasted every thing in the file abouve.

Step 5: Put Exec("game/server/scripts/camswitcher.cs"); at the bottom of all of my.mis files (bottom meaning I'v tried both abouve and below object right end).

Step 6: I GET MAD BECAUSE IT DOESN"T WORK AAAAA!

I'm glad io get that out. I'v tried in my one mod and in a normal map and neather worked. HELP!

Tuesday, May 18, 2004 at 11:57:56 PM

I copied from the post and the camswitcher.cs file looks just like the text in the post. I used the same method as bomber (above). Something about that (%val) doesn't work.

Wednesday, May 19, 2004 at 12:35:30 AM

It works for me in Solo play.

I can't seem to get it to work in On-Line mode though.

I'll keep playing with it.

The exec line can go in the main.cs instead of the.mis files.

Wednesday, May 19, 2004 at 1:36:24 AM

Here is a zip file with my camswitcher.cs in it.

I have come to realise that this board like to capitalize when You cut and paste into a reply.

That is why I could not get some of the particle emitter mods to work, and it is probably messing up some the people that tried my camswitcher as well.

The moveMap, function and if statements should have all started with lowercase letters.

Last edited: Wednesday, May 19, 2004 at 5:59:24 PM

Wednesday, May 19, 2004 at 5:58:13 PM

OK. It works now! Thanks. I found myself crouching down in the jar view.

Wednesday, May 19, 2004 at 6:40:52 PM

Good job ekker, glad to know my name toggler helped you out some, and keep up the good job! I may create more scripts soon...

Ekker, would you mind if I made more camera angles for this, and told people how to add them? I could release a "camera pak" :)

Last edited: Wednesday, May 19, 2004 at 7:32:15 PM

Wednesday, May 19, 2004 at 7:28:55 PM

So all the first letters of every line r supposed to be lowercased?

Wednesday, May 19, 2004 at 7:33:18 PM

@ Nathan

That would be cool (if it's all right with Ekker). It should be I hope :).

Wednesday, May 19, 2004 at 10:03:30 PM

Nathan,

I have the NameToggler installed as well. Feel free to do what you want with the camswitcher, I'm not keeping any secrets.

What would be really cool is get the brain cam to track with the gun barrel.

 

Thursday, May 20, 2004 at 12:10:58 AM

Zoon,

The words 'if' 'moveMap' and 'function' should all start with lowercase letters. The DefaultTankCamera should start with uppercase.

Download the zip file and use that.

Last edited: Thursday, May 20, 2004 at 12:13:44 AM

Thursday, May 20, 2004 at 12:12:29 AM

Hey Ecker,

Works great on my Mac. Thank you!

Do you have any suggestions to get it to work with online games too?

-Reagent X

 

 

-Rx

 

 

Thursday, May 20, 2004 at 12:47:40 AM

Yay its great. I got it to work now that I download that file. Thanks :P.

Thursday, May 20, 2004 at 2:18:56 AM

I'm am trying to see what I can do about online games.

Keep in mind that I only downloaded the demo version om May 14, 2004 and I purchased the game on the 17th. So I am not an expert at this yet.

Thursday, May 20, 2004 at 2:48:11 AM

Ok, I did some research during lunch, and I think I have the solution.

I'm at work now so, I can't test it online until I get home tonight.

I believe that the old script was actually changing the servers camera during on-line play. Since no one sees the servers camera view, nothing appeared to happen. The server need to tell the individual client to change it's camera settings during on-line play. The odd part is that the client has to tell the server to tell the client. :S

Thursday, May 20, 2004 at 3:32:16 PM

I mapped the buttons to different locations; Bird Cam is now Num 1, brain cam is num 2 ect...

Thursday, May 20, 2004 at 5:49:58 PM

You can map them to whatever keys you want. :)

I picked z, x, c & v because it would be easy to remember what they were.

Thursday, May 20, 2004 at 5:56:09 PM

My game wont load it, cuz u said I cud put this line..

 

Exec("game/client/scripts/camswitcher.cs");

 

In the.mis file, but each time a launch a dedicated server for my Zoon's scrum server it doesn't load it, I dunno wut wrong

 

Thursday, May 20, 2004 at 6:17:17 PM

Put it in the main file. It works that way and you don't have to put it in every one of your.mis files!

Thursday, May 20, 2004 at 8:29:03 PM

Change the Uppercase 'E' in exec to lower case.

Thursday, May 20, 2004 at 10:08:28 PM

Wait, I just re-read your post.

The camswitcher does not work on dedicated servers.

At this point it only works in Solo and Target Practice.

I am still trying to figure out how to get it to work in on-line play.

Last night's experiment did not work. :'(

Last edited: Friday, May 21, 2004 at 11:34:23 AM

Friday, May 21, 2004 at 11:33:52 AM

Hey Ekker,

Any luck getting this to work with a dedicated server? That would be sooooo cool!

Any ideas anyone?

-Rx

 

 

-Rx

 

 

Tuesday, November 09, 2004 at 3:18:43 AM

I know, that would rock.

Hmmmm... Idea....

Tuesday, November 09, 2004 at 11:56:53 AM

I think Ekker is dead...don't expect a reply anytime soon.

 

Tuesday, November 09, 2004 at 10:40:19 PM

Ok we'r losing racer AGAIN!!!!!! EVERYONE GET SOME COLD WATER!!!!!

Wednesday, November 10, 2004 at 9:00:12 PM

Omg... Now I cn switch to birdcam and print out the map and draw objects on it and actually plan ahead for a change!!! Uh oh... Now I HAVE TO PLAN AHEAD!!! AAAHHH!!! :'(
... OK ITS SERIOUS MODDING TIME!!! D16, YOU'RE FIRST!!! MUAHAHAHAHA!
[~Sasuke~]

Monday, November 15, 2004 at 5:58:50 PM

Btw nathan, I use nametoggler too. Although it causes more trouble than not sometimes...

Monday, November 15, 2004 at 6:00:21 PM

Um I have two copies of TT one is a normal one and one is a moded one and I usually go on the normal one so I would like to no HOW SHOULD I DO THIS!?!?!?!?! Because my.mis file is in the moded one!?!?!?!?!?!?!? IM GONNA GO CRAZY

Tuesday, November 23, 2004 at 6:54:25 AM

Actaully can someone just make me a birds eye cam that works in all servers?please?
zolt

Tuesday, November 23, 2004 at 10:50:04 AM

Wait guys take a moment to compair the codes from one thread to the other I mean they r the EXACT same code and most numbers r the same but anyway good work

Tuesday, November 23, 2004 at 10:53:02 AM

Nope, I'm not dead, just busy with other things.

Wednesday, February 02, 2005 at 1:00:34 PM

Page : <1> :

insert quote insert url insert email insert image bold italic underline superscript subscript horizontal rule : : Help on using forum codes

Add comment:

HTML is disabled within comments, but ZBB Code is enabled.

Back to the top

Web site designed, maintained and funded by -z- and Dan MacDonald