小修改

This commit is contained in:
GL 2024-11-22 09:27:28 +08:00
parent 357a87ca1e
commit ce7914b5c4
2 changed files with 26 additions and 0 deletions

View File

@ -325,6 +325,7 @@ public class AllHouseContro : MonoBehaviour
}
}
//击杀刷新房间蛋
//checkOutAllTheEscapeRoomsAsync();

View File

@ -2,6 +2,7 @@ using System.Collections;
using System.Collections.Generic;
using System.Threading.Tasks;
using UnityEngine;
using static UnityEngine.UIElements.UxmlAttributeDescription;
public class Allother : MonoBehaviour
{
@ -12,6 +13,7 @@ public class Allother : MonoBehaviour
public AllHouseContro allHouseContro;
public List<GameObject> JiaWoniu;//场下留下的假蜗牛
public Transform ReTurnPos;//返回点
// Start is called before the first frame update
void Start()
{
@ -34,6 +36,9 @@ public class Allother : MonoBehaviour
// }
// }
public void Reflash()//假蜗牛随机
{
foreach (GameObject go in JiaWoniu)
@ -61,6 +66,26 @@ public class Allother : MonoBehaviour
}
//清空指定房间蜗牛
public void KilltheWoniu(int killNo)
{
for (int i=0;i<allHouseContro.HouseBtnList.Count;i++)
{
if (allHouseContro.HouseBtnList[i].roomNo==killNo)
{
for (int j = 0; j< allHouseContro.HouseBtnList[i].otherWonius.Count; j++)
{
Destroy(allHouseContro.HouseBtnList[i].otherWonius[i].gameObject);
}
allHouseContro.HouseBtnList[i].otherWonius.Clear();
}
}
}
public void CreateWoniu()
{
foreach (HouseBtn house in allHouseContro.HouseBtnList)