A Simple 3rd Person Rpg Camera Template NOTE: Camera Collision on page 2

So. I was making a camera set-up for my game “Starlit”, and I manage to have a pretty decent camera. So without further or do. Here’s the features.
>Mouse-controlled (via the mouse look script) *with no limits
>A decent Minimap. :slight_smile:
>Camera Scrolling
>Simple Dialog System

But it’s not as perfect as it seems. I has some minor issues:
>The player is slightly twitching when rotating.
>The Minimap only works at the given camera size.
>It has no camera collision.
>No Suspend scene when having dialog.

Here you go. If you ever find this useful. Or if ever this helps your camera set up. A simple thank you is enough. :slight_smile:

Dialog Instructions:
Go to the small cube.
Press spacebar when near it.
Press spacebar again to go to the next page.

PS: It is not entirely mine. I just made a decent camera set up for my game and wanted to share it. :slight_smile:


3rdPersonCamera.blend (775 KB)

Here’s the blend for Camera Collision:


3rdPersonCamera.blend (444 KB)

Well, I like it. Which pieces are from other people?

I did notice a couple of issues, and also made a few changes to make it easier for me to see what was going on.

  • The left/right strafe was reversed, turns out the motion actuators had the wrong signs on the values. Easy fix.
  • I noticed the player didn’t rotate to follow the view while moving. Switched on Positive Pulse mode to fix it.

The rest is just my personal preference:

  • Changed player to red, added a material to the ground
  • Turned on GLSL and added a spotlight w/ shadow
  • Increased the sensitivity of the MouseLook script

Oh, and an issue with the viewport/minimap- if the game window isn’t full screen, the map sort of hangs off the side. If the view isn’t zoomed in so that the edges of the camera’s view are outside the window, it ends up looking sort of weird. I’d bet it’s the hard-coded window values in the script, maybe find a way to just calculate out a point from the bottom right corner? Like get the window height/width, divide by four or whatever amount of the screen you want, then subtract that from the window h/w to get the top and left edges (I think, something like that)

Like I said, I like it. Just needs some adjustments.

Well. I fixed the reversed strafe motion. And I did actually made the camera go free view without the character rotating with it. Because it would be awkward in games if the player kept on rotating with the camera. I can’t get my minimap to be correct so I just made it in the left corner of the screen. :slight_smile:

Patience is a great quality!

Another issue?..the camera/view turns around the character in Z axis…not cool!

Thank you anyway!

@OTO What seems to be the problem? What kind of rotation do you want?

This is really cool, it’s simple and effective. Nice one! :smiley:

Thank you krystof for the compliment! :slight_smile:

Actually, what I was referring to was if you move while rotating the camera, the player would still face whatever direction they started moving from. With the pulse mode on, the player auto-faces the camera direction, but only while a movement key is pressed. Try it out, hold WAS or D and move the mouse.

EDIT: And for me the map is in the bottom right.

And me, I was saying that the camera/view goes under the ground…

OTO, he did say in the original post that there wasn’t any camera collision at the moment. Tho I guess the “cap” setting in the mouselook script could be used to keep it over the ground plane.

I just updated it. Hopefully, the minimap should be more in line. And the rotation of the player should follow the camera. I still don’t have any knowledge on camera collision, do anyone mind helping me?

Hi, I just updated the template with the dialog system I just wrote a while ago. (with the help of leonnn)
Go to the small cube.
Press spacebar when near it.
Press spacebar again to go to the next page.

Here you go! :slight_smile:


3rdPersonCamera.blend (704 KB)

»thank you«

Mission accomplished!
What a cute cube’s Dialog. :3

Thank you

—> Yey :slight_smile:

what’s my new Quest ? :slight_smile:

Thanks bro!! this is really usefull.

Thank you everyone!

Thanks for the share.
it would be nice to see few improvements also, like a fully rigged char with a walk-cycle?

Maybe I’ll add my default anime character to the template. You think it would work?

sure it will.
Also it doesnt quite need to be your character you’re using on your character. Amakehuman character should be a good dummy character for this template imo.
Talking about char you should do a video tutorial aswell when you finish it. I cant see several such posts for some reason. So anyway you’re doing just fine and keep it up.