Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How can I stop the camera from following the character on trigger?

I'm trying to find a way to constrain the camera of my side scroller to the top and bottom of my level, but let the character keep moving until it hits the top or bottom of the level.

Any thoughts on how to achieve this? I'm using the side scroller template as a prototype.

Product Version: Not Selected
more ▼

asked Oct 14 '14 at 05:10 PM in Using UE4

avatar image

161 12 21 31

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

You probably want to remove the spring-arm and setup the required tracking logic yourself. Ie you will want manually set the camera's relative location.

Assuming that your pawn moves in X(left-right) and Z (up-down)axes, what you need to do is within each tick, set the camera's relative location = (0, [constant value], [calculated value]).

In this case the [constant value] determines how far the camera is from your pawn. [calculated value] is where the trick is. First you must identify the vertical center for your map. This is where the camera should stay. When you pawn moves up or down, you find how much higher or lower from this baseline your pawn is at. Neggate that value and that should be your [calculated_value].

try this and let me know.

more ▼

answered Oct 15 '14 at 06:37 AM

avatar image

3.4k 154 52 272

avatar image MrMastermindNL Oct 15 '14 at 07:03 AM

Thanks for the info! I will give that a try and let you know how I did.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question