add
This commit is contained in:
parent
dd956bbfee
commit
e595df5aa7
@ -715,7 +715,7 @@ MonoBehaviour:
|
|||||||
- {fileID: 21300000, guid: d4fbb32ff8543d443b74de2652100618, type: 3}
|
- {fileID: 21300000, guid: d4fbb32ff8543d443b74de2652100618, type: 3}
|
||||||
- {fileID: 21300000, guid: f6884187fb833964ea9e632b9d5a8252, type: 3}
|
- {fileID: 21300000, guid: f6884187fb833964ea9e632b9d5a8252, type: 3}
|
||||||
- {fileID: 21300000, guid: f79faf75d4e26b748958aaaf6c64cf56, type: 3}
|
- {fileID: 21300000, guid: f79faf75d4e26b748958aaaf6c64cf56, type: 3}
|
||||||
Thingid:
|
Thingid: 0
|
||||||
rooms:
|
rooms:
|
||||||
- {fileID: 361643069}
|
- {fileID: 361643069}
|
||||||
- {fileID: 1026708935}
|
- {fileID: 1026708935}
|
||||||
@ -744,6 +744,7 @@ MonoBehaviour:
|
|||||||
- {fileID: 1262522313}
|
- {fileID: 1262522313}
|
||||||
- {fileID: 1737182421}
|
- {fileID: 1737182421}
|
||||||
- {fileID: 1625391898}
|
- {fileID: 1625391898}
|
||||||
|
ids: []
|
||||||
--- !u!1 &138158026
|
--- !u!1 &138158026
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -2231,7 +2232,8 @@ Transform:
|
|||||||
m_LocalPosition: {x: -4.32, y: -1.85, z: -4}
|
m_LocalPosition: {x: -4.32, y: -1.85, z: -4}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children: []
|
m_Children:
|
||||||
|
- {fileID: 799288468}
|
||||||
m_Father: {fileID: 361643070}
|
m_Father: {fileID: 361643070}
|
||||||
m_RootOrder: 5
|
m_RootOrder: 5
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
@ -4814,6 +4816,75 @@ RectTransform:
|
|||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 100, y: 100}
|
m_SizeDelta: {x: 100, y: 100}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!1 &799288467
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 799288468}
|
||||||
|
- component: {fileID: 799288470}
|
||||||
|
- component: {fileID: 799288469}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: miner1(Clone)
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &799288468
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 799288467}
|
||||||
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
|
m_LocalPosition: {x: 6.9774723, y: 0.42249072, z: 5.4150186}
|
||||||
|
m_LocalScale: {x: 0.716264, y: 0.716264, z: 0.716264}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children:
|
||||||
|
- {fileID: 1416754134}
|
||||||
|
m_Father: {fileID: 379972121}
|
||||||
|
m_RootOrder: 0
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!114 &799288469
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 799288467}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 32c2f38a722aceb40980e1cdf8a6041a, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
animator: {fileID: 1416754135}
|
||||||
|
nowState: 0
|
||||||
|
probabilityOfStand: 0.4
|
||||||
|
probabilityOfMove: 0.3
|
||||||
|
probabilityOfDig: 0.3
|
||||||
|
ChangeStateTimer: 3
|
||||||
|
moveSpeed: 2
|
||||||
|
maxMovePos: {x: 2.6, y: 0.4, z: -3}
|
||||||
|
minMovePos: {x: -0.37, y: -0.15, z: -4}
|
||||||
|
digPosition: {x: 2.6, y: 0.2, z: -3}
|
||||||
|
digTime: 5
|
||||||
|
newV: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!210 &799288470
|
||||||
|
SortingGroup:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 799288467}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_SortingLayerID: 0
|
||||||
|
m_SortingLayer: 0
|
||||||
|
m_SortingOrder: 1
|
||||||
--- !u!1 &828208476
|
--- !u!1 &828208476
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -7875,6 +7946,112 @@ Transform:
|
|||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_RootOrder: 3
|
m_RootOrder: 3
|
||||||
m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
|
m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
|
||||||
|
--- !u!1 &1416754133
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 1416754134}
|
||||||
|
- component: {fileID: 1416754136}
|
||||||
|
- component: {fileID: 1416754135}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Square
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &1416754134
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1416754133}
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 0, y: 0.972, z: 0}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 799288468}
|
||||||
|
m_RootOrder: 0
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!95 &1416754135
|
||||||
|
Animator:
|
||||||
|
serializedVersion: 5
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1416754133}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_Avatar: {fileID: 0}
|
||||||
|
m_Controller: {fileID: 9100000, guid: 1633496a12ffc5a43b2c884de81064c1, type: 2}
|
||||||
|
m_CullingMode: 0
|
||||||
|
m_UpdateMode: 0
|
||||||
|
m_ApplyRootMotion: 0
|
||||||
|
m_LinearVelocityBlending: 0
|
||||||
|
m_StabilizeFeet: 0
|
||||||
|
m_WarningMessage:
|
||||||
|
m_HasTransformHierarchy: 1
|
||||||
|
m_AllowConstantClipSamplingOptimization: 1
|
||||||
|
m_KeepAnimatorStateOnDisable: 0
|
||||||
|
m_WriteDefaultValuesOnDisable: 0
|
||||||
|
--- !u!212 &1416754136
|
||||||
|
SpriteRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1416754133}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_CastShadows: 0
|
||||||
|
m_ReceiveShadows: 0
|
||||||
|
m_DynamicOccludee: 1
|
||||||
|
m_StaticShadowCaster: 0
|
||||||
|
m_MotionVectors: 1
|
||||||
|
m_LightProbeUsage: 1
|
||||||
|
m_ReflectionProbeUsage: 1
|
||||||
|
m_RayTracingMode: 0
|
||||||
|
m_RayTraceProcedural: 0
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_RendererPriority: 0
|
||||||
|
m_Materials:
|
||||||
|
- {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
|
m_StaticBatchInfo:
|
||||||
|
firstSubMesh: 0
|
||||||
|
subMeshCount: 0
|
||||||
|
m_StaticBatchRoot: {fileID: 0}
|
||||||
|
m_ProbeAnchor: {fileID: 0}
|
||||||
|
m_LightProbeVolumeOverride: {fileID: 0}
|
||||||
|
m_ScaleInLightmap: 1
|
||||||
|
m_ReceiveGI: 1
|
||||||
|
m_PreserveUVs: 0
|
||||||
|
m_IgnoreNormalsForChartDetection: 0
|
||||||
|
m_ImportantGI: 0
|
||||||
|
m_StitchLightmapSeams: 1
|
||||||
|
m_SelectedEditorRenderState: 0
|
||||||
|
m_MinimumChartSize: 4
|
||||||
|
m_AutoUVMaxDistance: 0.5
|
||||||
|
m_AutoUVMaxAngle: 89
|
||||||
|
m_LightmapParameters: {fileID: 0}
|
||||||
|
m_SortingLayerID: 0
|
||||||
|
m_SortingLayer: 0
|
||||||
|
m_SortingOrder: 0
|
||||||
|
m_Sprite: {fileID: 1679062413, guid: 8e4ba394e8569844caaefbadd38d117e, type: 3}
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_FlipX: 0
|
||||||
|
m_FlipY: 0
|
||||||
|
m_DrawMode: 0
|
||||||
|
m_Size: {x: 1, y: 1}
|
||||||
|
m_AdaptiveModeThreshold: 0.5
|
||||||
|
m_SpriteTileMode: 0
|
||||||
|
m_WasSpriteAssigned: 1
|
||||||
|
m_MaskInteraction: 0
|
||||||
|
m_SpriteSortPoint: 0
|
||||||
--- !u!1 &1438189709
|
--- !u!1 &1438189709
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -22,6 +22,7 @@ public class JinShaBuy : mount
|
|||||||
public int minerjiage = 0;
|
public int minerjiage = 0;
|
||||||
|
|
||||||
public List<GameObject> rooms;
|
public List<GameObject> rooms;
|
||||||
|
public List<string> ids = new List<string>();
|
||||||
|
|
||||||
public override void Awake()
|
public override void Awake()
|
||||||
{
|
{
|
||||||
@ -135,6 +136,7 @@ public class JinShaBuy : mount
|
|||||||
rooms[index1].GetComponent<RoomJinsha>().addman(index2, number);
|
rooms[index1].GetComponent<RoomJinsha>().addman(index2, number);
|
||||||
//Debug.Log(data.Ids[0]);
|
//Debug.Log(data.Ids[0]);
|
||||||
rooms[index1].GetComponent<RoomJinsha>().ids.Add(data.Ids[0]);
|
rooms[index1].GetComponent<RoomJinsha>().ids.Add(data.Ids[0]);
|
||||||
|
this.ids.Add(data.Ids[0]);
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -253,7 +253,7 @@ public class RoomJinsha : mount
|
|||||||
//Debug.Log(sponse);
|
//Debug.Log(sponse);
|
||||||
|
|
||||||
|
|
||||||
string response = await web.SendRequest(web.URL + "/MinerElfActive/GetListOfGem", "POST");
|
string response = await web.SendRequest(web.URL + "/MinerElfActive/GetListOfGold", "POST");
|
||||||
|
|
||||||
AllGemVocItemRes itemList = JsonUtility.FromJson<AllGemVocItemRes>(response);
|
AllGemVocItemRes itemList = JsonUtility.FromJson<AllGemVocItemRes>(response);
|
||||||
for (int i = 0; i < itemList.List.Length; i++)
|
for (int i = 0; i < itemList.List.Length; i++)
|
||||||
@ -261,7 +261,7 @@ public class RoomJinsha : mount
|
|||||||
if (itemList.List[i].Num == buy_type)
|
if (itemList.List[i].Num == buy_type)
|
||||||
{
|
{
|
||||||
haveNumber += 1;
|
haveNumber += 1;
|
||||||
Debug.Log(this.gameObject.name + "矿工数量" + haveNumber);
|
// Debug.Log(this.gameObject.name + "矿工数量" + haveNumber);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
toolsNumber = haveNumber;
|
toolsNumber = haveNumber;
|
||||||
@ -272,7 +272,7 @@ public class RoomJinsha : mount
|
|||||||
GetRoom();
|
GetRoom();
|
||||||
GameObject newMiner = GameObject.Instantiate(minerPrefab);
|
GameObject newMiner = GameObject.Instantiate(minerPrefab);
|
||||||
newMiner.transform.SetParent(startPos);
|
newMiner.transform.SetParent(startPos);
|
||||||
newMiner.transform.position =new Vector3(gold.position.x-0.5f,gold.position.y,gold.position.y);
|
newMiner.transform.position =new Vector3(gold.position.x-1.5f,gold.position.y-0.5f,gold.position.y);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -286,7 +286,7 @@ public class RoomJinsha : mount
|
|||||||
ids.RemoveAt(ids.Count - 1);
|
ids.RemoveAt(ids.Count - 1);
|
||||||
string jsonString = JsonUtility.ToJson(use);
|
string jsonString = JsonUtility.ToJson(use);
|
||||||
string aa = await web.SendRequest(web.URL + "/Voucher/Use", "POST", jsonString);
|
string aa = await web.SendRequest(web.URL + "/Voucher/Use", "POST", jsonString);
|
||||||
Debug.Log(aa);
|
//Debug.Log(aa);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -174,18 +174,15 @@ public class jinsha : mount
|
|||||||
{
|
{
|
||||||
//ÔùËÍÂß¼
|
//ÔùËÍÂß¼
|
||||||
Giveaway giveaway = new Giveaway();
|
Giveaway giveaway = new Giveaway();
|
||||||
Debug.LogError(Thingid);
|
Debug.Log(go.ids.Count);
|
||||||
List<string> go = rooms[Thingid].GetComponent<RoomJinsha>().ids;
|
string[] sstr = { go.ids[go.ids.Count - 1] };
|
||||||
Debug.LogError(rooms[Thingid].GetComponent<RoomJinsha>().ids);
|
giveaway.Ids = sstr;
|
||||||
if (go.Count<1)
|
|
||||||
{
|
giveaway.GiftTargetId = userid;
|
||||||
Debug.LogError("Ä㻹ûÓÐ");
|
|
||||||
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
string aa= await web.SendRequest(web.URL + "/Voucher/Gift", "POST", JsonUtility.ToJson(giveaway));
|
||||||
return;
|
|
||||||
}
|
//Debug.Log("ÔùËͳɹ¦,AA:"+aa);
|
||||||
giveaway.Ids[0] = go[go.Count - 1];
|
|
||||||
giveaway.GiftTargetId = "1";
|
|
||||||
Debug.Log("ÔùËͳɹ¦");
|
|
||||||
|
|
||||||
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
||||||
}
|
}
|
||||||
@ -274,11 +271,15 @@ public class jinsha : mount
|
|||||||
ercitanchuangs[1].GetComponent<input_box_pop_up_window_item>().register_click(async (BoxType boxType, int type) =>
|
ercitanchuangs[1].GetComponent<input_box_pop_up_window_item>().register_click(async (BoxType boxType, int type) =>
|
||||||
{
|
{
|
||||||
if (type == 1)
|
if (type == 1)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//ÔùËÍÂß¼
|
//ÔùËÍÂß¼
|
||||||
|
Giveaway giveaway = new Giveaway();
|
||||||
|
Debug.Log(go.ids.Count);
|
||||||
|
string[] sstr = { go.ids[go.ids.Count - 1] };
|
||||||
|
giveaway.Ids = sstr;
|
||||||
|
giveaway.GiftTargetId = userid;
|
||||||
|
string aa = await web.SendRequest(web.URL + "/Voucher/Gift", "POST", JsonUtility.ToJson(giveaway));
|
||||||
|
|
||||||
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -31,6 +31,8 @@ public class room : mount
|
|||||||
public GameObject Boom;
|
public GameObject Boom;
|
||||||
|
|
||||||
private bool Buy_succefful =false;
|
private bool Buy_succefful =false;
|
||||||
|
|
||||||
|
//public List<string> ids = new List<string>();
|
||||||
// Start is called before the first frame update
|
// Start is called before the first frame update
|
||||||
public override void Awake()
|
public override void Awake()
|
||||||
{
|
{
|
||||||
@ -204,7 +206,7 @@ public class room : mount
|
|||||||
if (itemList.List[i].Num == buy_type)
|
if (itemList.List[i].Num == buy_type)
|
||||||
{
|
{
|
||||||
haveNumber += 1;
|
haveNumber += 1;
|
||||||
Debug.Log(this.gameObject.name+"矿工数量" + haveNumber);
|
// Debug.Log(this.gameObject.name+"矿工数量" + haveNumber);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ChangeTextPro();
|
ChangeTextPro();
|
||||||
@ -214,7 +216,7 @@ public class room : mount
|
|||||||
GetRoom();
|
GetRoom();
|
||||||
GameObject newMiner = GameObject.Instantiate(minerPrefab);
|
GameObject newMiner = GameObject.Instantiate(minerPrefab);
|
||||||
newMiner.transform.SetParent(startPos);
|
newMiner.transform.SetParent(startPos);
|
||||||
newMiner.transform.position = new Vector3(gold.position.x - 0.5f, gold.position.y, gold.position.y); ;
|
newMiner.transform.position = new Vector3(gold.position.x -1.5f, gold.position.y - 0.5f, gold.position.y); ;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -58,6 +58,8 @@ public class landContorl_jinsha : MonoBehaviour
|
|||||||
|
|
||||||
public static bool canClick=true;
|
public static bool canClick=true;
|
||||||
|
|
||||||
|
public List<string> ids = new List<string>();
|
||||||
|
|
||||||
// Start is called before the first frame update
|
// Start is called before the first frame update
|
||||||
private void Awake()
|
private void Awake()
|
||||||
{
|
{
|
||||||
|
@ -20,6 +20,9 @@ public class shopman :mount
|
|||||||
public int minerjiage = 0;
|
public int minerjiage = 0;
|
||||||
|
|
||||||
public int type =0;
|
public int type =0;
|
||||||
|
private string userid;
|
||||||
|
public List<GameObject> lands= new List<GameObject>();
|
||||||
|
public int lishiid;
|
||||||
// Start is called before the first frame update
|
// Start is called before the first frame update
|
||||||
public override void Awake()
|
public override void Awake()
|
||||||
{
|
{
|
||||||
@ -39,9 +42,9 @@ public class shopman :mount
|
|||||||
landContorl_jinsha.canClick = false;
|
landContorl_jinsha.canClick = false;
|
||||||
|
|
||||||
string userponse = await web.SendRequest(web.URL + "/FisherElf/GetList", "POST");
|
string userponse = await web.SendRequest(web.URL + "/FisherElf/GetList", "POST");
|
||||||
Debug.Log(userponse);
|
//Debug.Log(userponse);
|
||||||
BuyuList itemList = JsonUtility.FromJson<BuyuList>(userponse);
|
BuyuList itemList = JsonUtility.FromJson<BuyuList>(userponse);
|
||||||
Debug.Log(itemList.List[0].Type);
|
// Debug.Log(itemList.List[0].Type);
|
||||||
|
|
||||||
|
|
||||||
List<BoxType> boxTypes = new List<BoxType>();
|
List<BoxType> boxTypes = new List<BoxType>();
|
||||||
@ -82,6 +85,7 @@ public class shopman :mount
|
|||||||
{
|
{
|
||||||
Debug.Log("进入创建弹窗");
|
Debug.Log("进入创建弹窗");
|
||||||
BuyuItem item = intData.GetTypedData();
|
BuyuItem item = intData.GetTypedData();
|
||||||
|
lishiid = item.Num;
|
||||||
Show_buy(boxType.icon, boxType.prompt, 64, item.Num, item.ActivateValue);
|
Show_buy(boxType.icon, boxType.prompt, 64, item.Num, item.ActivateValue);
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -131,6 +135,7 @@ public class shopman :mount
|
|||||||
{
|
{
|
||||||
|
|
||||||
PlayerData pldata = intData.GetTypedData();
|
PlayerData pldata = intData.GetTypedData();
|
||||||
|
userid = pldata.Id;
|
||||||
}
|
}
|
||||||
|
|
||||||
List<BoxType> boxTypeser = new List<BoxType>();
|
List<BoxType> boxTypeser = new List<BoxType>();
|
||||||
@ -143,8 +148,16 @@ public class shopman :mount
|
|||||||
{
|
{
|
||||||
if (type == 1)
|
if (type == 1)
|
||||||
{
|
{
|
||||||
|
|
||||||
//赠送逻辑
|
//赠送逻辑
|
||||||
|
Giveaway giveaway = new Giveaway();
|
||||||
|
string[] sstr = { this.lands[lishiid / 3].GetComponent<landContorl_jinsha>().ids[this.lands[lishiid / 3].GetComponent<landContorl_jinsha>().ids.Count - 1]};
|
||||||
|
giveaway.Ids = sstr;
|
||||||
|
giveaway.GiftTargetId = userid;
|
||||||
|
string aa = await web.SendRequest(web.URL + "/Voucher/Gift", "POST", JsonUtility.ToJson(giveaway));
|
||||||
|
// Debug.Log("ÔùËÍ"+aa);
|
||||||
|
|
||||||
|
|
||||||
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
ercitanchuang.GetComponent<input_box_pop_up_window>().destroy();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -208,7 +221,6 @@ public class shopman :mount
|
|||||||
numbertext1 = "1",//单个矿工的价钱
|
numbertext1 = "1",//单个矿工的价钱
|
||||||
numbertext2 = number.ToString()//几个矿工
|
numbertext2 = number.ToString()//几个矿工
|
||||||
});
|
});
|
||||||
|
|
||||||
boxTypes.Add(new BoxType { Name = "account_number", textName = " 数量:", prompt = "请输入购买数量", Type = 6, is_required = false });
|
boxTypes.Add(new BoxType { Name = "account_number", textName = " 数量:", prompt = "请输入购买数量", Type = 6, is_required = false });
|
||||||
boxTypes.Add(new BoxType { Name = "submit", textName = " 取消购买 ", Type = 2 });
|
boxTypes.Add(new BoxType { Name = "submit", textName = " 取消购买 ", Type = 2 });
|
||||||
GameObject gameObject = add_pop_up(true);//生成弹窗母体
|
GameObject gameObject = add_pop_up(true);//生成弹窗母体
|
||||||
@ -280,7 +292,12 @@ public class shopman :mount
|
|||||||
generateForFisherElf.Num = Num;
|
generateForFisherElf.Num = Num;
|
||||||
generateForFisherElf.Count = Convert.ToInt32(number);
|
generateForFisherElf.Count = Convert.ToInt32(number);
|
||||||
string response = await web.SendRequest(web.URL + "/Voucher/GenerateForFisherElf", "POST", JsonUtility.ToJson(generateForFisherElf));
|
string response = await web.SendRequest(web.URL + "/Voucher/GenerateForFisherElf", "POST", JsonUtility.ToJson(generateForFisherElf));
|
||||||
Debug.Log(response);
|
|
||||||
|
//Ìí¼Ó
|
||||||
|
Mining_Wizard_ID mi = JsonUtility.FromJson<Mining_Wizard_ID>(response);
|
||||||
|
this.lands[Num / 3].GetComponent<landContorl_jinsha>().ids.Add(mi.Ids[0]);
|
||||||
|
|
||||||
|
|
||||||
Promptmgr.Instance.PromptBubble("购买精灵成功", Color.black, Color.blue);
|
Promptmgr.Instance.PromptBubble("购买精灵成功", Color.black, Color.blue);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user