Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

how to make an object jump in unity

Rigidbody rb;
float force = 10f;

void Awake(){
  rb = GetComponent<Rigidbody>();
}

void Update(){
   if(Input.GetKeyDown(KeyCode.Space)) {
      rb.AddForce(Vector3.up * force, ForceMode.Impulse);
   }
}
Comment

How to jump in Unity using physics 3D

Rigidbody.AddForce(Vector3 force);Copy
Comment

How to jump in Unity using physics

Rigidbody.AddForce(Vector3 force);Copied!
Comment

PREVIOUS NEXT
Code Example
Csharp :: administrative priviledge in c# 
Csharp :: sustituir un caracter de un string c# 
Csharp :: Advertisement code for unity 
Csharp :: c# query string builder 
Csharp :: unity find all scriptable objects of a type 
Csharp :: c# dictionary check if value exists 
Csharp :: c# enum get string value 
Csharp :: how to iterate string in c# 
Csharp :: unity gui button width 
Csharp :: c# press ctrl and alt 
Csharp :: get file upload file size in MB c# 
Csharp :: how to we put a link in button in a view in asp.net 
Csharp :: Get logged in user in ASP.Net 
Csharp :: asp net core dependency injection factory with parameters 
Csharp :: c# winforms datagridview bind to list 
Csharp :: check if list contains any empty element in c# 
Csharp :: datagridview column index 
Csharp :: sends keys enter selenium c# 
Csharp :: summernote dropdown plugin 
Csharp :: c# generate random string 
Csharp :: narcissistic 
Csharp :: c# HttpResponseMessage postResponse = client.PostAsync 
Csharp :: ex: c# last item in array 
Csharp :: triangle 
Csharp :: admob unity 
Csharp :: non null array length 
Csharp :: what does focusbale do in listview WPF 
Csharp :: c# predicate 
Csharp :: c# nunit assert.contains 
Csharp :: user (current login user) in viewcomponent 
ADD CONTENT
Topic
Content
Source link
Name
7+4 =