# How to make planet walker camera ?

like this camera

If you are talking about the movement of the block on the mesh, try the script by me that is in the last comment in this question:

As for the camera movement, it looks like a standard SmoothFollow script. If you do Assets > Import Package > Scripts, you will get this script.

In the comments section of this video the creator visioneleven says:

The script is very simple. I just rotate the﻿ whole world with key arrows. All the yellow enemys are rigidbodys with gravity disabled. I
did the gravity with these single line of code:

``````object.rigidbody.velocity += (centerax.transform.position - object.transform.position).nor­malized * 10 * Time.deltaTime;
``````

Centerax is the center of the planet…

Also this skript could help for a body-to-body gravity: http://wiki.unity3d.com/index.php?title=Gravity

You could try the script posted in the question Walking On Walls - it uses a rigidbody character that can walk over any surface, even upside down.

using UnityEngine;
using System.Collections;

``````public class mooove : MonoBehaviour {
public float moveSpeed = 0.1f;
public float turnSmoothing = 15f;
// Use this for initialization
void Start () {

}

// Update is called once per frame
void FixedUpdate () {

float h = Input.GetAxis("Horizontal")* moveSpeed * Time.deltaTime;
//transform.position += transform.right * h;
float v = Input.GetAxis("Vertical")* moveSpeed * Time.deltaTime;
//transform.position += transform.forward * v;

MovementManagement(h,v);
if(h != 0f || v != 0f)
{
transform.position += transform.right * .05f;
}

}

void MovementManagement (float horizontal, float vertical)
{

// If there is some axis input...
if(horizontal != 0f || vertical != 0f)
{

// ... set the players rotation and set the speed parameter to 5.5f.
Rotating(horizontal, vertical);

//Vector3 targetDirection1 = new Vector3(horizontal, 0f, vertical);

}
}

void Rotating (float horizontal, float vertical)
{
// Create a new vector of the horizontal and vertical inputs.
Vector3 targetDirection = new Vector3(horizontal, 0f, vertical);
//transform.position += transform.TransformDirection(targetDirection);

// Create a rotation based on this new vector assuming that up is the global y axis.
Quaternion targetRotation = Quaternion.LookRotation(targetDirection, Vector3.up);

// Create a rotation that is an increment closer to the target rotation from the player's rotation.
Quaternion newRotation = Quaternion.Lerp(rigidbody.rotation, targetRotation, turnSmoothing * Time.deltaTime);

// Change the players rotation to this new rotation.
rigidbody.MoveRotation(newRotation);

}

}
``````