[private void launchLeftRope(RaycastHit hit, bool single, int mode = 0)
{
if (this.currentGas != 0f)
{
this.useGas(0f);
if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
{
this.bulletLeft = (GameObject) Object.Instantiate(Resources.Load("hook"));
}
else if (base.photonView.isMine)
{
this.bulletLeft = PhotonNetwork.Instantiate("hook", base.transform.position, base.transform.rotation, 0);
}
GameObject obj2 = !this.useGun ? this.hookRefL1 : this.hookRefL2;
string str = !this.useGun ? "hookRefL1" : "hookRefL2";
this.bulletLeft.transform.position = obj2.transform.position;
Bullet component = this.bulletLeft.GetComponent<Bullet>();
float num = !single ? ((hit.distance <= 50f) ? (hit.distance * 0.05f) : (hit.distance * 0.3f)) : 0f;
Vector3 vector = (hit.point - ((Vector3) (base.transform.right * num))) - this.bulletLeft.transform.position;
vector.Normalize();
if (mode == 1)
{
component.launch((Vector3) (vector * 3f), base.rigidbody.velocity, str, true, base.gameObject, true);
}
else
{
component.launch((Vector3) (vector * 3f), base.rigidbody.velocity, str, true, base.gameObject, false);
}
this.launchPointLeft = Vector3.zero;
}
}
private void launchLeftRope(RaycastHit hit, bool single, int mode = 0)
{
if (this.currentGas != 0f)
{
this.useGas(0f);
if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
{
this.bulletLeft = (GameObject) Object.Instantiate(Resources.Load("hook"));
}
else if (base.photonView.isMine)
{
this.bulletLeft = PhotonNetwork.Instantiate("hook", base.transform.position, base.transform.rotation, 0);
}
GameObject obj2 = !this.useGun ? this.hookRefL1 : this.hookRefL2;
string str = !this.useGun ? "hookRefL1" : "hookRefL2";
this.bulletLeft.transform.position = obj2.transform.position;
Bullet component = this.bulletLeft.GetComponent<Bullet>();
float num = !single ? ((hit.distance <= 50f) ? (hit.distance * 0.05f) : (hit.distance * 0.3f)) : 0f;
Vector3 vector = (hit.point - ((Vector3) (base.transform.right * num))) - this.bulletLeft.transform.position;
vector.Normalize();
if (mode == 1)
{
component.launch((Vector3) (vector * 3f), base.rigidbody.velocity, str, true, base.gameObject, true);
}
else
{
component.launch((Vector3) (vector * 3f), base.rigidbody.velocity, str, true, base.gameObject, false);
}
this.launchPointLeft = Vector3.zero;
}
}