6.12晚上
This commit is contained in:
parent
c78c8a12d2
commit
61c1974b04
|
@ -11,7 +11,7 @@ public class JunctionBox : MonoBehaviour
|
|||
public Transform TransparentlidObj;
|
||||
|
||||
/// <summary>
|
||||
/// 端子排上所有封印螺丝
|
||||
/// 端子排上所有封印和螺丝
|
||||
/// </summary>
|
||||
public GameObject[] allObjects;
|
||||
|
||||
|
|
|
@ -4,14 +4,24 @@ using UnityEngine;
|
|||
|
||||
public class Ladder : MonoBehaviour
|
||||
{
|
||||
public static Ladder instance;
|
||||
SkinnedMeshRenderer smr;
|
||||
float weight;
|
||||
bool show = false;
|
||||
|
||||
public void Awake()
|
||||
{
|
||||
instance = this;
|
||||
}
|
||||
public void Init()
|
||||
{
|
||||
smr = transform.GetComponent<SkinnedMeshRenderer>();
|
||||
show = true;
|
||||
}
|
||||
public void closed()
|
||||
{
|
||||
show = false;
|
||||
}
|
||||
void Update()
|
||||
{
|
||||
if (show == false)
|
||||
|
|
|
@ -114,12 +114,12 @@ Material:
|
|||
- _UVSec: 0
|
||||
- _ZWrite: 1
|
||||
- __dirty: 0
|
||||
- _step_p1: 1
|
||||
- _step_p2: 1
|
||||
- _step_p3: 1
|
||||
- _step_p4: 1
|
||||
- _step_p5: 1
|
||||
- _step_p6: 1
|
||||
- _step_p1: 0
|
||||
- _step_p2: 0
|
||||
- _step_p3: 0
|
||||
- _step_p4: 0
|
||||
- _step_p5: 0
|
||||
- _step_p6: 0
|
||||
m_Colors:
|
||||
- _BaseCol: {r: 0.23429155, g: 0.28497556, b: 0.3679245, a: 0}
|
||||
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -58,6 +58,21 @@ public class Screwdriver : MonoBehaviour
|
|||
/// </summary>
|
||||
public GameObject HubCoverObj;
|
||||
|
||||
/// <summary>
|
||||
/// 集中器后边螺丝
|
||||
/// </summary>
|
||||
public GameObject[] ConcentratorScrewObj;
|
||||
|
||||
/// <summary>
|
||||
/// 集线器物体
|
||||
/// </summary>
|
||||
public Transform ConcentratorObj;
|
||||
|
||||
/// <summary>
|
||||
/// 电线前段胶带
|
||||
/// </summary>
|
||||
public Material TapeMar;
|
||||
|
||||
public InteractiveObjects[] interactiveObjects;
|
||||
|
||||
/// <summary>
|
||||
|
@ -74,6 +89,19 @@ public class Screwdriver : MonoBehaviour
|
|||
void Init()
|
||||
{
|
||||
ElectricWireBcr.enabled = false;
|
||||
ElectricWireSMR.SetBlendShapeWeight(0, 0);
|
||||
ElectricWireSMR.SetBlendShapeWeight(1, 0);
|
||||
ElectricWireSMR.SetBlendShapeWeight(2, 0);
|
||||
ElectricWireSMR.SetBlendShapeWeight(3, 0);
|
||||
ElectricWireSMR.SetBlendShapeWeight(4, 0);
|
||||
ElectricWireSMR.SetBlendShapeWeight(5, 0);
|
||||
TapeMar.SetFloat("_step_p1", 0);
|
||||
TapeMar.SetFloat("_step_p2", 0);
|
||||
TapeMar.SetFloat("_step_p3", 0);
|
||||
TapeMar.SetFloat("_step_p4", 0);
|
||||
TapeMar.SetFloat("_step_p5", 0);
|
||||
TapeMar.SetFloat("_step_p6", 0);
|
||||
//TapeMar.SetFloat("_step_p1", 1);
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
|
@ -114,15 +142,25 @@ public class Screwdriver : MonoBehaviour
|
|||
StartCoroutine(IEHubSegmentRowScrews());
|
||||
ScrewObj[i].gameObject.SetActive(false);
|
||||
}
|
||||
//if (!ScrewObj[i].gameObject.activeInHierarchy)
|
||||
//{
|
||||
// StartCoroutine(IEElectricWire());
|
||||
//}
|
||||
}
|
||||
if (hit.collider.gameObject.name == "固定螺丝_Rdown")
|
||||
{
|
||||
Debug.Log(hit.collider.gameObject.name);
|
||||
StartCoroutine(IEHubSegmentRowScrews());
|
||||
ConcentratorScrewObj[0].SetActive(false);
|
||||
ConcentratorScrewObj[1].SetActive(false);
|
||||
}
|
||||
if (hit.collider.gameObject.name == "集电器固定螺丝_Ldown")
|
||||
{
|
||||
Debug.Log(hit.collider.gameObject.name);
|
||||
StartCoroutine(IEHubSegmentRowScrews());
|
||||
ConcentratorScrewObj[2].SetActive(false);
|
||||
ConcentratorScrewObj[3].SetActive(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
//集中器螺丝全隐藏后播放电线动画
|
||||
if (AreAllObjectsHidden())
|
||||
if (AreAllObjectsHidden()&& concentrator.isPlayAni)
|
||||
{
|
||||
StartCoroutine(ScrewdriverBack());
|
||||
ElectricWireBcr.enabled = true;
|
||||
|
@ -135,6 +173,10 @@ public class Screwdriver : MonoBehaviour
|
|||
HubCoverObj.gameObject.transform.DOLocalMove(new Vector3(0, 0.0167f, -0.2387f),1);
|
||||
Debug.Log("所有集线器盖子螺丝都已隐藏");
|
||||
}
|
||||
if (ConcentratorScrew())
|
||||
{
|
||||
StartCoroutine(IEConcentratorScrew());
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -143,15 +185,14 @@ public class Screwdriver : MonoBehaviour
|
|||
/// <returns></returns>
|
||||
public bool AreAllObjectsHidden()
|
||||
{
|
||||
// 检查每个对象的激活状态
|
||||
foreach (GameObject obj in ScrewObj)
|
||||
{
|
||||
if (obj.activeInHierarchy) // 使用 activeInHierarchy 如果你想检查对象是否在其父级结构中被激活
|
||||
if (obj.activeInHierarchy)
|
||||
{
|
||||
return false; // 如果找到任何一个激活的对象,返回false
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true; // 如果所有对象都未激活,返回true
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -160,16 +201,32 @@ public class Screwdriver : MonoBehaviour
|
|||
/// <returns></returns>
|
||||
public bool AllHubOfHubs()
|
||||
{
|
||||
// 检查每个对象的激活状态
|
||||
foreach (GameObject obj in concentratorScrew)
|
||||
{
|
||||
if (obj.activeInHierarchy) // 使用 activeInHierarchy 如果你想检查对象是否在其父级结构中被激活
|
||||
if (obj.activeInHierarchy)
|
||||
{
|
||||
return false; // 如果找到任何一个激活的对象,返回false
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true; // 如果所有对象都未激活,返回true
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 集中器后部四颗螺丝
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public bool ConcentratorScrew()
|
||||
{
|
||||
foreach (GameObject obj in ConcentratorScrewObj)
|
||||
{
|
||||
if (obj.activeInHierarchy)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 螺丝刀返回动画
|
||||
/// </summary>
|
||||
|
@ -294,6 +351,21 @@ public class Screwdriver : MonoBehaviour
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 集中器背后螺丝
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
IEnumerator IEConcentratorScrew()
|
||||
{
|
||||
ConcentratorObj.gameObject.transform.DOLocalMove(new Vector3(-0.2719f, 2.24768f, -0.0772f), 0.5f);
|
||||
yield return new WaitForSeconds(1);
|
||||
ConcentratorObj.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 螺丝刀移动到集中器旁动画
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
IEnumerator IEHubSegmentRowScrews()
|
||||
{
|
||||
ScrewdriverTrans.gameObject.transform.DOLocalMove(new Vector3(3.1215f, 2.1383f, -1.3484f),0.5f);
|
||||
|
|
|
@ -11,7 +11,7 @@ namespace ToolsPack
|
|||
{
|
||||
this.GetComponent<Button>().onClick.AddListener(delegate
|
||||
{
|
||||
SceneManager.LoadScene("现场");
|
||||
SceneManager.LoadScene("现场 _Test");
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 49 KiB |
|
@ -0,0 +1,114 @@
|
|||
fileFormatVersion: 2
|
||||
guid: c393796320cdae04bb4f18044f65bc14
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 12
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
flipGreenChannel: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMipmapLimit: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 0
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
swizzle: 50462976
|
||||
cookieLightType: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
ignorePlatformSupport: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
- serializedVersion: 3
|
||||
buildTarget: Standalone
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
ignorePlatformSupport: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
nameFileIdTable: {}
|
||||
mipmapLimitGroupName:
|
||||
pSDRemoveMatte: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,161 @@
|
|||
using DG.Tweening;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class concentrator : MonoBehaviour
|
||||
{
|
||||
/// <summary>
|
||||
/// 集中器
|
||||
/// </summary>
|
||||
public GameObject concentratorObj;
|
||||
|
||||
/// <summary>
|
||||
/// 集中器端子螺丝
|
||||
/// </summary>
|
||||
public GameObject[] ScrewObj;
|
||||
|
||||
/// <summary>
|
||||
/// 集线盒电线动画
|
||||
/// </summary>
|
||||
public SkinnedMeshRenderer ElectricWireSMR;
|
||||
|
||||
/// <summary>
|
||||
/// 电线碰撞
|
||||
/// </summary>
|
||||
public BoxCollider TapeMarCol;
|
||||
|
||||
/// <summary>
|
||||
/// 电线前段胶带
|
||||
/// </summary>
|
||||
public Material TapeMar;
|
||||
/// <summary>
|
||||
/// 螺丝是否全部显示
|
||||
/// </summary>
|
||||
int allls;
|
||||
/// <summary>
|
||||
/// 是否播放集线器螺丝拆完后电线动画
|
||||
/// </summary>
|
||||
public static bool isPlayAni = true;
|
||||
|
||||
bool isplaying = true;
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
if (Input.GetMouseButtonDown(0))
|
||||
{//Camera.transform.forward
|
||||
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
|
||||
RaycastHit hit;
|
||||
bool raycast = Physics.Raycast(ray, out hit);
|
||||
if (raycast)
|
||||
{
|
||||
if (hit.collider.gameObject.name == "新的集中器碰撞")
|
||||
{
|
||||
StartCoroutine(Newconcentrator());
|
||||
Debug.Log(hit.collider.gameObject.name);
|
||||
}
|
||||
for (int i = 0; i < ScrewObj.Length; i++)
|
||||
{
|
||||
if (hit.collider.gameObject.name == ScrewObj[i].name)
|
||||
{
|
||||
Debug.Log(hit.collider.gameObject.name);
|
||||
//StartCoroutine(IEHubSegmentRowScrews());
|
||||
ScrewObj[i].GetComponent<MeshRenderer>().enabled = true;
|
||||
}
|
||||
}
|
||||
if (hit.collider.gameObject.name == "pCylinder170")
|
||||
{
|
||||
if (isplaying)
|
||||
{
|
||||
StartCoroutine(IEElectricWire());
|
||||
isplaying = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (AreAllObjectsHidden())
|
||||
{
|
||||
isPlayAni = false;
|
||||
StartCoroutine(TapeBack());
|
||||
Debug.Log("所有螺丝都显示");
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 新集中器螺丝
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public bool AreAllObjectsHidden()
|
||||
{
|
||||
allls = 0;
|
||||
for (int i = 0; i < ScrewObj.Length; i++)
|
||||
{
|
||||
if (ScrewObj[i].gameObject.GetComponent<MeshRenderer>().enabled)
|
||||
{
|
||||
allls++;
|
||||
}
|
||||
}
|
||||
if (allls >= ScrewObj.Length - 1)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 集线器上线动画
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
IEnumerator Newconcentrator()
|
||||
{
|
||||
concentratorObj.gameObject.transform.DOLocalMove(new Vector3(3.0778f, 2.2149f, -1.4581f), 1f);
|
||||
yield return new WaitForSeconds(1.0f);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 集线器上线动画
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
IEnumerator IEElectricWire()
|
||||
{
|
||||
TapeMarCol.enabled = false;
|
||||
for (int i = 0; i < 6; i++)
|
||||
{
|
||||
for (int a = 100; a >= 0; a--)
|
||||
{
|
||||
yield return new WaitForSeconds(0.01f);
|
||||
ElectricWireSMR.SetBlendShapeWeight(i, a);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 胶带还原动画
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
IEnumerator TapeBack()
|
||||
{
|
||||
TapeMarCol.enabled = true;
|
||||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p6", 0);
|
||||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p5", 0);
|
||||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p4", 0);
|
||||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p3", 0);
|
||||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p2", 0);
|
||||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p1", 0);
|
||||
yield return new WaitForSeconds(1f);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 7bb56f5280a99c74cbb2d948bdf3aef6
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -18,8 +18,18 @@ using UnityEngine;
|
|||
/// µçÏßǰ¶Î½º´ø
|
||||
/// </summary>
|
||||
public Material TapeMar;
|
||||
|
||||
/// <summary>
|
||||
/// 든窟툭旒
|
||||
/// </summary>
|
||||
public BoxCollider TapeMarCol;
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
Init();
|
||||
}
|
||||
|
||||
void Init()
|
||||
{
|
||||
TapeMar.SetFloat("_step_p1", 0);
|
||||
TapeMar.SetFloat("_step_p2", 0);
|
||||
|
@ -49,7 +59,7 @@ using UnityEngine;
|
|||
}
|
||||
|
||||
/// <summary>
|
||||
/// µçÏß²ø
|
||||
/// 든窟끌스던
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
IEnumerator Tape()
|
||||
|
@ -68,6 +78,7 @@ using UnityEngine;
|
|||
yield return new WaitForSeconds(1f);
|
||||
TapeMar.SetFloat("_step_p6", 1);
|
||||
yield return new WaitForSeconds(1f);
|
||||
|
||||
StartCoroutine(TapeBack());
|
||||
}
|
||||
|
||||
|
@ -78,8 +89,7 @@ using UnityEngine;
|
|||
IEnumerator TapeBack()
|
||||
{
|
||||
TapeOBJ.transform.DOLocalMove(new Vector3(3.179443f, 1.790938f, -1.107346f),1f);
|
||||
yield return null;
|
||||
TapeMarCol.enabled = false;
|
||||
yield return new WaitForSeconds(1f);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,96 @@
|
|||
using MotionFramework;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
/// <summary>
|
||||
/// 点击背包中的物品显示物体
|
||||
/// </summary>
|
||||
public class DisplayKnapsackObjects : MonoBehaviour
|
||||
{
|
||||
public GameObject[] Tool;
|
||||
|
||||
/// <summary>
|
||||
/// 放回背包按钮
|
||||
/// </summary>
|
||||
public Button PutBack;
|
||||
|
||||
/// <summary>
|
||||
/// 梯子动画
|
||||
/// </summary>
|
||||
public SkinnedMeshRenderer LadderSkr;
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
MotionEngine.GetModule<ToolsPackManager>().OnStringEvent += HandleStringEvent;
|
||||
PutBack.onClick.AddListener(() => {
|
||||
if (Tool[0].activeInHierarchy)
|
||||
{
|
||||
Tool[0].gameObject.SetActive(false);
|
||||
Ladder.instance.closed();
|
||||
}
|
||||
if (Tool[1].activeInHierarchy)
|
||||
{
|
||||
Tool[1].gameObject.SetActive(false);
|
||||
}
|
||||
if (Tool[2].activeInHierarchy)
|
||||
{
|
||||
Tool[2].gameObject.SetActive(false);
|
||||
}
|
||||
if (Tool[3].activeInHierarchy)
|
||||
{
|
||||
Tool[3].gameObject.SetActive(false);
|
||||
}
|
||||
if (Tool[4].activeInHierarchy)
|
||||
{
|
||||
Tool[4].gameObject.SetActive(false);
|
||||
}
|
||||
if (Tool[5].activeInHierarchy)
|
||||
{
|
||||
Tool[5].gameObject.SetActive(false);
|
||||
}
|
||||
if (Tool[6].activeInHierarchy)
|
||||
{
|
||||
Tool[6].gameObject.SetActive(false);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
private void HandleStringEvent(string message)
|
||||
{
|
||||
if (message == "梯子")
|
||||
{
|
||||
Tool[0].gameObject.SetActive(true);
|
||||
Ladder.instance.Init();
|
||||
}
|
||||
if (message == "工作证")
|
||||
{
|
||||
Tool[1].gameObject.SetActive(true);
|
||||
}
|
||||
if (message == "剥线钳")
|
||||
{
|
||||
Tool[2].gameObject.SetActive(true);
|
||||
}
|
||||
if (message == "验电笔")
|
||||
{
|
||||
Tool[3].gameObject.SetActive(true);
|
||||
}
|
||||
if (message == "螺丝刀")
|
||||
{
|
||||
Tool[4].gameObject.SetActive(true);
|
||||
}
|
||||
if (message == "绝缘胶带")
|
||||
{
|
||||
Tool[5].gameObject.SetActive(true);
|
||||
}
|
||||
|
||||
if (message == "l型集中器")
|
||||
{
|
||||
Tool[6].gameObject.SetActive(true);
|
||||
}
|
||||
Debug.Log("Received message: " + message);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
fileFormatVersion: 2
|
||||
guid: e33923dee0d2a0f4f81ca859f6fc70d5
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Loading…
Reference in New Issue