Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

hwo to prevent rotation after hitting an object in unity

private void OnCollisionEnter(Collision collision)
{
	GetComponent<RigidBody>().freezeRotation = true;
}
Comment

PREVIOUS NEXT
Code Example
Csharp :: checking if a list contains a value unity 
Csharp :: how to print something in c# 
Csharp :: textblock line break 
Csharp :: increase value in dictionary against a key in c# 
Csharp :: c# remove all punctuation from string 
Csharp :: c# quit button script 
Csharp :: datetime month name 
Csharp :: how to validate if date is a weekday or weekend c# 
Csharp :: vb.net add row to datagridview programmatically 
Csharp :: unity get gameobject from hit 
Csharp :: asp.net response.redirect new tab 
Csharp :: c# delete files in directory and subdirectories 
Csharp :: linq when name then orderby 
Csharp :: check if value in list c# 
Csharp :: c# how to crete array 
Csharp :: random mac address c# 
Csharp :: map user to ConnectionId SignalR 
Csharp :: unity game object remove parent 
Csharp :: switch case with 2 variables c# 
Csharp :: System.Drawing get from url 
Csharp :: how to set the value of a textbox textmode=date asp.net c# 
Csharp :: how set cascade on delete and update in same time in laravel 
Csharp :: how to use curl in asp.net c# 
Csharp :: set text in unity invisible 
Csharp :: unity scroll rect to bottom 
Csharp :: Scrollable WPF ListBox 
Csharp :: delay activity in uipath 
Csharp :: change size of button c# 
Csharp :: how to decrease velocity of a Unity rigidbody 
Csharp :: unity check if gameobject is inside collider 
ADD CONTENT
Topic
Content
Source link
Name
1+3 =