[03_RoyalGallery/Unity-19050-03_RoyalGallery_iPad]

Fixed draw no loop bug.
master
LH 6 years ago
parent 192e3b6598
commit fb54fe9289
  1. 1
      03_RoyalGallery/Unity-19050-03_RoyalGallery_iPad/19050-03_RoyalGallery_iPad/Assets/RoyalGallery/Script/AppData.cs
  2. 8
      03_RoyalGallery/Unity-19050-03_RoyalGallery_iPad/19050-03_RoyalGallery_iPad/Assets/RoyalGallery/Script/AppDataxConfiguration.cs
  3. 10
      03_RoyalGallery/Unity-19050-03_RoyalGallery_iPad/19050-03_RoyalGallery_iPad/Assets/RoyalGallery/Script/ResourceClient.cs

@ -21,5 +21,6 @@ namespace UltraCombos.Frozen.RoyalGallery
public bool isEnablePaintBG = true; public bool isEnablePaintBG = true;
public bool isGetPageBySelf = false; public bool isGetPageBySelf = false;
public bool isEnableSceneTester = false; public bool isEnableSceneTester = false;
public int currentIndex = 0;
} }
} }

@ -20,6 +20,10 @@ namespace UltraCombos.Frozen.RoyalGallery
[Configuration.Config] [Configuration.Config]
public bool isEnableSceneTester = false; public bool isEnableSceneTester = false;
[Configuration.Config]
[Range(-1, 15)]
public int targetIndex = -1;
// Start is called before the first frame update // Start is called before the first frame update
void Start() void Start()
{ {
@ -27,6 +31,10 @@ namespace UltraCombos.Frozen.RoyalGallery
AppData.Instance.isEnablePaintBG = isEnablePaintBG; AppData.Instance.isEnablePaintBG = isEnablePaintBG;
AppData.Instance.isGetPageBySelf = isGetPageBySelf; AppData.Instance.isGetPageBySelf = isGetPageBySelf;
AppData.Instance.isEnableSceneTester = isEnableSceneTester; AppData.Instance.isEnableSceneTester = isEnableSceneTester;
if (targetIndex >= 0)
{
AppData.Instance.currentIndex = targetIndex;
}
} }
// Update is called once per frame // Update is called once per frame

@ -10,10 +10,6 @@ namespace UltraCombos.Frozen.RoyalGallery
{ {
public class ResourceClient : GrpcClientBase public class ResourceClient : GrpcClientBase
{ {
public bool isGetPageBySelf = false;
[Configuration.Config]
public int currentIndex = 0;
[Configuration.Config] [Configuration.Config]
public string overrideHost = "127.0.0.1"; public string overrideHost = "127.0.0.1";
@ -95,9 +91,9 @@ namespace UltraCombos.Frozen.RoyalGallery
} }
var data = AppData.Instance; var data = AppData.Instance;
currentIndex %= pm.names.Count; data.currentIndex %= pm.names.Count;
string name = pm.names[currentIndex++]; string name = pm.names[data.currentIndex++];
currentIndex %= pm.names.Count; data.currentIndex %= pm.names.Count;
data.roleId = name; data.roleId = name;
data.serial = Utils.GenerateSerial(0, data.roleId); data.serial = Utils.GenerateSerial(0, data.roleId);

Loading…
Cancel
Save