Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class FauxGravityBodys : MonoBehaviour
public FauxGravityAttractor attractor;
private Transform myTransform;
Rigidbody rb;
void Start()
rb = GetComponent<Rigidbody>();
rb.constraints = RigidbodyConstraints.FreezeRotation;
rb.useGravity = false;
myTransform = transform;
void Update()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment