This commit is contained in:
陈向学 2024-08-26 20:29:15 +08:00
parent da661a3881
commit cd484b2110
2 changed files with 33 additions and 15 deletions

View File

@ -51,6 +51,8 @@ public class Device_3Phase4WireMeter : Device_Base
JieXianScrewInstallState();
//铭牌
namePlate.isChecked = false;
//固定螺丝拧上状态
FixScrewInstall();
gameObject.SetActive(true);
}
else
@ -60,6 +62,8 @@ public class Device_3Phase4WireMeter : Device_Base
CoverUnstallState();
//接线螺丝拧下状态
JieXianScrewUninstallState();
//固定螺丝拧下状态
FixScrewUninstall();
gameObject.SetActive(false);
}
}
@ -84,13 +88,6 @@ public class Device_3Phase4WireMeter : Device_Base
//右封印被剪开
cover.cover_seal_Right.isCut = true;
cover.cover_seal_Right.gameObject.SetActive(false);
//左固定螺丝拧下
fix_screw_left.isInstall = false;
fix_screw_left.transform.localPosition = new Vector3(fix_screw_left.transform.localPosition.x, fix_screw_left.initPostionY - 0.03f, fix_screw_left.transform.localPosition.z);
//右固定螺丝拧下
fix_screw_right.isInstall = false;
fix_screw_right.transform.localPosition = new Vector3(fix_screw_right.transform.localPosition.x, fix_screw_right.initPostionY - 0.03f, fix_screw_right.transform.localPosition.z);
//接线螺丝全部拧下
}
/// <summary>
@ -113,13 +110,6 @@ public class Device_3Phase4WireMeter : Device_Base
//右封印安装
cover.cover_seal_Right.isCut = false;
cover.cover_seal_Right.gameObject.SetActive(true);
//左固定螺丝拧上
fix_screw_left.isInstall = true;
fix_screw_left.transform.localPosition = new Vector3(fix_screw_left.transform.localPosition.x, fix_screw_left.initPostionY, fix_screw_left.transform.localPosition.z);
//右固定螺丝拧上
fix_screw_right.isInstall = true;
fix_screw_right.transform.localPosition = new Vector3(fix_screw_right.transform.localPosition.x, fix_screw_right.initPostionY, fix_screw_right.transform.localPosition.z);
}
/// <summary>
/// 接线螺丝拧上状态
@ -144,6 +134,32 @@ public class Device_3Phase4WireMeter : Device_Base
a.transform.localPosition = new Vector3(a.transform.localPosition.x, a.initPostionY - 0.03f, a.transform.localPosition.z);
});
}
/// <summary>
/// 固定螺丝装上
/// </summary>
public void FixScrewInstall()
{
//左固定螺丝拧上
fix_screw_left.isInstall = true;
fix_screw_left.transform.localPosition = new Vector3(fix_screw_left.transform.localPosition.x, fix_screw_left.initPostionY, fix_screw_left.transform.localPosition.z);
//右固定螺丝拧上
fix_screw_right.isInstall = true;
fix_screw_right.transform.localPosition = new Vector3(fix_screw_right.transform.localPosition.x, fix_screw_right.initPostionY, fix_screw_right.transform.localPosition.z);
}
/// <summary>
/// 固定螺丝拧下
/// </summary>
public void FixScrewUninstall()
{
//左固定螺丝拧下
fix_screw_left.isInstall = false;
fix_screw_left.transform.localPosition = new Vector3(fix_screw_left.transform.localPosition.x, fix_screw_left.initPostionY - 0.03f, fix_screw_left.transform.localPosition.z);
//右固定螺丝拧下
fix_screw_right.isInstall = false;
fix_screw_right.transform.localPosition = new Vector3(fix_screw_right.transform.localPosition.x, fix_screw_right.initPostionY - 0.03f, fix_screw_right.transform.localPosition.z);
}
/// <summary>
/// 拆下电能表

View File

@ -151,6 +151,8 @@ public class StepState_1002 : StepState
{
//安装电能表
//固定螺丝拧下了
SiteManager.instance.measuringCabinet.meteringDevice.FixScrewUninstall();
//接线螺丝拧下了
SiteManager.instance.measuringCabinet.meteringDevice.JieXianScrewUninstallState();
//电能表接线取下了