PlaceholderGames / 2ndYearHelpDesk

Where the important help requests and general questions get asked by CS2S561 students
0 stars 1 forks source link

Creating 3rd Person Zoom Control in Unreal Engine. #5

Closed AdamScott121 closed 6 years ago

AdamScott121 commented 7 years ago

How To Create 3rd Person Camera Zoom Control in Unreal Engine: How do I allow my 3rd person game's camera to be able to zoom in and out? Well look no further! Simply copy the blueprint code blocks as seen below and you will be good to go!

unreal zoom code

A few notes: 1: What is that box with the plus sign in it called? Simply right click in the event graph window and search for "Plus" and look for the item called "x + x" <--- this case "Float + Float" same for the other one which is "Minus" (Float - Float).

2: The camera must be attached to the spring arm component in order for this code to work as shown in the image above.

3: What is "Clamp(Float)"? In short this allows us to limit how far in and out the camera can zoom. Without the camera can zoom in or out forever... By "clamping" the values we are saying "This far and no further!" (Anyone who got the Star Trek reference.. +1 Cookie)

4: Any other questions comment below! :D

DoctorMikeReddy commented 7 years ago

:-)

ghost commented 7 years ago

thanks for sharing adam. Is it still a requirement for us to make a 3rd person game or did Mike say we can do first person due to the placeholder module

AdamScott121 commented 7 years ago

I think that requirement was waived due to the lack of cooperation with other disciplines this year. For my teams game, we've added 1st and 3rd person perspectives to the game.

DoctorMikeReddy commented 6 years ago

Old now