Sunday 5 April 2015

Unity3D Tutorial Uplifting !

Unity3D Tutorial Uplifting !

Easter video series !







DIRECT DOWNLOAD HERE




THIS IS BACKUP  IN TEXT FORM  TUTORIAL Uplifting !

1. Create New C# and name it : liftup


2. Copy & Past this text and save liftup :
----------------------------------------­­­­­------------------------------------­-­-­-­-­-


using UnityEngine;

// :) up up you goo
[RequireComponent(typeof(BoxCollider))]
public class liftup : MonoBehaviour 
{
public float lift; //the lifting force applied to player :)
void Awake()
{
collider.isTrigger = true;
}
// lol
//also lift player upwards
void OnTriggerStay(Collider other)
{
if(other.rigidbody)
other.rigidbody.AddForce(Vector3.up * lift, ForceMode.Force);
 }
    }







 ----------------------------------------­­­­­------------------------------------­-­-­-­-­-

1 comment: