This commit is contained in:
hyskai 2024-11-05 04:03:26 +08:00
parent 2dc8687b04
commit 4088949c52
7 changed files with 39 additions and 30 deletions

View File

@ -2197,6 +2197,7 @@ MonoBehaviour:
BlackRoom: {fileID: 982477524}
Boom: {fileID: 1998930180334184709, guid: 1af55f3362cdbd643937d48b138bef77, type: 3}
ids: []
toolids: []
--- !u!1 &379972120
GameObject:
m_ObjectHideFlags: 0
@ -5935,6 +5936,7 @@ MonoBehaviour:
BlackRoom: {fileID: 314702314}
Boom: {fileID: 1998930180334184709, guid: 1af55f3362cdbd643937d48b138bef77, type: 3}
ids: []
toolids: []
--- !u!1 &1058917053
GameObject:
m_ObjectHideFlags: 0
@ -7061,6 +7063,7 @@ MonoBehaviour:
BlackRoom: {fileID: 64041271}
Boom: {fileID: 1998930180334184709, guid: 1af55f3362cdbd643937d48b138bef77, type: 3}
ids: []
toolids: []
--- !u!1 &1267245798
GameObject:
m_ObjectHideFlags: 0
@ -10185,6 +10188,7 @@ MonoBehaviour:
BlackRoom: {fileID: 927504749}
Boom: {fileID: 1998930180334184709, guid: 1af55f3362cdbd643937d48b138bef77, type: 3}
ids: []
toolids: []
--- !u!1 &1625551201
GameObject:
m_ObjectHideFlags: 0
@ -10889,6 +10893,7 @@ MonoBehaviour:
BlackRoom: {fileID: 1676301279}
Boom: {fileID: 1998930180334184709, guid: 1af55f3362cdbd643937d48b138bef77, type: 3}
ids: []
toolids: []
--- !u!1 &1747948505
GameObject:
m_ObjectHideFlags: 0

View File

@ -148,8 +148,7 @@ public class JinShaBuy : mount
int index1 = Num - 74;
int index2 = (Num - 74)*2;
rooms[index1].GetComponent<RoomJinsha>().addtools(index2, number);
// rooms[index1].GetComponent<RoomJinsha>().toolids.Add();
rooms[index1].GetComponent<RoomJinsha>().addtools(index2, number);
}
}
});

View File

@ -51,7 +51,7 @@ public class RoomJinsha : mount
ChangeTextPro();
//Debug.Log(this.gameObject.name+":"+this.type);
loding();
}
@ -242,28 +242,41 @@ public class RoomJinsha : mount
}
}
private async void Allminer()
private async void loding()
{
Login login = new Login();
login.Phone = "1";
await web.SendRequest(web.URL + "/Player/Login", "POST", JsonUtility.ToJson(login));
string response = await web.SendRequest(web.URL + "/MinerElf/GetList", "POST");
Debug.Log(response);
Response reslist = JsonUtility.FromJson<Response>(response);
string sponse = await web.SendRequest(web.URL + "/MinerElf/GetList", "POST");
Debug.Log(sponse);
for (int i = 0; i < reslist.List.Length; i++)
string response = await web.SendRequest(web.URL + "/MinerElfActive/GetListOfGem", "POST");
AllGemVocItemRes itemList = JsonUtility.FromJson<AllGemVocItemRes>(response);
for (int i = 0; i < itemList.List.Length; i++)
{
if (reslist.List[i].Type == 1)
if (itemList.List[i].Num == buy_type)
{
itemlist.Add(reslist.List[i]);
haveNumber += 1;
Debug.Log(this.gameObject.name + "¿ó¹¤ÊýÁ¿" + haveNumber);
}
}
toolsNumber = haveNumber;
ChangeTextPro();
for (int i = 0; i < haveNumber; i++)
{
GetRoom();
GameObject newMiner = GameObject.Instantiate(minerPrefab);
newMiner.transform.SetParent(startPos);
newMiner.transform.position =new Vector3(gold.position.x-0.5f,gold.position.y,gold.position.y);
}
}
private async void UseDaijinjuan()

View File

@ -74,8 +74,8 @@ public class jinsha : mount
if (type == item.Type)
{
boxTypes.Add(new BoxType { Name = index.ToString() + "Îı¾", prompt = "µÚ" + ArabicToChineseNumberConverter.ConvertToChineseNumbers(index.ToString()) + "²ã", Type = 4, is_required = true });
boxTypes.Add(new BoxType { Name = "矿工" + index.ToString(), prompt = item.Name, Type = 3, icon = icons[index - 1], customData = new BoxData<Item>(item) });
boxTypes.Add(new BoxType { Name = "挖矿设备" + index.ToString(), prompt = "挖矿设备·" + ArabicToChineseNumberConverter.ConvertToChineseNumbers(index.ToString()), Type = 3, icon = toolsicons[0],Num=73+index, customData = new BoxData<Item>(item) });
boxTypes.Add(new BoxType { Name = "矿工" + index.ToString(), prompt = item.Name,goldNumerobj=item.ActivateValue.ToString(), Type = 3, icon = icons[index - 1], customData = new BoxData<Item>(item) });
boxTypes.Add(new BoxType { Name = "挖矿设备" + index.ToString(), prompt = "挖矿设备·" + ArabicToChineseNumberConverter.ConvertToChineseNumbers(index.ToString()), Type = 3,goldNumerobj= itemDataList[73 + index].Gold.ToString(), icon = toolsicons[0],Num=73+index, customData = new BoxData<Item>(item) });
index++;
}
@ -170,7 +170,6 @@ public class jinsha : mount
{
if (type == 1)
{
//ÔùËÍÂß¼­
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
}

View File

@ -213,7 +213,7 @@ public class room : mount
GetRoom();
GameObject newMiner = GameObject.Instantiate(minerPrefab);
newMiner.transform.SetParent(startPos);
newMiner.transform.position = gold.position;
newMiner.transform.position = new Vector3(gold.position.x - 0.5f, gold.position.y, gold.position.y); ;
}
@ -237,13 +237,6 @@ public class room : mount
string aa = await web.SendRequest(web.URL + "/Voucher/Use", "POST", jsonString);
}
//¿ªÍØ·¿¼ä
void GetRoom()
{

View File

@ -116,7 +116,7 @@ public class boy_jinsha:mount
//获得所有
//"Type": 0捕鱼1挖矿2锻造
string userponse = await web.SendRequest(web.URL + "/Voucher/GetList", "POST");
Debug.Log(userponse);
//Debug.Log(userponse);
ResponseVoucher itemList = JsonUtility.FromJson<ResponseVoucher>(userponse);
voucheList = new List<VoucherItem>();
foreach (VoucherItem item in itemList.List)

View File

@ -53,7 +53,7 @@ public class shopman :mount
if (type == item.Type && item.Num == 1 || type == item.Type && item.Num == 4 || type == item.Type && item.Num == 7)
{
boxTypes.Add(new BoxType { Name = index.ToString() + "Îı¾", prompt = "µÚ" + ArabicToChineseNumberConverter.ConvertToChineseNumbers(index.ToString()) + "²ã", Type = 4, is_required = true });
boxTypes.Add(new BoxType { Name = "˛śÓă" + index.ToString(), prompt = item.Name, Type = 3, icon =iconS[index -1],customData = new BoxData<BuyuItem>(item) });
boxTypes.Add(new BoxType { Name = "²¶Óã" + index.ToString(), prompt = item.Name, Type = 3, goldNumerobj = item.ActivateValue.ToString(),icon =iconS[index -1],customData = new BoxData<BuyuItem>(item) });
index++;
}