void uLink_OnNetworkInstantiate(uLink.NetworkMessageInfo info)
 {
     int ownerViewId = info.networkView.initialData.Read<int>();
     uLink.NetworkView slingshotNetworkView = uLink.NetworkView.Find(new uLink.NetworkViewID(ownerViewId));
     slingshot = slingshotNetworkView.GetComponentInChildren<SlingshotProxy>();
     slingshot.SetProjectile(this);
     smoothRigidbody = GetComponent<uLinkSmoothRigidbodyImproved>();
     disablePhysics();
     transform.parent = slingshot.transform;
     transform.position = slingshot.transform.position;
 }
Exemple #2
0
    void uLink_OnNetworkInstantiate(uLink.NetworkMessageInfo info)
    {
        int ownerViewId = info.networkView.initialData.Read <int>();

        uLink.NetworkView slingshotNetworkView = uLink.NetworkView.Find(new uLink.NetworkViewID(ownerViewId));
        slingshot = slingshotNetworkView.GetComponentInChildren <SlingshotProxy>();
        slingshot.SetProjectile(this);
        smoothRigidbody = GetComponent <uLinkSmoothRigidbodyImproved>();
        disablePhysics();
        transform.parent   = slingshot.transform;
        transform.position = slingshot.transform.position;
    }
 private void getSlingshot()
 {
     slingshot = GetComponentInChildren<SlingshotProxy>();
 }
 private void getSlingshot()
 {
     slingshot = GetComponentInChildren <SlingshotProxy>();
 }