initial upload
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Back : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Camera CameraMenu;
|
||||
|
||||
public Camera CameraSettings;
|
||||
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
public Camera CameraCoop;
|
||||
|
||||
public Camera CameraVerses;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
CameraMenu.GetComponent<Camera>().enabled = true;
|
||||
CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fdbdf5a8e7f376f1909ee01050106297
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,37 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Backsettings : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Camera CameraMenu;
|
||||
|
||||
public Camera CameraSettings;
|
||||
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
public Camera CameraCoop;
|
||||
|
||||
public Camera CameraVerses;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
Transform transform = GameObject.FindWithTag("Settings").transform;
|
||||
UnityEngine.Object.Destroy(transform.gameObject);
|
||||
CameraMenu.GetComponent<Camera>().enabled = true;
|
||||
CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a0d3aedc6d8a8f2fc47eee7a33b9c990
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x02000002 RID: 2
|
||||
[Serializable]
|
||||
public class Begingame: MonoBehaviour
|
||||
{
|
||||
// Token: 0x06000002 RID: 2 RVA: 0x000020F4 File Offset: 0x000002F4
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown("e"))
|
||||
{
|
||||
Network.Destroy(this.gameObject);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06000003 RID: 3 RVA: 0x00002110 File Offset: 0x00000310
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d155aeebab21843d9d93ad1789eaf946
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Begin_0020game : MonoBehaviour
|
||||
{
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown("e"))
|
||||
{
|
||||
Network.Destroy(gameObject);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f8bba35b4b18ea4409614a7af9e4fa6c
|
||||
timeCreated: 1757101798
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,383 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Boo.Lang;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class ChangeTextures : MonoBehaviour
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024LoadCL_002415 : GenericGenerator<WWW>
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024 : GenericGeneratorEnumerator<WWW>, IEnumerator
|
||||
{
|
||||
internal GameObject _0024GOH_002416;
|
||||
|
||||
internal GameObject _0024GOH1_002417;
|
||||
|
||||
internal string _0024urlTT_002418;
|
||||
|
||||
internal WWW _0024downloadTT_002419;
|
||||
|
||||
internal GameObject _0024GOH2_002420;
|
||||
|
||||
internal string _0024urlTC_002421;
|
||||
|
||||
internal WWW _0024downloadTC_002422;
|
||||
|
||||
internal GameObject _0024GOH3_002423;
|
||||
|
||||
internal string _0024urlTCl_002424;
|
||||
|
||||
internal WWW _0024downloadTCl_002425;
|
||||
|
||||
internal GameObject _0024GOH4_002426;
|
||||
|
||||
internal GameObject _0024GOH45_002427;
|
||||
|
||||
internal GameObject _0024GOH46_002428;
|
||||
|
||||
internal string _0024urlTCA_002429;
|
||||
|
||||
internal WWW _0024downloadTCA_002430;
|
||||
|
||||
internal GameObject _0024GOH5_002431;
|
||||
|
||||
internal GameObject _0024GOH55_002432;
|
||||
|
||||
internal string _0024urlTCB_002433;
|
||||
|
||||
internal WWW _0024downloadTCB_002434;
|
||||
|
||||
internal string _0024ent_002435;
|
||||
|
||||
internal string _0024tT_002436;
|
||||
|
||||
internal string _0024tC_002437;
|
||||
|
||||
internal string _0024tCl_002438;
|
||||
|
||||
internal string _0024tCA_002439;
|
||||
|
||||
internal string _0024tCB_002440;
|
||||
|
||||
internal ChangeTextures _0024self__002441;
|
||||
|
||||
public _0024(string ent, string tT, string tC, string tCl, string tCA, string tCB, ChangeTextures self_)
|
||||
{
|
||||
_0024ent_002435 = ent;
|
||||
_0024tT_002436 = tT;
|
||||
_0024tC_002437 = tC;
|
||||
_0024tCl_002438 = tCl;
|
||||
_0024tCA_002439 = tCA;
|
||||
_0024tCB_002440 = tCB;
|
||||
_0024self__002441 = self_;
|
||||
}
|
||||
|
||||
public override bool MoveNext()
|
||||
{
|
||||
int result;
|
||||
switch (_state)
|
||||
{
|
||||
default:
|
||||
if (_0024self__002441.gameObject.GetComponent<NetworkView>().viewID.ToString().Remove(0, 13) == _0024ent_002435)
|
||||
{
|
||||
_0024GOH_002416 = GameObject.Find("multiplayertubby/default" + _0024ent_002435);
|
||||
_0024GOH1_002417 = GameObject.Find("multiplayertubby/headmesh" + _0024ent_002435);
|
||||
_0024urlTT_002418 = _0024tT_002436;
|
||||
_0024downloadTT_002419 = new WWW(_0024urlTT_002418);
|
||||
result = (Yield(2, _0024downloadTT_002419) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
goto IL_038e;
|
||||
case 2:
|
||||
_0024GOH_002416.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTT_002419.texture;
|
||||
_0024GOH1_002417.GetComponent<Renderer>().materials[1].mainTexture = _0024downloadTT_002419.texture;
|
||||
_0024GOH1_002417.GetComponent<Renderer>().materials[2].mainTexture = _0024downloadTT_002419.texture;
|
||||
_0024GOH2_002420 = GameObject.Find("multiplayertubby/headmesh" + _0024ent_002435);
|
||||
_0024urlTC_002421 = _0024tC_002437;
|
||||
_0024downloadTC_002422 = new WWW(_0024urlTC_002421);
|
||||
result = (Yield(3, _0024downloadTC_002422) ? 1 : 0);
|
||||
break;
|
||||
case 3:
|
||||
_0024GOH2_002420.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTC_002422.texture;
|
||||
_0024GOH3_002423 = GameObject.Find("multiplayertubby/Cylinder002" + _0024ent_002435);
|
||||
_0024urlTCl_002424 = _0024tCl_002438;
|
||||
_0024downloadTCl_002425 = new WWW(_0024urlTCl_002424);
|
||||
result = (Yield(4, _0024downloadTCl_002425) ? 1 : 0);
|
||||
break;
|
||||
case 4:
|
||||
_0024GOH3_002423.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTCl_002425.texture;
|
||||
_0024GOH4_002426 = GameObject.Find("multiplayertubby/rightarmmesh" + _0024ent_002435);
|
||||
_0024GOH45_002427 = GameObject.Find("multiplayertubby/leftarmmesh" + _0024ent_002435);
|
||||
_0024GOH46_002428 = GameObject.Find("multiplayertubby/headmesh" + _0024ent_002435);
|
||||
_0024urlTCA_002429 = _0024tCA_002439;
|
||||
_0024downloadTCA_002430 = new WWW(_0024urlTCA_002429);
|
||||
result = (Yield(5, _0024downloadTCA_002430) ? 1 : 0);
|
||||
break;
|
||||
case 5:
|
||||
_0024GOH4_002426.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTCA_002430.texture;
|
||||
_0024GOH45_002427.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTCA_002430.texture;
|
||||
_0024GOH46_002428.GetComponent<Renderer>().materials[2].mainTexture = _0024downloadTCA_002430.texture;
|
||||
_0024GOH5_002431 = GameObject.Find("multiplayertubby/rightlegmesh" + _0024ent_002435);
|
||||
_0024GOH55_002432 = GameObject.Find("multiplayertubby/leftlegmesh" + _0024ent_002435);
|
||||
_0024urlTCB_002433 = _0024tCB_002440;
|
||||
_0024downloadTCB_002434 = new WWW(_0024urlTCB_002433);
|
||||
result = (Yield(6, _0024downloadTCB_002434) ? 1 : 0);
|
||||
break;
|
||||
case 6:
|
||||
_0024GOH5_002431.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTCB_002434.texture;
|
||||
_0024GOH55_002432.GetComponent<Renderer>().materials[0].mainTexture = _0024downloadTCB_002434.texture;
|
||||
goto IL_038e;
|
||||
case 1:
|
||||
{
|
||||
result = 0;
|
||||
break;
|
||||
}
|
||||
IL_038e:
|
||||
YieldDefault(1);
|
||||
goto case 1;
|
||||
}
|
||||
return (byte)result != 0;
|
||||
}
|
||||
}
|
||||
|
||||
internal string _0024ent_002442;
|
||||
|
||||
internal string _0024tT_002443;
|
||||
|
||||
internal string _0024tC_002444;
|
||||
|
||||
internal string _0024tCl_002445;
|
||||
|
||||
internal string _0024tCA_002446;
|
||||
|
||||
internal string _0024tCB_002447;
|
||||
|
||||
internal ChangeTextures _0024self__002448;
|
||||
|
||||
public _0024LoadCL_002415(string ent, string tT, string tC, string tCl, string tCA, string tCB, ChangeTextures self_)
|
||||
{
|
||||
_0024ent_002442 = ent;
|
||||
_0024tT_002443 = tT;
|
||||
_0024tC_002444 = tC;
|
||||
_0024tCl_002445 = tCl;
|
||||
_0024tCA_002446 = tCA;
|
||||
_0024tCB_002447 = tCB;
|
||||
_0024self__002448 = self_;
|
||||
}
|
||||
|
||||
public override IEnumerator<WWW> GetEnumerator()
|
||||
{
|
||||
return new _0024(_0024ent_002442, _0024tT_002443, _0024tC_002444, _0024tCl_002445, _0024tCA_002446, _0024tCB_002447, _0024self__002448);
|
||||
}
|
||||
}
|
||||
|
||||
public string entID;
|
||||
|
||||
public int OneTime;
|
||||
|
||||
public bool renderize;
|
||||
|
||||
public Rect windowRect;
|
||||
|
||||
public bool hidedWindow;
|
||||
|
||||
public string addTextureBodyI;
|
||||
|
||||
public string addTextureHeadI;
|
||||
|
||||
public string addTextureHatI;
|
||||
|
||||
public string addTextureArmsI;
|
||||
|
||||
public string addTextureLegsI;
|
||||
|
||||
public string addTextureBody;
|
||||
|
||||
public string addTextureHead;
|
||||
|
||||
public string addTextureHat;
|
||||
|
||||
public string addTextureArms;
|
||||
|
||||
public string addTextureLegs;
|
||||
|
||||
public string titBut;
|
||||
|
||||
public ChangeTextures()
|
||||
{
|
||||
windowRect = new Rect(20f, 30f, 350f, 300f);
|
||||
hidedWindow = true;
|
||||
addTextureBodyI = "http://i48.tinypic.com/2eckyyq.png";
|
||||
addTextureHeadI = "http://i50.tinypic.com/eppws5.png";
|
||||
addTextureHatI = "http://i46.tinypic.com/28uoiz9.jpg";
|
||||
addTextureArmsI = "http://i48.tinypic.com/2eckyyq.png";
|
||||
addTextureLegsI = "http://i48.tinypic.com/2eckyyq.png";
|
||||
addTextureBody = " ";
|
||||
addTextureHead = " ";
|
||||
addTextureHat = " ";
|
||||
addTextureArms = " ";
|
||||
addTextureLegs = " ";
|
||||
titBut = "Accept/confirm";
|
||||
}
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
entID = gameObject.GetComponent<NetworkView>().viewID.ToString().Remove(0, 13);
|
||||
}
|
||||
|
||||
public virtual void showWindow()
|
||||
{
|
||||
renderize = true;
|
||||
}
|
||||
|
||||
public virtual void hideWindow()
|
||||
{
|
||||
renderize = false;
|
||||
}
|
||||
|
||||
public virtual void OnGUI()
|
||||
{
|
||||
GUI.depth = 1;
|
||||
if (OneTime == 0 && GetComponent<NetworkView>().isMine && GUI.Button(new Rect(10f, Screen.height - 30, 135f, 20f), titBut))
|
||||
{
|
||||
if (hidedWindow)
|
||||
{
|
||||
showWindow();
|
||||
hidedWindow = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
hideWindow();
|
||||
hidedWindow = true;
|
||||
Load();
|
||||
OneTime = 1;
|
||||
}
|
||||
}
|
||||
if (renderize)
|
||||
{
|
||||
windowRect = GUI.Window(1, windowRect, window1, "Character Customization");
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void window1(int windowID)
|
||||
{
|
||||
GUI.DragWindow(new Rect(0f, 0f, 120f, 20f));
|
||||
GUI.Label(new Rect(10f, 25f, 300f, 20f), "Body/Torso texture");
|
||||
if (GUI.Button(new Rect(50f, 50f, 50f, 20f), "Red"))
|
||||
{
|
||||
addTextureBodyI = "http://i45.tinypic.com/2ed77sm.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(100f, 50f, 60f, 20f), "Purple"))
|
||||
{
|
||||
addTextureBodyI = "http://i50.tinypic.com/2v927ue.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(160f, 50f, 60f, 20f), "Green"))
|
||||
{
|
||||
addTextureBodyI = "http://i47.tinypic.com/30de0w7.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(220f, 50f, 60f, 20f), "Yellow"))
|
||||
{
|
||||
addTextureBodyI = "http://i48.tinypic.com/1zdi51.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(280f, 50f, 60f, 20f), "White"))
|
||||
{
|
||||
addTextureBodyI = "http://i48.tinypic.com/2eckyyq.png ";
|
||||
}
|
||||
addTextureBodyI = GUI.TextField(new Rect(10f, 70f, 330f, 20f), addTextureBodyI);
|
||||
GUI.Label(new Rect(10f, 95f, 400f, 20f), "Head texture");
|
||||
if (GUI.Button(new Rect(50f, 120f, 50f, 20f), "Red"))
|
||||
{
|
||||
addTextureHeadI = "http://i48.tinypic.com/oibk8.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(100f, 120f, 60f, 20f), "Purple"))
|
||||
{
|
||||
addTextureHeadI = "http://i47.tinypic.com/sgsnl3.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(160f, 120f, 60f, 20f), "Green"))
|
||||
{
|
||||
addTextureHeadI = "http://i46.tinypic.com/2l95q9.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(220f, 120f, 60f, 20f), "Yellow"))
|
||||
{
|
||||
addTextureHeadI = "http://i45.tinypic.com/2qc1oxk.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(280f, 120f, 60f, 20f), "White"))
|
||||
{
|
||||
addTextureHeadI = "http://i50.tinypic.com/eppws5.png";
|
||||
}
|
||||
addTextureHeadI = GUI.TextField(new Rect(10f, 140f, 330f, 20f), addTextureHeadI);
|
||||
GUI.Label(new Rect(10f, 165f, 400f, 20f), "Hat texture");
|
||||
addTextureHatI = GUI.TextField(new Rect(10f, 190f, 330f, 20f), addTextureHatI);
|
||||
GUI.Label(new Rect(10f, 215f, 400f, 20f), "Arms texture");
|
||||
if (GUI.Button(new Rect(50f, 240f, 50f, 20f), "Red"))
|
||||
{
|
||||
addTextureArmsI = "http://i45.tinypic.com/2ed77sm.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(100f, 240f, 60f, 20f), "Purple"))
|
||||
{
|
||||
addTextureArmsI = "http://i50.tinypic.com/2v927ue.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(160f, 240f, 60f, 20f), "Green"))
|
||||
{
|
||||
addTextureArmsI = "http://i47.tinypic.com/30de0w7.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(220f, 240f, 60f, 20f), "Yellow"))
|
||||
{
|
||||
addTextureArmsI = "http://i48.tinypic.com/1zdi51.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(280f, 240f, 60f, 20f), "White"))
|
||||
{
|
||||
addTextureArmsI = "http://i48.tinypic.com/2eckyyq.png";
|
||||
}
|
||||
addTextureArmsI = GUI.TextField(new Rect(10f, 260f, 330f, 20f), addTextureArmsI);
|
||||
GUI.Label(new Rect(10f, 285f, 400f, 20f), "Legs texture");
|
||||
if (GUI.Button(new Rect(50f, 310f, 50f, 20f), "Red"))
|
||||
{
|
||||
addTextureLegsI = "http://i45.tinypic.com/2ed77sm.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(100f, 310f, 60f, 20f), "Purple"))
|
||||
{
|
||||
addTextureLegsI = "http://i50.tinypic.com/2v927ue.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(160f, 310f, 60f, 20f), "Green"))
|
||||
{
|
||||
addTextureLegsI = "http://i47.tinypic.com/30de0w7.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(220f, 310f, 60f, 20f), "Yellow"))
|
||||
{
|
||||
addTextureLegsI = "http://i48.tinypic.com/1zdi51.png";
|
||||
}
|
||||
if (GUI.Button(new Rect(280f, 310f, 60f, 20f), "White"))
|
||||
{
|
||||
addTextureLegsI = "http://i48.tinypic.com/2eckyyq.png";
|
||||
}
|
||||
addTextureLegsI = GUI.TextField(new Rect(10f, 330f, 330f, 20f), addTextureLegsI);
|
||||
}
|
||||
|
||||
public virtual void Load()
|
||||
{
|
||||
addTextureBody = addTextureBodyI;
|
||||
addTextureHead = addTextureHeadI;
|
||||
addTextureHat = addTextureHatI;
|
||||
addTextureArms = addTextureArmsI;
|
||||
addTextureLegs = addTextureLegsI;
|
||||
if (GetComponent<NetworkView>().isMine)
|
||||
{
|
||||
GetComponent<NetworkView>().RPC("LoadCL", RPCMode.AllBuffered, entID, addTextureBody, addTextureHead, addTextureHat, addTextureArms, addTextureLegs);
|
||||
}
|
||||
}
|
||||
|
||||
[RPC]
|
||||
public virtual IEnumerator LoadCL(string ent, string tT, string tC, string tCl, string tCA, string tCB)
|
||||
{
|
||||
return new _0024LoadCL_002415(ent, tT, tC, tCl, tCA, tCB, this).GetEnumerator();
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8a0258d0633b7e5ad07fd3b93e248c1c
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,181 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Boo.Lang;
|
||||
using Boo.Lang.Runtime;
|
||||
using UnityEngine;
|
||||
using UnityScript.Lang;
|
||||
|
||||
[Serializable]
|
||||
public class Chat : MonoBehaviour
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024FocusControl_002449 : GenericGenerator<object>
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024 : GenericGeneratorEnumerator<object>, IEnumerator
|
||||
{
|
||||
public override bool MoveNext()
|
||||
{
|
||||
int result;
|
||||
switch (_state)
|
||||
{
|
||||
default:
|
||||
result = (YieldDefault(2) ? 1 : 0);
|
||||
break;
|
||||
case 2:
|
||||
result = (YieldDefault(3) ? 1 : 0);
|
||||
break;
|
||||
case 3:
|
||||
GUI.FocusControl("Chat input field");
|
||||
YieldDefault(1);
|
||||
goto case 1;
|
||||
case 1:
|
||||
result = 0;
|
||||
break;
|
||||
}
|
||||
return (byte)result != 0;
|
||||
}
|
||||
}
|
||||
|
||||
public override IEnumerator<object> GetEnumerator()
|
||||
{
|
||||
return new _0024();
|
||||
}
|
||||
}
|
||||
|
||||
public GUISkin skin;
|
||||
|
||||
public bool showChat;
|
||||
|
||||
private string inputField;
|
||||
|
||||
private bool display;
|
||||
|
||||
private ArrayList entries;
|
||||
|
||||
private Vector2 scrollPosition;
|
||||
|
||||
private Rect window;
|
||||
|
||||
public Chat()
|
||||
{
|
||||
inputField = string.Empty;
|
||||
display = true;
|
||||
entries = new ArrayList();
|
||||
window = new Rect(50f, 50f, 200f, 300f);
|
||||
}
|
||||
|
||||
public virtual void CloseChatWindow()
|
||||
{
|
||||
showChat = false;
|
||||
inputField = string.Empty;
|
||||
entries = new ArrayList();
|
||||
}
|
||||
|
||||
public virtual IEnumerator FocusControl()
|
||||
{
|
||||
return new _0024FocusControl_002449().GetEnumerator();
|
||||
}
|
||||
|
||||
public virtual void OnGUI()
|
||||
{
|
||||
GUI.skin = skin;
|
||||
if (GUI.Button(new Rect(Screen.width - 100, Screen.height - 30, 90f, 20f), (!showChat) ? "Show Chat" : "Hide Chat"))
|
||||
{
|
||||
if (showChat)
|
||||
{
|
||||
CloseChatWindow();
|
||||
}
|
||||
else
|
||||
{
|
||||
showChat = true;
|
||||
StartCoroutine(FocusControl());
|
||||
}
|
||||
}
|
||||
if (showChat)
|
||||
{
|
||||
window = GUI.Window(1, window, GlobalChatWindow, "Chat");
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void GlobalChatWindow(int id)
|
||||
{
|
||||
GUIStyle style = GUI.skin.GetStyle("close_button");
|
||||
if (GUI.Button(new Rect(4f, 4f, style.normal.background.width, style.normal.background.height), string.Empty, "close_button"))
|
||||
{
|
||||
CloseChatWindow();
|
||||
}
|
||||
scrollPosition = GUILayout.BeginScrollView(scrollPosition);
|
||||
IEnumerator enumerator = UnityRuntimeServices.GetEnumerator(entries);
|
||||
while (enumerator.MoveNext())
|
||||
{
|
||||
object obj = enumerator.Current;
|
||||
if (!(obj is ChatEntry))
|
||||
{
|
||||
obj = RuntimeServices.Coerce(obj, typeof(ChatEntry));
|
||||
}
|
||||
ChatEntry chatEntry = (ChatEntry)obj;
|
||||
GUILayout.BeginHorizontal();
|
||||
if (!chatEntry.mine)
|
||||
{
|
||||
GUILayout.FlexibleSpace();
|
||||
GUILayout.Label(chatEntry.text, "chat_rightaligned");
|
||||
UnityRuntimeServices.Update(enumerator, chatEntry);
|
||||
}
|
||||
else
|
||||
{
|
||||
GUILayout.Label(chatEntry.text, "chat_leftaligned");
|
||||
UnityRuntimeServices.Update(enumerator, chatEntry);
|
||||
GUILayout.FlexibleSpace();
|
||||
}
|
||||
GUILayout.EndHorizontal();
|
||||
GUILayout.Space(3f);
|
||||
}
|
||||
GUILayout.EndScrollView();
|
||||
if (Event.current.type == EventType.KeyDown && Event.current.character == '\n' && inputField.Length > 0)
|
||||
{
|
||||
ApplyGlobalChatText(inputField, 1);
|
||||
GetComponent<NetworkView>().RPC("ApplyGlobalChatText", RPCMode.Others, inputField, 0);
|
||||
inputField = string.Empty;
|
||||
}
|
||||
GUI.SetNextControlName("Chat input field");
|
||||
inputField = GUILayout.TextField(inputField);
|
||||
GUI.DragWindow();
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown("t"))
|
||||
{
|
||||
showChat = true;
|
||||
StartCoroutine(FocusControl());
|
||||
}
|
||||
}
|
||||
|
||||
[RPC]
|
||||
public virtual void ApplyGlobalChatText(string str, int mine)
|
||||
{
|
||||
ChatEntry chatEntry = new ChatEntry();
|
||||
chatEntry.sender = "Not implemented";
|
||||
chatEntry.text = str;
|
||||
if (mine == 1)
|
||||
{
|
||||
chatEntry.mine = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
chatEntry.mine = false;
|
||||
}
|
||||
entries.Add(chatEntry);
|
||||
if (entries.Count > 50)
|
||||
{
|
||||
entries.RemoveAt(0);
|
||||
}
|
||||
scrollPosition.y = 1000000f;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2b889710faa73e11e80e2e067d3b35d0
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
|
||||
[Serializable]
|
||||
public class ChatEntry
|
||||
{
|
||||
public string sender;
|
||||
|
||||
public string text;
|
||||
|
||||
public bool mine;
|
||||
|
||||
public ChatEntry()
|
||||
{
|
||||
sender = string.Empty;
|
||||
text = string.Empty;
|
||||
mine = true;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1eded0084357a204fa1cc33048909ed7
|
||||
timeCreated: 1757091918
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,89 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class CollectPapers : MonoBehaviour
|
||||
{
|
||||
public int Paper;
|
||||
|
||||
public int paperToWin;
|
||||
|
||||
public Transform allpapersobj;
|
||||
|
||||
public Transform winobj1;
|
||||
|
||||
public Transform winobj2;
|
||||
|
||||
public Transform winobj3;
|
||||
|
||||
public Transform winobj4;
|
||||
|
||||
public Transform winobj5;
|
||||
|
||||
public Transform winobj6;
|
||||
|
||||
public Transform winobj7;
|
||||
|
||||
public Transform winobj8;
|
||||
|
||||
public Transform winobj9;
|
||||
|
||||
public CollectPapers()
|
||||
{
|
||||
paperToWin = 5;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerEnter(Collider other)
|
||||
{
|
||||
if (other.gameObject.tag == "Paper")
|
||||
{
|
||||
Paper++;
|
||||
UnityEngine.Object.Destroy(other.gameObject);
|
||||
Debug.Log("A paper was picked up. Total papers = " + Paper);
|
||||
}
|
||||
if (Paper == paperToWin)
|
||||
{
|
||||
Network.Instantiate(allpapersobj, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 1)
|
||||
{
|
||||
Network.Instantiate(winobj1, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 2)
|
||||
{
|
||||
Network.Instantiate(winobj2, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 3)
|
||||
{
|
||||
Network.Instantiate(winobj3, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 4)
|
||||
{
|
||||
Network.Instantiate(winobj4, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 5)
|
||||
{
|
||||
Network.Instantiate(winobj5, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 6)
|
||||
{
|
||||
Network.Instantiate(winobj6, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 7)
|
||||
{
|
||||
Network.Instantiate(winobj7, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 8)
|
||||
{
|
||||
Network.Instantiate(winobj8, transform.position, transform.rotation, 1);
|
||||
}
|
||||
if (Paper == 9)
|
||||
{
|
||||
Network.Instantiate(winobj9, transform.position, transform.rotation, 1);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ccbaa6ccd828776dd4f555b81637eebd
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,39 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class DoorOpen : MonoBehaviour
|
||||
{
|
||||
[NonSerialized]
|
||||
public static int leverswitch;
|
||||
|
||||
public int trigger;
|
||||
|
||||
public Transform Player;
|
||||
|
||||
public GameObject animated;
|
||||
|
||||
public Transform dooractivater;
|
||||
|
||||
public DoorOpen()
|
||||
{
|
||||
trigger = 1;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerEnter(Collider other)
|
||||
{
|
||||
leverswitch = trigger;
|
||||
Player.parent = null;
|
||||
animated.GetComponent<Animation>().Play("Take 001");
|
||||
bool flag = false;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerExit(Collider other)
|
||||
{
|
||||
UnityEngine.Object.Destroy(gameObject);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b0036c2836d91af58bcfb6f22317a5df
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,237 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using UnityScript.Lang;
|
||||
|
||||
[Serializable]
|
||||
public class EnemyScript : MonoBehaviour
|
||||
{
|
||||
public Transform thePlayer;
|
||||
|
||||
private Transform theEnemy;
|
||||
|
||||
public float speed;
|
||||
|
||||
public float runspeed;
|
||||
|
||||
public float sprintspeed;
|
||||
|
||||
public bool isOffScreen;
|
||||
|
||||
public float offscreenDotRange;
|
||||
|
||||
public bool isVisible;
|
||||
|
||||
public float visibleDotRange;
|
||||
|
||||
public bool isInRange;
|
||||
|
||||
public float followDistance;
|
||||
|
||||
public float maxVisibleDistance;
|
||||
|
||||
private float sqrDist;
|
||||
|
||||
public float health;
|
||||
|
||||
public float damage;
|
||||
|
||||
public AudioClip nearbyaudio;
|
||||
|
||||
public GameObject triggerTarget;
|
||||
|
||||
public Texture replacementTex;
|
||||
|
||||
public Texture originalTex;
|
||||
|
||||
public Texture2D blackness;
|
||||
|
||||
public Texture2D scare;
|
||||
|
||||
public Transform endgamepopup;
|
||||
|
||||
public Transform ifseesobject;
|
||||
|
||||
public GameObject[] gos;
|
||||
|
||||
public EnemyScript()
|
||||
{
|
||||
speed = 5f;
|
||||
runspeed = 7f;
|
||||
sprintspeed = 11f;
|
||||
offscreenDotRange = 0.7f;
|
||||
visibleDotRange = 0.8f;
|
||||
followDistance = 3f;
|
||||
maxVisibleDistance = 25f;
|
||||
health = 100f;
|
||||
damage = 20f;
|
||||
}
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
if (thePlayer == null)
|
||||
{
|
||||
thePlayer = GameObject.FindWithTag("Player").transform;
|
||||
}
|
||||
theEnemy = transform;
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
thePlayer = GameObject.FindWithTag("Player").transform;
|
||||
CheckIfOffScreen();
|
||||
if (isOffScreen)
|
||||
{
|
||||
MoveEnemy();
|
||||
return;
|
||||
}
|
||||
thePlayer = GameObject.FindWithTag("Player").transform;
|
||||
CheckIfVisible();
|
||||
if (isVisible)
|
||||
{
|
||||
DeductHealth();
|
||||
StopEnemy();
|
||||
return;
|
||||
}
|
||||
CheckMaxVisibleRange();
|
||||
if (!isInRange)
|
||||
{
|
||||
MoveEnemy();
|
||||
}
|
||||
else
|
||||
{
|
||||
StopEnemy();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void DeductHealth()
|
||||
{
|
||||
health -= damage * Time.deltaTime;
|
||||
Renderer rend = GetComponentInChildren<Renderer>();
|
||||
if (rend != null)
|
||||
{
|
||||
rend.sharedMaterial.mainTexture = replacementTex;
|
||||
}
|
||||
Network.Instantiate(ifseesobject, transform.position, transform.rotation, 1);
|
||||
if (!GetComponent<AudioSource>().isPlaying)
|
||||
{
|
||||
GetComponent<AudioSource>().clip = nearbyaudio;
|
||||
GetComponent<AudioSource>().Play();
|
||||
}
|
||||
if (!(health > 0f))
|
||||
{
|
||||
Network.Instantiate(endgamepopup, transform.position, transform.rotation, 1);
|
||||
UnityEngine.Object.Destroy(gameObject);
|
||||
Network.Disconnect();
|
||||
Application.LoadLevel(0);
|
||||
health = 0f;
|
||||
Debug.Log("YOU ARE OUT OF HEALTH !");
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void CheckIfOffScreen()
|
||||
{
|
||||
Vector3 normalized = thePlayer.forward.normalized;
|
||||
Vector3 normalized2 = (theEnemy.position - thePlayer.position).normalized;
|
||||
float num = Vector3.Dot(normalized, normalized2);
|
||||
if (!(num >= offscreenDotRange))
|
||||
{
|
||||
isOffScreen = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
isOffScreen = false;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void MoveEnemy()
|
||||
{
|
||||
gos = GameObject.FindGameObjectsWithTag("Paper");
|
||||
if (Extensions.get_length((System.Array)gos) == 5)
|
||||
{
|
||||
speed = runspeed;
|
||||
}
|
||||
if (Extensions.get_length((System.Array)gos) == 2)
|
||||
{
|
||||
speed = sprintspeed;
|
||||
}
|
||||
CheckDistance();
|
||||
if (!isInRange)
|
||||
{
|
||||
transform.LookAt(thePlayer);
|
||||
GetComponent<Rigidbody>().velocity = new Vector3(0f, GetComponent<Rigidbody>().velocity.y, 0f);
|
||||
transform.position += transform.forward * speed * Time.deltaTime;
|
||||
}
|
||||
else
|
||||
{
|
||||
StopEnemy();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void StopEnemy()
|
||||
{
|
||||
transform.LookAt(thePlayer);
|
||||
GetComponent<Rigidbody>().velocity = Vector3.zero;
|
||||
}
|
||||
|
||||
public virtual void CheckIfVisible()
|
||||
{
|
||||
Vector3 normalized = thePlayer.forward.normalized;
|
||||
Vector3 normalized2 = (theEnemy.position - thePlayer.position).normalized;
|
||||
float num = Vector3.Dot(normalized, normalized2);
|
||||
if (!(num <= visibleDotRange))
|
||||
{
|
||||
CheckMaxVisibleRange();
|
||||
if (isInRange)
|
||||
{
|
||||
RaycastHit hitInfo = default(RaycastHit);
|
||||
if (Physics.Linecast(theEnemy.position, thePlayer.position, out hitInfo) && hitInfo.collider.gameObject.tag == "Player")
|
||||
{
|
||||
isVisible = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
isVisible = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
isVisible = false;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void CheckDistance()
|
||||
{
|
||||
float sqrMagnitude = (theEnemy.position - thePlayer.position).sqrMagnitude;
|
||||
float num = followDistance * followDistance;
|
||||
if (!(sqrMagnitude >= num))
|
||||
{
|
||||
isInRange = true;
|
||||
return;
|
||||
}
|
||||
isInRange = false;
|
||||
Renderer rend = GetComponentInChildren<Renderer>();
|
||||
if (rend != null)
|
||||
{
|
||||
rend.sharedMaterial.mainTexture = originalTex;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void CheckMaxVisibleRange()
|
||||
{
|
||||
float sqrMagnitude = (theEnemy.position - thePlayer.position).sqrMagnitude;
|
||||
float num = maxVisibleDistance * maxVisibleDistance;
|
||||
if (!(sqrMagnitude >= num))
|
||||
{
|
||||
isInRange = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
isInRange = false;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a7d2c90932fb0ce2520f28f9b13e7013
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,199 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class EnemyScriptPlayer : MonoBehaviour
|
||||
{
|
||||
public Transform thePlayer;
|
||||
|
||||
private Transform theEnemy;
|
||||
|
||||
public float speed;
|
||||
|
||||
public bool isOffScreen;
|
||||
|
||||
public float offscreenDotRange;
|
||||
|
||||
public bool isVisible;
|
||||
|
||||
public float visibleDotRange;
|
||||
|
||||
public bool isInRange;
|
||||
|
||||
public float followDistance;
|
||||
|
||||
public float maxVisibleDistance;
|
||||
|
||||
private float sqrDist;
|
||||
|
||||
public float health;
|
||||
|
||||
public float damage;
|
||||
|
||||
public AudioClip nearbyaudio;
|
||||
|
||||
public GameObject triggerTarget;
|
||||
|
||||
public Texture replacementTex;
|
||||
|
||||
public Texture originalTex;
|
||||
|
||||
public Texture2D blackness;
|
||||
|
||||
public Texture2D scare;
|
||||
|
||||
public Transform endgamepopup;
|
||||
|
||||
public EnemyScriptPlayer()
|
||||
{
|
||||
speed = 5f;
|
||||
offscreenDotRange = 0.7f;
|
||||
visibleDotRange = 0.8f;
|
||||
followDistance = 3f;
|
||||
maxVisibleDistance = 25f;
|
||||
health = 100f;
|
||||
damage = 20f;
|
||||
}
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
if (thePlayer == null)
|
||||
{
|
||||
thePlayer = GameObject.FindWithTag("Player").transform;
|
||||
}
|
||||
theEnemy = transform;
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
thePlayer = GameObject.FindWithTag("Player").transform;
|
||||
CheckIfOffScreen();
|
||||
if (isOffScreen)
|
||||
{
|
||||
MoveEnemy();
|
||||
return;
|
||||
}
|
||||
thePlayer = GameObject.FindWithTag("Player").transform;
|
||||
CheckIfVisible();
|
||||
if (isVisible)
|
||||
{
|
||||
DeductHealth();
|
||||
StopEnemy();
|
||||
return;
|
||||
}
|
||||
CheckMaxVisibleRange();
|
||||
if (!isInRange)
|
||||
{
|
||||
MoveEnemy();
|
||||
}
|
||||
else
|
||||
{
|
||||
StopEnemy();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void DeductHealth()
|
||||
{
|
||||
health -= damage * Time.deltaTime;
|
||||
triggerTarget.GetComponent<Renderer>().material.mainTexture = replacementTex;
|
||||
if (!GetComponent<AudioSource>().isPlaying)
|
||||
{
|
||||
GetComponent<AudioSource>().clip = nearbyaudio;
|
||||
GetComponent<AudioSource>().Play();
|
||||
}
|
||||
if (!(health > 0f))
|
||||
{
|
||||
Network.Instantiate(endgamepopup, transform.position, transform.rotation, 1);
|
||||
UnityEngine.Object.DestroyObject(gameObject);
|
||||
health = 0f;
|
||||
Debug.Log("YOU ARE OUT OF HEALTH !");
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void CheckIfOffScreen()
|
||||
{
|
||||
Vector3 normalized = thePlayer.forward.normalized;
|
||||
Vector3 normalized2 = (theEnemy.position - thePlayer.position).normalized;
|
||||
float num = Vector3.Dot(normalized, normalized2);
|
||||
if (!(num >= offscreenDotRange))
|
||||
{
|
||||
isOffScreen = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
isOffScreen = false;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void MoveEnemy()
|
||||
{
|
||||
CheckDistance();
|
||||
if (isInRange)
|
||||
{
|
||||
StopEnemy();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void StopEnemy()
|
||||
{
|
||||
GetComponent<Rigidbody>().velocity = Vector3.zero;
|
||||
}
|
||||
|
||||
public virtual void CheckIfVisible()
|
||||
{
|
||||
Vector3 normalized = thePlayer.forward.normalized;
|
||||
Vector3 normalized2 = (theEnemy.position - thePlayer.position).normalized;
|
||||
float num = Vector3.Dot(normalized, normalized2);
|
||||
if (!(num <= visibleDotRange))
|
||||
{
|
||||
CheckMaxVisibleRange();
|
||||
if (isInRange)
|
||||
{
|
||||
RaycastHit hitInfo = default(RaycastHit);
|
||||
if (Physics.Linecast(theEnemy.position, thePlayer.position, out hitInfo) && hitInfo.collider.gameObject.tag == "Player")
|
||||
{
|
||||
isVisible = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
isVisible = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
isVisible = false;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void CheckDistance()
|
||||
{
|
||||
float sqrMagnitude = (theEnemy.position - thePlayer.position).sqrMagnitude;
|
||||
float num = followDistance * followDistance;
|
||||
if (!(sqrMagnitude >= num))
|
||||
{
|
||||
isInRange = true;
|
||||
return;
|
||||
}
|
||||
isInRange = false;
|
||||
triggerTarget.GetComponent<Renderer>().material.mainTexture = originalTex;
|
||||
}
|
||||
|
||||
public virtual void CheckMaxVisibleRange()
|
||||
{
|
||||
float sqrMagnitude = (theEnemy.position - thePlayer.position).sqrMagnitude;
|
||||
float num = maxVisibleDistance * maxVisibleDistance;
|
||||
if (!(sqrMagnitude >= num))
|
||||
{
|
||||
isInRange = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
isInRange = false;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f303a3a02b58be51a7725e19761e0f09
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using UnityEditor;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x0200000C RID: 12
|
||||
[Serializable]
|
||||
public class Exitcreditshelp : MonoBehaviour
|
||||
{
|
||||
// Token: 0x0600002E RID: 46 RVA: 0x000037B8 File Offset: 0x000019B8
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown(KeyCode.Space))
|
||||
{
|
||||
Transform transform = GameObject.FindWithTag("Creditsandhelp").transform;
|
||||
global::UnityEngine.Object.Destroy(transform.gameObject);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600002F RID: 47 RVA: 0x000037EC File Offset: 0x000019EC
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1f7bd613a115e5915c0e614fd86acd85
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Exitcredits_0026help : MonoBehaviour
|
||||
{
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown(KeyCode.Space))
|
||||
{
|
||||
Transform transform = GameObject.FindWithTag("Creditsandhelp").transform;
|
||||
UnityEngine.Object.Destroy(transform.gameObject);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e9c3e997ef319854ab9b854c0d4e46dd
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class FlyingCamera : MonoBehaviour
|
||||
{
|
||||
public float lookSpeed;
|
||||
|
||||
public float moveSpeed;
|
||||
|
||||
public float rotationX;
|
||||
|
||||
public float rotationY;
|
||||
|
||||
public FlyingCamera()
|
||||
{
|
||||
lookSpeed = 7f;
|
||||
moveSpeed = 3f;
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
rotationX += Input.GetAxis("Mouse X") * lookSpeed;
|
||||
rotationY += Input.GetAxis("Mouse Y") * lookSpeed;
|
||||
rotationY = Mathf.Clamp(rotationY, -90f, 90f);
|
||||
transform.localRotation = Quaternion.AngleAxis(rotationX, Vector3.up);
|
||||
transform.localRotation *= Quaternion.AngleAxis(rotationY, Vector3.left);
|
||||
transform.position += transform.forward * moveSpeed * Input.GetAxis("Vertical");
|
||||
transform.position += transform.right * moveSpeed * Input.GetAxis("Horizontal");
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7201bf2f35f9761e1cd43ef5887307b0
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Gamequit : MonoBehaviour
|
||||
{
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown("escape"))
|
||||
{
|
||||
Application.Quit();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fe47f5f1c1f5eef151e3a1d98db3e0ea
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,52 @@
|
||||
using System;
|
||||
using Boo.Lang.Runtime;
|
||||
using UnityEngine;
|
||||
using UnityScript.Lang;
|
||||
|
||||
[Serializable]
|
||||
public class Individualize : MonoBehaviour
|
||||
{
|
||||
public string entID;
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
entID = gameObject.GetComponent<NetworkView>().viewID.ToString().Remove(0, 13);
|
||||
if (GetComponent<NetworkView>().isMine)
|
||||
{
|
||||
GetComponent<NetworkView>().RPC("Change", RPCMode.AllBuffered, entID);
|
||||
}
|
||||
}
|
||||
|
||||
[RPC]
|
||||
public virtual void Change(string ent)
|
||||
{
|
||||
if (!(gameObject.GetComponent<NetworkView>().viewID.ToString().Remove(0, 13) == ent))
|
||||
{
|
||||
return;
|
||||
}
|
||||
Component[] componentsInChildren = GetComponentsInChildren(typeof(Transform));
|
||||
int i = 0;
|
||||
Component[] array = componentsInChildren;
|
||||
for (int length = array.Length; i < length; i++)
|
||||
{
|
||||
if (array[i].tag == "Player")
|
||||
{
|
||||
array[i].name = array[i].name + ent;
|
||||
}
|
||||
}
|
||||
Component[] componentsInChildren2 = GetComponentsInChildren(typeof(Renderer));
|
||||
int j = 0;
|
||||
Component[] array2 = componentsInChildren2;
|
||||
for (int length2 = array2.Length; j < length2; j++)
|
||||
{
|
||||
for (int k = 0; RuntimeServices.ToBool(RuntimeServices.InvokeBinaryOperator("op_LessThan", k, UnityRuntimeServices.GetProperty(UnityRuntimeServices.GetProperty(array2[j], "materials"), "length"))); k++)
|
||||
{
|
||||
RuntimeServices.SetProperty(RuntimeServices.GetSlice(array2[j], "materials", new object[1] { k }), "name", RuntimeServices.InvokeBinaryOperator("op_Addition", UnityRuntimeServices.GetProperty(RuntimeServices.GetSlice(array2[j], "materials", new object[1] { k }), "name"), ent));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4016b748ea678543cbadfc4aa8f600c4
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x02000023 RID: 35
|
||||
[Serializable]
|
||||
public class Multiplayerbutton : MonoBehaviour
|
||||
{
|
||||
// Token: 0x06000083 RID: 131 RVA: 0x00004B7C File Offset: 0x00002D7C
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
this.clicked = !this.clicked;
|
||||
this.CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
this.CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
this.CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
this.CameraMultiplayer.GetComponent<Camera>().enabled = true;
|
||||
this.CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
this.CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
// Token: 0x06000084 RID: 132 RVA: 0x00004C00 File Offset: 0x00002E00
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x040000B0 RID: 176
|
||||
public bool clicked;
|
||||
|
||||
// Token: 0x040000B1 RID: 177
|
||||
public Camera CameraMenu;
|
||||
|
||||
// Token: 0x040000B2 RID: 178
|
||||
public Camera CameraSettings;
|
||||
|
||||
// Token: 0x040000B3 RID: 179
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
// Token: 0x040000B4 RID: 180
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
// Token: 0x040000B5 RID: 181
|
||||
public Camera CameraCoop;
|
||||
|
||||
// Token: 0x040000B6 RID: 182
|
||||
public Camera CameraVerses;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 04ca878cfbd769c7c99b7cf8a66708ad
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Multiplayerbutton_0023 : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Camera CameraMenu;
|
||||
|
||||
public Camera CameraSettings;
|
||||
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
public Camera CameraCoop;
|
||||
|
||||
public Camera CameraVerses;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraMultiplayer.GetComponent<Camera>().enabled = true;
|
||||
CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 15923a368c4515945bcbe898be87296b
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Popupguiscript : MonoBehaviour
|
||||
{
|
||||
public Texture2D yourtexture;
|
||||
|
||||
public AudioClip popupsound;
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (popupsound != null)
|
||||
{
|
||||
if (!GetComponent<AudioSource>().isPlaying)
|
||||
{
|
||||
GetComponent<AudioSource>().clip = popupsound;
|
||||
GetComponent<AudioSource>().Play();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void OnGUI()
|
||||
{
|
||||
GUI.DrawTexture(new Rect(0f, 0f, Screen.width, Screen.height), yourtexture);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d03b12d438f279340a18132eaa908d71
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,163 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Boo.Lang;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Popups : MonoBehaviour
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024Spawn_002453 : GenericGenerator<WaitForSeconds>
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024 : GenericGeneratorEnumerator<WaitForSeconds>, IEnumerator
|
||||
{
|
||||
internal int _0024randomPick_002454;
|
||||
|
||||
internal Transform _0024location_002455;
|
||||
|
||||
internal Transform _0024thingToMake_002456;
|
||||
|
||||
internal Popups _0024self__002457;
|
||||
|
||||
public _0024(Popups self_)
|
||||
{
|
||||
_0024self__002457 = self_;
|
||||
}
|
||||
|
||||
public override bool MoveNext()
|
||||
{
|
||||
int result;
|
||||
switch (_state)
|
||||
{
|
||||
default:
|
||||
_0024self__002457.spawning = true;
|
||||
_0024self__002457.timer = 0f;
|
||||
_0024randomPick_002454 = Mathf.Abs(UnityEngine.Random.Range(1, 7));
|
||||
_0024location_002455 = null;
|
||||
if (_0024randomPick_002454 == 1)
|
||||
{
|
||||
_0024location_002455 = _0024self__002457.spawn1;
|
||||
result = (Yield(2, new WaitForSeconds(UnityEngine.Random.Range(30, 200))) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
if (_0024randomPick_002454 == 2)
|
||||
{
|
||||
result = (Yield(3, new WaitForSeconds(UnityEngine.Random.Range(30, 200))) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
if (_0024randomPick_002454 == 3)
|
||||
{
|
||||
result = (Yield(4, new WaitForSeconds(UnityEngine.Random.Range(30, 200))) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
if (_0024randomPick_002454 == 4)
|
||||
{
|
||||
result = (Yield(5, new WaitForSeconds(UnityEngine.Random.Range(30, 200))) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
if (_0024randomPick_002454 == 5)
|
||||
{
|
||||
result = (Yield(6, new WaitForSeconds(UnityEngine.Random.Range(30, 200))) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
if (_0024randomPick_002454 == 6)
|
||||
{
|
||||
result = (Yield(7, new WaitForSeconds(UnityEngine.Random.Range(30, 200))) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
goto IL_0218;
|
||||
case 2:
|
||||
Debug.Log("Chose pos 1");
|
||||
goto IL_0218;
|
||||
case 3:
|
||||
_0024location_002455 = _0024self__002457.spawn2;
|
||||
Debug.Log("Chose pos 2");
|
||||
goto IL_0218;
|
||||
case 4:
|
||||
_0024location_002455 = _0024self__002457.spawn3;
|
||||
Debug.Log("Chose pos 3");
|
||||
goto IL_0218;
|
||||
case 5:
|
||||
_0024location_002455 = _0024self__002457.spawn4;
|
||||
Debug.Log("Chose pos 4");
|
||||
goto IL_0218;
|
||||
case 6:
|
||||
_0024location_002455 = _0024self__002457.spawn5;
|
||||
Debug.Log("Chose pos 5");
|
||||
goto IL_0218;
|
||||
case 7:
|
||||
_0024location_002455 = _0024self__002457.spawn6;
|
||||
Debug.Log("Chose pos 6");
|
||||
goto IL_0218;
|
||||
case 8:
|
||||
_0024self__002457.spawning = false;
|
||||
YieldDefault(1);
|
||||
goto case 1;
|
||||
case 1:
|
||||
{
|
||||
result = 0;
|
||||
break;
|
||||
}
|
||||
IL_0218:
|
||||
_0024thingToMake_002456 = (Transform)Network.Instantiate(_0024location_002455, _0024self__002457.spawnpoint.position, _0024self__002457.spawnpoint.rotation, 1);
|
||||
result = (Yield(8, new WaitForSeconds(1f)) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
return (byte)result != 0;
|
||||
}
|
||||
}
|
||||
|
||||
internal Popups _0024self__002458;
|
||||
|
||||
public _0024Spawn_002453(Popups self_)
|
||||
{
|
||||
_0024self__002458 = self_;
|
||||
}
|
||||
|
||||
public override IEnumerator<WaitForSeconds> GetEnumerator()
|
||||
{
|
||||
return new _0024(_0024self__002458);
|
||||
}
|
||||
}
|
||||
|
||||
public float timer;
|
||||
|
||||
public bool spawning;
|
||||
|
||||
public Transform spawnpoint;
|
||||
|
||||
public Transform spawn1;
|
||||
|
||||
public Transform spawn2;
|
||||
|
||||
public Transform spawn3;
|
||||
|
||||
public Transform spawn4;
|
||||
|
||||
public Transform spawn5;
|
||||
|
||||
public Transform spawn6;
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (!spawning)
|
||||
{
|
||||
timer += Time.deltaTime;
|
||||
}
|
||||
if (!(timer < 2f))
|
||||
{
|
||||
StartCoroutine(Spawn());
|
||||
}
|
||||
}
|
||||
|
||||
public virtual IEnumerator Spawn()
|
||||
{
|
||||
return new _0024Spawn_002453(this).GetEnumerator();
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4765139e64978f74bb403348e80cb61a
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,9 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1060c9fe727f8774789e4eb99445597a
|
||||
folderAsset: yes
|
||||
timeCreated: 1757091907
|
||||
licenseType: Pro
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,5 @@
|
||||
using System.Diagnostics;
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
[assembly: AssemblyVersion("0.0.0.0")]
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9e8b3d9c3d5f83743867545f9c3512ba
|
||||
timeCreated: 1757091922
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Returntomainmenu : MonoBehaviour
|
||||
{
|
||||
public virtual void OnGUI()
|
||||
{
|
||||
if (GUI.Button(new Rect(0f, 0f, 800f, 20f), "Return to the main menu"))
|
||||
{
|
||||
Debug.Log("clicked credits");
|
||||
Application.LoadLevel(0);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: dad1e98addafe22c107b9a312bd94119
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,38 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Settings : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Camera CameraMenu;
|
||||
|
||||
public Camera CameraSettings;
|
||||
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
public Camera CameraCoop;
|
||||
|
||||
public Camera CameraVerses;
|
||||
|
||||
public Transform settingsobject;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
UnityEngine.Object.Instantiate(settingsobject, transform.position, transform.rotation);
|
||||
CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
CameraSettings.GetComponent<Camera>().enabled = true;
|
||||
CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 04aeaa002b694c8881020c1d9f0c4eaa
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Singleplayerbutton_0023 : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Camera CameraMenu;
|
||||
|
||||
public Camera CameraSettings;
|
||||
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
public Camera CameraCoop;
|
||||
|
||||
public Camera CameraVerses;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
CameraSingleplayer.GetComponent<Camera>().enabled = true;
|
||||
CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e007be8d2490d5d49ac7db139ae0d429
|
||||
timeCreated: 1757091923
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x02000025 RID: 37
|
||||
[Serializable]
|
||||
public class Singleplayerbutton : MonoBehaviour
|
||||
{
|
||||
// Token: 0x06000089 RID: 137 RVA: 0x00004CBC File Offset: 0x00002EBC
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
this.clicked = !this.clicked;
|
||||
this.CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
this.CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
this.CameraSingleplayer.GetComponent<Camera>().enabled = true;
|
||||
this.CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
this.CameraCoop.GetComponent<Camera>().enabled = false;
|
||||
this.CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
// Token: 0x0600008A RID: 138 RVA: 0x00004D40 File Offset: 0x00002F40
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x040000BF RID: 191
|
||||
public bool clicked;
|
||||
|
||||
// Token: 0x040000C0 RID: 192
|
||||
public Camera CameraMenu;
|
||||
|
||||
// Token: 0x040000C1 RID: 193
|
||||
public Camera CameraSettings;
|
||||
|
||||
// Token: 0x040000C2 RID: 194
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
// Token: 0x040000C3 RID: 195
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
// Token: 0x040000C4 RID: 196
|
||||
public Camera CameraCoop;
|
||||
|
||||
// Token: 0x040000C5 RID: 197
|
||||
public Camera CameraVerses;
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0ff5f061318b07446ac543f6ca91674e
|
||||
timeCreated: 1757094945
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Tinkypopupcontrol : MonoBehaviour
|
||||
{
|
||||
public Transform popup1;
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (GetComponent<NetworkView>().isMine && Input.GetKeyDown("n"))
|
||||
{
|
||||
Network.Instantiate(popup1, transform.position, transform.rotation, 1);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 66d0b2f101fb961438c8e49a68b95827
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class Tinkyvision : MonoBehaviour
|
||||
{
|
||||
public virtual void Start()
|
||||
{
|
||||
RenderSettings.fog = !RenderSettings.fog;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 01b5e76923d8935f7a8dad389ed4ec4e
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,27 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using UnityScript.Lang;
|
||||
|
||||
[Serializable]
|
||||
public class checkcustards : MonoBehaviour
|
||||
{
|
||||
public GameObject[] gos;
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
gos = GameObject.FindGameObjectsWithTag("Paper");
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
gos = GameObject.FindGameObjectsWithTag("Paper");
|
||||
if (Extensions.get_length((System.Array)gos) == 10)
|
||||
{
|
||||
UnityEngine.Object.DestroyObject(gameObject);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8b88c164af297a2eb45a8fc0cff266ec
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class collectsoundscript : MonoBehaviour
|
||||
{
|
||||
[NonSerialized]
|
||||
public static int leverswitch;
|
||||
|
||||
public int trigger;
|
||||
|
||||
public Transform Player;
|
||||
|
||||
public GameObject animated;
|
||||
|
||||
public Transform dooractivater;
|
||||
|
||||
public Transform collect;
|
||||
|
||||
public Transform spawnpoint;
|
||||
|
||||
public collectsoundscript()
|
||||
{
|
||||
trigger = 1;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerEnter(Collider other)
|
||||
{
|
||||
leverswitch = trigger;
|
||||
Player.parent = null;
|
||||
UnityEngine.Object.Instantiate(collect, spawnpoint.position, spawnpoint.rotation);
|
||||
bool flag = false;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerExit(Collider other)
|
||||
{
|
||||
UnityEngine.Object.Destroy(gameObject);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f41e6cc7c2b91db3fc6c8ecf350024bd
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x02000026 RID: 38
|
||||
[Serializable]
|
||||
public class coopbutton : MonoBehaviour
|
||||
{
|
||||
// Token: 0x0600008C RID: 140 RVA: 0x00004D4C File Offset: 0x00002F4C
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
this.clicked = !this.clicked;
|
||||
this.CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
this.CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
this.CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
this.CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
this.CameraCoop.GetComponent<Camera>().enabled = true;
|
||||
this.CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
// Token: 0x0600008D RID: 141 RVA: 0x00004DD0 File Offset: 0x00002FD0
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x040000C6 RID: 198
|
||||
public bool clicked;
|
||||
|
||||
// Token: 0x040000C7 RID: 199
|
||||
public Camera CameraMenu;
|
||||
|
||||
// Token: 0x040000C8 RID: 200
|
||||
public Camera CameraSettings;
|
||||
|
||||
// Token: 0x040000C9 RID: 201
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
// Token: 0x040000CA RID: 202
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
// Token: 0x040000CB RID: 203
|
||||
public Camera CameraCoop;
|
||||
|
||||
// Token: 0x040000CC RID: 204
|
||||
public Camera CameraVerses;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 93cb6a2fba5ef291d61e0360b8b21822
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class coopbutton_0023 : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Camera CameraMenu;
|
||||
|
||||
public Camera CameraSettings;
|
||||
|
||||
public Camera CameraSingleplayer;
|
||||
|
||||
public Camera CameraMultiplayer;
|
||||
|
||||
public Camera CameraCoop;
|
||||
|
||||
public Camera CameraVerses;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
CameraMenu.GetComponent<Camera>().enabled = false;
|
||||
CameraSettings.GetComponent<Camera>().enabled = false;
|
||||
CameraSingleplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraMultiplayer.GetComponent<Camera>().enabled = false;
|
||||
CameraCoop.GetComponent<Camera>().enabled = true;
|
||||
CameraVerses.GetComponent<Camera>().enabled = false;
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0040a307aa6e3b84f83199bc836b24fc
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class coopday : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
Application.LoadLevel(1);
|
||||
Debug.Log("clicked credits" + ((!clicked) ? " off" : string.Empty));
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a4b0dd4207b272b9974e1f7de89a035e
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class coopdusk : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
Application.LoadLevel(2);
|
||||
Debug.Log("clicked credits" + ((!clicked) ? " off" : string.Empty));
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7c6bb0b3ebd1bc84ceb2879ac22c076c
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class coopnight : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
Application.LoadLevel(3);
|
||||
Debug.Log("clicked credits" + ((!clicked) ? " off" : string.Empty));
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 95143578659cfc4ea4cb5889c36ace4b
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class createonclick : MonoBehaviour
|
||||
{
|
||||
public bool clicked;
|
||||
|
||||
public Transform spawn;
|
||||
|
||||
public virtual void OnMouseDown()
|
||||
{
|
||||
clicked = !clicked;
|
||||
UnityEngine.Object.Instantiate(spawn, transform.position, transform.rotation);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 316b8e6dc1a18e4505b8e5fdacf789ee
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,73 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x02000017 RID: 23
|
||||
[Serializable]
|
||||
public class crouchandrun : MonoBehaviour
|
||||
{
|
||||
// Token: 0x06000057 RID: 87 RVA: 0x00004308 File Offset: 0x00002508
|
||||
public crouchandrun()
|
||||
{
|
||||
this.walkSpeed = (float)7;
|
||||
this.crchSpeed = (float)3;
|
||||
this.runSpeed = (float)20;
|
||||
}
|
||||
|
||||
// Token: 0x06000058 RID: 88 RVA: 0x0000432C File Offset: 0x0000252C
|
||||
public virtual void Start()
|
||||
{
|
||||
this.chMotor = (CharacterMotor)this.GetComponent(typeof(CharacterMotor));
|
||||
this.tr = this.transform;
|
||||
CharacterController characterController = (CharacterController)this.GetComponent(typeof(CharacterController));
|
||||
this.dist = characterController.height / (float)2;
|
||||
}
|
||||
|
||||
// Token: 0x06000059 RID: 89 RVA: 0x00004388 File Offset: 0x00002588
|
||||
public virtual void Update()
|
||||
{
|
||||
float num = 1f;
|
||||
float num2 = this.walkSpeed;
|
||||
if ((this.chMotor.grounded && Input.GetKey("left shift")) || Input.GetKey("right shift"))
|
||||
{
|
||||
num2 = this.runSpeed;
|
||||
}
|
||||
if (Input.GetKey("c"))
|
||||
{
|
||||
num = 0.5f;
|
||||
num2 = this.crchSpeed;
|
||||
}
|
||||
this.chMotor.movement.maxForwardSpeed = num2;
|
||||
float y = this.tr.localScale.y;
|
||||
float num3 = Mathf.Lerp(this.tr.localScale.y, num, (float)5 * Time.deltaTime);
|
||||
Vector3 localScale = this.tr.localScale;
|
||||
float num4 = (localScale.y = num3);
|
||||
Vector3 vector = (this.tr.localScale = localScale);
|
||||
float num5 = this.tr.position.y + this.dist * (this.tr.localScale.y - y);
|
||||
Vector3 position = this.tr.position;
|
||||
float num6 = (position.y = num5);
|
||||
Vector3 vector2 = (this.tr.position = position);
|
||||
}
|
||||
|
||||
// Token: 0x0600005A RID: 90 RVA: 0x000044D8 File Offset: 0x000026D8
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x0400007F RID: 127
|
||||
public float walkSpeed;
|
||||
|
||||
// Token: 0x04000080 RID: 128
|
||||
public float crchSpeed;
|
||||
|
||||
// Token: 0x04000081 RID: 129
|
||||
public float runSpeed;
|
||||
|
||||
// Token: 0x04000082 RID: 130
|
||||
private CharacterMotor chMotor;
|
||||
|
||||
// Token: 0x04000083 RID: 131
|
||||
private Transform tr;
|
||||
|
||||
// Token: 0x04000084 RID: 132
|
||||
private float dist;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d1ec75c1b1408d86d9146acebee9ef83
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,62 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class crouch_0020and_0020run : MonoBehaviour
|
||||
{
|
||||
public float walkSpeed;
|
||||
|
||||
public float crchSpeed;
|
||||
|
||||
public float runSpeed;
|
||||
|
||||
private CharacterMotor chMotor;
|
||||
|
||||
private Transform tr;
|
||||
|
||||
private float dist;
|
||||
|
||||
public crouch_0020and_0020run()
|
||||
{
|
||||
walkSpeed = 7f;
|
||||
crchSpeed = 3f;
|
||||
runSpeed = 20f;
|
||||
}
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
chMotor = (CharacterMotor)GetComponent(typeof(CharacterMotor));
|
||||
tr = transform;
|
||||
CharacterController characterController = (CharacterController)GetComponent(typeof(CharacterController));
|
||||
dist = characterController.height / 2f;
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
float to = 1f;
|
||||
float maxForwardSpeed = walkSpeed;
|
||||
if ((chMotor.grounded && Input.GetKey("left shift")) || Input.GetKey("right shift"))
|
||||
{
|
||||
maxForwardSpeed = runSpeed;
|
||||
}
|
||||
if (Input.GetKey("c"))
|
||||
{
|
||||
to = 0.5f;
|
||||
maxForwardSpeed = crchSpeed;
|
||||
}
|
||||
chMotor.movement.maxForwardSpeed = maxForwardSpeed;
|
||||
float y = tr.localScale.y;
|
||||
float y2 = Mathf.Lerp(tr.localScale.y, to, 5f * Time.deltaTime);
|
||||
Vector3 localScale = tr.localScale;
|
||||
float num = (localScale.y = y2);
|
||||
Vector3 vector = (tr.localScale = localScale);
|
||||
float y3 = tr.position.y + dist * (tr.localScale.y - y);
|
||||
Vector3 position = tr.position;
|
||||
float num2 = (position.y = y3);
|
||||
Vector3 vector3 = (tr.position = position);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 157aafc44358c5b429dee899a484df98
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class destoryaftertimer : MonoBehaviour
|
||||
{
|
||||
public float timeOut;
|
||||
|
||||
public bool detachChildren;
|
||||
|
||||
public destoryaftertimer()
|
||||
{
|
||||
timeOut = 1f;
|
||||
}
|
||||
|
||||
public virtual void Awake()
|
||||
{
|
||||
Invoke("DestroyNow", timeOut);
|
||||
}
|
||||
|
||||
public virtual void DestroyNow()
|
||||
{
|
||||
if (detachChildren)
|
||||
{
|
||||
transform.DetachChildren();
|
||||
}
|
||||
UnityEngine.Object.DestroyObject(gameObject);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f857cea17ff25e451e8fc67fbb29df76
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,38 @@
|
||||
using NUnit;
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x02000019 RID: 25
|
||||
[Serializable]
|
||||
public class disconnectend : MonoBehaviour
|
||||
{
|
||||
// Token: 0x0600005F RID: 95 RVA: 0x0000452C File Offset: 0x0000272C
|
||||
public disconnectend()
|
||||
|
||||
{
|
||||
this.timeOut = 5f;
|
||||
}
|
||||
|
||||
// Token: 0x06000060 RID: 96 RVA: 0x00004540 File Offset: 0x00002740
|
||||
public virtual void Awake()
|
||||
{
|
||||
this.Invoke("DestroyNow", this.timeOut);
|
||||
}
|
||||
|
||||
// Token: 0x06000061 RID: 97 RVA: 0x00004554 File Offset: 0x00002754
|
||||
public virtual void DestroyNow()
|
||||
{
|
||||
global::UnityEngine.Object.Destroy(this.gameObject);
|
||||
}
|
||||
|
||||
// Token: 0x06000062 RID: 98 RVA: 0x00004564 File Offset: 0x00002764
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x04000087 RID: 135
|
||||
public float timeOut;
|
||||
|
||||
// Token: 0x04000088 RID: 136
|
||||
public bool detachChildren;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f362b07f2e282d7c04d58dca023f61f5
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
// Token: 0x0200001A RID: 26
|
||||
[Serializable]
|
||||
public class disconnectendwon : MonoBehaviour
|
||||
{
|
||||
// Token: 0x06000063 RID: 99 RVA: 0x00004568 File Offset: 0x00002768
|
||||
public disconnectendwon()
|
||||
|
||||
{
|
||||
this.timeOut = 5f;
|
||||
}
|
||||
|
||||
// Token: 0x06000064 RID: 100 RVA: 0x0000457C File Offset: 0x0000277C
|
||||
public virtual void Awake()
|
||||
{
|
||||
this.Invoke("DestroyNow", this.timeOut);
|
||||
}
|
||||
|
||||
// Token: 0x06000065 RID: 101 RVA: 0x00004590 File Offset: 0x00002790
|
||||
public virtual void DestroyNow()
|
||||
{
|
||||
if (this.detachChildren)
|
||||
{
|
||||
this.transform.DetachChildren();
|
||||
}
|
||||
Network.Disconnect();
|
||||
MasterServer.UnregisterHost();
|
||||
Application.LoadLevel(10);
|
||||
}
|
||||
|
||||
// Token: 0x06000066 RID: 102 RVA: 0x000045BC File Offset: 0x000027BC
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x04000089 RID: 137
|
||||
public float timeOut;
|
||||
|
||||
// Token: 0x0400008A RID: 138
|
||||
public bool detachChildren;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a678c4057c88e940b11f4ae5ad3446b4
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class disconnect_0026end : MonoBehaviour
|
||||
{
|
||||
public float timeOut;
|
||||
|
||||
public bool detachChildren;
|
||||
|
||||
public disconnect_0026end()
|
||||
{
|
||||
timeOut = 5f;
|
||||
}
|
||||
|
||||
public virtual void Awake()
|
||||
{
|
||||
Invoke("DestroyNow", timeOut);
|
||||
}
|
||||
|
||||
public virtual void DestroyNow()
|
||||
{
|
||||
UnityEngine.Object.Destroy(gameObject);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5e48a851991fa324baef0e9f09d34f8c
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class disconnect_0026endwon : MonoBehaviour
|
||||
{
|
||||
public float timeOut;
|
||||
|
||||
public bool detachChildren;
|
||||
|
||||
public disconnect_0026endwon()
|
||||
{
|
||||
timeOut = 5f;
|
||||
}
|
||||
|
||||
public virtual void Awake()
|
||||
{
|
||||
Invoke("DestroyNow", timeOut);
|
||||
}
|
||||
|
||||
public virtual void DestroyNow()
|
||||
{
|
||||
if (detachChildren)
|
||||
{
|
||||
transform.DetachChildren();
|
||||
}
|
||||
Network.Disconnect();
|
||||
MasterServer.UnregisterHost();
|
||||
Application.LoadLevel(10);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 01d9373ba10755c45bb2933a2ea16ea9
|
||||
timeCreated: 1757101944
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class flashlight : MonoBehaviour
|
||||
{
|
||||
public GameObject flashLight;
|
||||
|
||||
public AudioClip switchsound;
|
||||
|
||||
public bool Paused;
|
||||
|
||||
public Light myLight;
|
||||
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown("f"))
|
||||
{
|
||||
myLight.enabled = !myLight.enabled;
|
||||
GetComponent<AudioSource>().PlayOneShot(switchsound);
|
||||
}
|
||||
if (Input.GetMouseButtonDown(1))
|
||||
{
|
||||
myLight.enabled = !myLight.enabled;
|
||||
GetComponent<AudioSource>().PlayOneShot(switchsound);
|
||||
}
|
||||
if (Input.GetKeyDown("h"))
|
||||
{
|
||||
Cursor.visible = false;
|
||||
}
|
||||
if (Input.GetKeyDown("g"))
|
||||
{
|
||||
Cursor.visible = false;
|
||||
}
|
||||
}
|
||||
|
||||
public void Start()
|
||||
{
|
||||
|
||||
myLight = flashLight.GetComponent<Light>();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2efb1b59705de584216d4672f56f8b3d
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,167 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Boo.Lang;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class hooverscript : MonoBehaviour
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024Slow_002450 : GenericGenerator<WaitForSeconds>
|
||||
{
|
||||
[Serializable]
|
||||
internal sealed class _0024 : GenericGeneratorEnumerator<WaitForSeconds>, IEnumerator
|
||||
{
|
||||
internal hooverscript _0024self__002451;
|
||||
|
||||
public _0024(hooverscript self_)
|
||||
{
|
||||
_0024self__002451 = self_;
|
||||
}
|
||||
|
||||
public override bool MoveNext()
|
||||
{
|
||||
int result;
|
||||
switch (_state)
|
||||
{
|
||||
default:
|
||||
if (!_0024self__002451.slowState)
|
||||
{
|
||||
_0024self__002451.accelState = false;
|
||||
_0024self__002451.slowState = true;
|
||||
}
|
||||
_0024self__002451.currentSpeed *= _0024self__002451.inertia;
|
||||
_0024self__002451.transform.Translate(0f, 0f, Time.deltaTime * _0024self__002451.currentSpeed);
|
||||
if (!(_0024self__002451.currentSpeed > _0024self__002451.minSpeed))
|
||||
{
|
||||
_0024self__002451.currentSpeed = 0f;
|
||||
result = (Yield(2, new WaitForSeconds(_0024self__002451.stopTime)) ? 1 : 0);
|
||||
break;
|
||||
}
|
||||
goto IL_00d6;
|
||||
case 2:
|
||||
_0024self__002451.functionState = 0;
|
||||
goto IL_00d6;
|
||||
case 1:
|
||||
{
|
||||
result = 0;
|
||||
break;
|
||||
}
|
||||
IL_00d6:
|
||||
YieldDefault(1);
|
||||
goto case 1;
|
||||
}
|
||||
return (byte)result != 0;
|
||||
}
|
||||
}
|
||||
|
||||
internal hooverscript _0024self__002452;
|
||||
|
||||
public _0024Slow_002450(hooverscript self_)
|
||||
{
|
||||
_0024self__002452 = self_;
|
||||
}
|
||||
|
||||
public override IEnumerator<WaitForSeconds> GetEnumerator()
|
||||
{
|
||||
return new _0024(_0024self__002452);
|
||||
}
|
||||
}
|
||||
|
||||
public float accel;
|
||||
|
||||
public float inertia;
|
||||
|
||||
public float speedLimit;
|
||||
|
||||
public float minSpeed;
|
||||
|
||||
public float stopTime;
|
||||
|
||||
private float currentSpeed;
|
||||
|
||||
private int functionState;
|
||||
|
||||
private bool accelState;
|
||||
|
||||
private bool slowState;
|
||||
|
||||
private Transform waypoint;
|
||||
|
||||
public float rotationDamping;
|
||||
|
||||
public bool smoothRotation;
|
||||
|
||||
public Transform[] waypoints;
|
||||
|
||||
private int WPindexPointer;
|
||||
|
||||
public hooverscript()
|
||||
{
|
||||
accel = 0.8f;
|
||||
inertia = 0.9f;
|
||||
speedLimit = 10f;
|
||||
minSpeed = 1f;
|
||||
stopTime = 1f;
|
||||
rotationDamping = 6f;
|
||||
smoothRotation = true;
|
||||
}
|
||||
|
||||
public virtual void Start()
|
||||
{
|
||||
functionState = 0;
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (functionState == 0)
|
||||
{
|
||||
Accell();
|
||||
}
|
||||
if (functionState == 1)
|
||||
{
|
||||
StartCoroutine(Slow());
|
||||
}
|
||||
waypoint = waypoints[WPindexPointer];
|
||||
}
|
||||
|
||||
public virtual void Accell()
|
||||
{
|
||||
if (!accelState)
|
||||
{
|
||||
accelState = true;
|
||||
slowState = false;
|
||||
}
|
||||
if ((bool)waypoint && smoothRotation)
|
||||
{
|
||||
Quaternion to = Quaternion.LookRotation(waypoint.position - transform.position);
|
||||
transform.rotation = Quaternion.Slerp(transform.rotation, to, Time.deltaTime * rotationDamping);
|
||||
}
|
||||
currentSpeed += accel * accel;
|
||||
transform.Translate(0f, 0f, Time.deltaTime * currentSpeed);
|
||||
if (!(currentSpeed < speedLimit))
|
||||
{
|
||||
currentSpeed = speedLimit;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void OnTriggerEnter()
|
||||
{
|
||||
functionState = 1;
|
||||
WPindexPointer++;
|
||||
if (WPindexPointer >= waypoints.Length)
|
||||
{
|
||||
WPindexPointer = 0;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual IEnumerator Slow()
|
||||
{
|
||||
return new _0024Slow_002450(this).GetEnumerator();
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b1e20861c9dbfd504925c68ebcee8494
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class lalascare : MonoBehaviour
|
||||
{
|
||||
[NonSerialized]
|
||||
public static int leverswitch;
|
||||
|
||||
public int trigger;
|
||||
|
||||
public Transform Player;
|
||||
|
||||
public GameObject animated;
|
||||
|
||||
public Transform dooractivater;
|
||||
|
||||
public AudioClip fallsound;
|
||||
|
||||
public lalascare()
|
||||
{
|
||||
trigger = 1;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerEnter(Collider other)
|
||||
{
|
||||
leverswitch = trigger;
|
||||
Player.parent = null;
|
||||
animated.GetComponent<Animation>().Play("scare2");
|
||||
animated.GetComponent<AudioSource>().PlayOneShot(fallsound);
|
||||
bool flag = false;
|
||||
}
|
||||
|
||||
public virtual void OnTriggerExit(Collider other)
|
||||
{
|
||||
UnityEngine.Object.Destroy(gameObject);
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d4901cf4bb235f46145eb14017ad2579
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,27 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class map : MonoBehaviour
|
||||
{
|
||||
public Texture2D yourtexture;
|
||||
|
||||
public GameObject objecttodestroy;
|
||||
|
||||
public virtual void OnGUI()
|
||||
{
|
||||
GUI.DrawTexture(new Rect(0f, 0f, Screen.width, Screen.height), yourtexture);
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyUp("m"))
|
||||
{
|
||||
UnityEngine.Object.Destroy(objecttodestroy, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 52c6f956567cc6deac735afcaf3f4721
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class mappopup : MonoBehaviour
|
||||
{
|
||||
public Transform ifseesobject;
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (Input.GetKeyDown("m"))
|
||||
{
|
||||
UnityEngine.Object.Instantiate(ifseesobject, transform.position, transform.rotation);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 19510ce84c82dc1b8d6bd77d47266c1e
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class nightvision : MonoBehaviour
|
||||
{
|
||||
public GameObject flashlight;
|
||||
|
||||
public AudioClip switchsound;
|
||||
|
||||
public Light myLight;
|
||||
|
||||
public nightvision()
|
||||
{
|
||||
myLight = (Light)flashlight.GetComponent("Light");
|
||||
}
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
if (GetComponent<NetworkView>().isMine && Input.GetKeyDown("n"))
|
||||
{
|
||||
myLight.enabled = !myLight.enabled;
|
||||
GetComponent<AudioSource>().PlayOneShot(switchsound);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5e68bbbe6e9c6d03eff9f833e02a8e63
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,93 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class playerwalkingsound : MonoBehaviour
|
||||
{
|
||||
public AudioClip walkingsound;
|
||||
|
||||
public AnimationClip walkAnimation;
|
||||
|
||||
public virtual void Update()
|
||||
{
|
||||
Transform transform = GameObject.FindWithTag("Player").transform;
|
||||
GetComponent<AudioSource>().clip = walkingsound;
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
if (Input.GetKeyDown(KeyCode.W))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.W))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.S))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.S))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.A))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.A))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.D))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.D))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.UpArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.UpArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.DownArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.DownArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.LeftArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.LeftArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
if (Input.GetKeyDown(KeyCode.RightArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Play();
|
||||
GetComponent<AudioSource>().loop = true;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.RightArrow))
|
||||
{
|
||||
GetComponent<AudioSource>().Stop();
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2bcb5fa8b6562ab03e55be2b737be007
|
||||
timeCreated: 1757099056
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
name:
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {fileID: 0}
|
||||
userData:
|
||||
@@ -0,0 +1,39 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
[Serializable]
|
||||
public class setqualitylevel : MonoBehaviour
|
||||
{
|
||||
public virtual void OnGUI()
|
||||
{
|
||||
GUI.Box(new Rect(10f, 10f, 200f, 1000f), "Graphics Resolution");
|
||||
if (GUI.Button(new Rect(20f, 40f, 80f, 20f), "Fastest"))
|
||||
{
|
||||
QualitySettings.currentLevel = QualityLevel.Fastest;
|
||||
}
|
||||
if (GUI.Button(new Rect(20f, 70f, 80f, 20f), "Fast"))
|
||||
{
|
||||
QualitySettings.currentLevel = QualityLevel.Fast;
|
||||
}
|
||||
if (GUI.Button(new Rect(20f, 100f, 80f, 20f), "Simple"))
|
||||
{
|
||||
QualitySettings.currentLevel = QualityLevel.Simple;
|
||||
}
|
||||
if (GUI.Button(new Rect(20f, 130f, 80f, 20f), "Good"))
|
||||
{
|
||||
QualitySettings.currentLevel = QualityLevel.Good;
|
||||
}
|
||||
if (GUI.Button(new Rect(20f, 160f, 80f, 20f), "Beautiful"))
|
||||
{
|
||||
QualitySettings.currentLevel = QualityLevel.Beautiful;
|
||||
}
|
||||
if (GUI.Button(new Rect(20f, 190f, 80f, 20f), "Fantastic"))
|
||||
{
|
||||
QualitySettings.currentLevel = QualityLevel.Fantastic;
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Main()
|
||||
{
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user