• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges

Mathf.clamp

Cancel

Cancel

All Questions

  • Unanswered Questions
avatar image

Spacejet13 answered

Not able to clamp camera rotation

Aug 7, '18 c#·fps controller·mathf.clamp·camera rotation·clamped rotation

1 Reply

0 Votes

avatar image

cjtouhey edited

My accelerate script ramps up in the inspector but no movement.

Jun 14, '18 movement·rigidbody·velocity·mathf.clamp

0 Replies

0 Votes

avatar image

EvanCheddar commented

My player shakes when Mathf.Clamp stops it from going off screen.

May 19, '18 player·player movement·mathf·mathf.clamp·shaking

1 Reply

0 Votes

avatar image

TreyH commented

Cant Clamp

May 7, '18 c#·timer·clamp·timer countdown·mathf.clamp

1 Reply

0 Votes

avatar image

maxdragonpc asked

Please help me! Correct script) ,

Apr 18, '18 in Help Room

0 Replies

0 Votes

avatar image

LinkUpGames asked

Help with Clamping X Rotation

Apr 9, '18 c#·rotatearound·mathf.clamp

0 Replies

0 Votes

avatar image

meat5000 commented

I'm having trouble clamping the rotation of the camera? Closed

Apr 1, '18 rotation·quaternion·mathf.clamp·first-person

0 Replies

0 Votes

avatar image

22ecvvw edited

Mathf.Clamp() Not working, one corner only.

Mar 24, '18 in Help Room

0 Replies

0 Votes

avatar image

unity_S0ZCLiVP1XXH-w answered

Need help with limited movement with mathf clamp Closed

Feb 10, '18 in Help Room

2 Replies

0 Votes

avatar image

pako commented

problem with mathf.clamp

Dec 23, '17 mathf.clamp

0 Replies

0 Votes

avatar image

games504 commented

helps to adapt the Mathf.Clamp in c #!

Dec 23, '17 mathf.clamp

1 Reply

0 Votes

avatar image

mathacka commented

So I'm trying to rotate an object from -35 degrees to 35 degrees, or rather 325 degrees to 35 degrees

Nov 18, '17 in Help Room

1 Reply

0 Votes

avatar image

JaredHD edited

Limiting rotation based on direction

Oct 29, '17 c#·quaternion·eulerangles·mathf.clamp·localrotation

0 Replies

0 Votes

avatar image

DevMerlin commented

Can rotation be clamped when X produces -30 for both negative and positive?

Sep 14, '17 rotation·transform·mathf.clamp

1 Reply

0 Votes

avatar image

Fermak commented

pixels per unit issues

Sep 6, '17 mathf.clamp·pixels

0 Replies

0 Votes

avatar image

Hoorza commented

How can I make sprite stay in viewport and point towards the game object it is attached to?

Nov 2, '17 in Help Room

1 Reply

0 Votes

avatar image

Wakaar edited

transform.position assign attempt for 'RCCMainCamera' is not valid. Input position is { NaN, NaN, NaN }. UnityEngine.Transform:set_position(Vector3)

Mar 24, '20 in Help Room

1 Reply

1 Votes

avatar image

myojin08 edited

how is mathf.clamp to be resolution independent according to the RectTransform rt which is my gamefield? bacause when im playing in other resolution clamp is changing.

Aug 1, '17 in Help Room

0 Replies

0 Votes

avatar image

Montreal edited

Save object position after drag?

Jul 26, '17 in Help Room

0 Replies

0 Votes

avatar image

StinkyDubeau commented

Raycast instantiation only sometimes working.

Jul 6, '17 in Help Room

1 Reply

0 Votes

avatar image

InsertNamehere asked

Using Mathf.Clamp To Limit Camera Movement

Jun 30, '17 camera·movement·limit·mathf.clamp·x-axis

0 Replies

0 Votes

avatar image

Jwizard93 commented

How to mathf.clamp a VR player?

Jun 28, '17 vr·sceneview·localposition·mathf.clamp

1 Reply

0 Votes

avatar image

RiotRews answered

Hey! I have problem with my FPS controller, where Mathf.Clamp doesn't work. Any ideas?

Jun 15, '17 in Help Room

1 Reply

0 Votes

avatar image

Shindy117 asked

Mathf.clamp cancels my trigger

Jun 4, '17 in Help Room

0 Replies

0 Votes

avatar image

CloudFs published

How to stop rigidbody from slowing down ?

May 20, '17 rigidbody·mathf.clamp·boundary·slowdown

0 Replies

0 Votes

avatar image

janus1001 commented

Limiting rotation in 2 axis'

Apr 28, '17 physics·transform.rotation·mathf.clamp·mathf.lerp·quaternion.slerp

1 Reply

0 Votes

avatar image

skylerkingdev published

Clamping local movement

Apr 24, '17 scripting problem·positioning·localposition·mathf.clamp

0 Replies

1 Votes

avatar image

Zac_Mountain commented

Random.Range producing values outside its range.

Apr 24, '17 in Help Room

1 Reply

0 Votes

avatar image

Namey5 commented

How can I use Mathf.Clamp?

Mar 18, '17 in Help Room

1 Reply

0 Votes

avatar image

Robert_s_a commented

I have a problem with mathf.clamp…how to use it to move left and right??

Mar 10, '17 in Help Room

2 Replies

0 Votes

  • ‹
  • 1
  • 2
  • 3
  • 4
  • 5
  • ›
  • »

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Related Topics

rotation c# clamp camera mathf movement quaternion rigidbody boundary scripting problem limit mathf.lerp 2d vector3 eulerangles transform.position transform axis unity 5 camera rotate math gameobject clamped rotation transform.rotation transform.rotate


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges