![Negin Soltani](/assets/img/avatar_default.png)
- Globe Asset - Spatial Anchors - Photon Implementation - Scripts for Globe Control and Initial Country Colorizing - Script for Reading csv file
22 lines
379 B
C#
22 lines
379 B
C#
using UnityEngine;
|
|
using System.Text;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
|
|
namespace WPM {
|
|
public class SpherePingPong : MonoBehaviour {
|
|
|
|
Vector3 origPosition;
|
|
|
|
void Awake () {
|
|
origPosition = transform.position;
|
|
}
|
|
|
|
void Update () {
|
|
float t = (Mathf.Sin (Time.time) + 1f) * 0.2f;
|
|
transform.position = origPosition * (0.8f + t);
|
|
}
|
|
|
|
}
|
|
|
|
} |