This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using UnityEngine; | |
using UnityEngine.EventSystems; | |
using UnityEngine.Events; | |
public class TeleportEvent : UnityEvent<Vector3> | |
{ | |
} | |
public class SDKBoyTeleportController : MonoBehaviour { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class PlayerController : MonoBehaviour { | |
public GameObject gvrControllerPointer; | |
public GameObject head; | |
public GameObject otherPlayersController; | |
public GameObject playerCamera; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using UnityEngine.UI; | |
using Photon; | |
public class PhotonCommsManager : Photon.PunBehaviour { | |
private GameObject currentPlayer; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class NetworkPlayer : Photon.MonoBehaviour { | |
public GameObject otherPlayerController; | |
public GameObject playerController; | |
public GameObject otherPlayerHead; | |
public Camera playerCamera; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine.Events; | |
using System.Collections; | |
using System.Collections.Generic; | |
/* | |
Unity C# Event manager using UnityEvents and a Hashtable for loosely typed params with event. | |
This EventManager expands the usefulness of UnityEvents by allowing values of any type to be passed as a | |
parameter in the Event eg: int, string, Vector3 etc. | |
Usage: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.UI; | |
public class PlayerController : MonoBehaviour { | |
void Update () { | |
if (GvrController.ClickButtonUp) { | |
GvrLaserPointerImpl laserPointerImpl = (GvrLaserPointerImpl)GvrPointerManager.Pointer; | |
if (laserPointerImpl.IsPointerIntersecting) { | |
gameObject.transform.position = new Vector3(laserPointerImpl.PointerIntersection.x, gameObject.transform.position.y, laserPointerImpl.PointerIntersection.z); |