データ構造追加
This commit is contained in:
parent
554f36fee5
commit
22ae9d6f70
|
|
@ -8,6 +8,8 @@ namespace MyGame.Scenes.WorldMap.Scripts
|
||||||
public class CityIcon : MonoBehaviour
|
public class CityIcon : MonoBehaviour
|
||||||
{
|
{
|
||||||
[SerializeField] private Transform icon;
|
[SerializeField] private Transform icon;
|
||||||
|
[SerializeField] private int cityId;
|
||||||
|
public int CityId => cityId;
|
||||||
public IObservable<Unit> OnClick =>
|
public IObservable<Unit> OnClick =>
|
||||||
(icon.GetComponent<ObservableEventTrigger>() ?? icon.gameObject.AddComponent<ObservableEventTrigger>())
|
(icon.GetComponent<ObservableEventTrigger>() ?? icon.gameObject.AddComponent<ObservableEventTrigger>())
|
||||||
.OnPointerClickAsObservable()
|
.OnPointerClickAsObservable()
|
||||||
|
|
|
||||||
|
|
@ -69,6 +69,9 @@ public static class Const {
|
||||||
public static readonly string ScrollGamePlaceDataSheet = "ScrollGamePlaceData";
|
public static readonly string ScrollGamePlaceDataSheet = "ScrollGamePlaceData";
|
||||||
public static readonly string ScrollGameStageDataSheet = "ScrollGameStageData";
|
public static readonly string ScrollGameStageDataSheet = "ScrollGameStageData";
|
||||||
public static readonly string ScrollGameStageDifficultyDataSheet = "ScrollGameStageDifficultyData";
|
public static readonly string ScrollGameStageDifficultyDataSheet = "ScrollGameStageDifficultyData";
|
||||||
|
public static readonly string CityDataSheet = "CityData";
|
||||||
|
public static readonly string FundingDataSheet = "FundingData";
|
||||||
|
public static readonly string PartTimerDataSheet = "PartTimerData";
|
||||||
|
|
||||||
// language
|
// language
|
||||||
public static readonly string LangJapanDataSheet = "LangJapanData";
|
public static readonly string LangJapanDataSheet = "LangJapanData";
|
||||||
|
|
@ -109,6 +112,9 @@ public static class Const {
|
||||||
new SheetData(Const.ScrollGamePlaceDataSheet),
|
new SheetData(Const.ScrollGamePlaceDataSheet),
|
||||||
new SheetData(Const.ScrollGameStageDataSheet),
|
new SheetData(Const.ScrollGameStageDataSheet),
|
||||||
new SheetData(Const.ScrollGameStageDifficultyDataSheet),
|
new SheetData(Const.ScrollGameStageDifficultyDataSheet),
|
||||||
|
new SheetData(Const.CityDataSheet),
|
||||||
|
new SheetData(Const.FundingDataSheet),
|
||||||
|
new SheetData(Const.PartTimerDataSheet),
|
||||||
};
|
};
|
||||||
public static readonly SheetData[] LanguageSheetNameList = new SheetData[]{
|
public static readonly SheetData[] LanguageSheetNameList = new SheetData[]{
|
||||||
new SheetData(Const.LangJapanDataSheet, "LanguageData"),
|
new SheetData(Const.LangJapanDataSheet, "LanguageData"),
|
||||||
|
|
|
||||||
|
|
@ -606,4 +606,38 @@ public sealed class ScrollGameStageDifficultyData
|
||||||
}
|
}
|
||||||
return ScrollGameDifficulty.Easy;
|
return ScrollGameDifficulty.Easy;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[Serializable]
|
||||||
|
public sealed class CityData
|
||||||
|
{
|
||||||
|
public int id;
|
||||||
|
public int needHeart;
|
||||||
|
public int scriptId;
|
||||||
|
public string prefabName;
|
||||||
|
}
|
||||||
|
|
||||||
|
[Serializable]
|
||||||
|
public sealed class FundingData
|
||||||
|
{
|
||||||
|
public int id;
|
||||||
|
public int cityId;
|
||||||
|
public int fundingCityId;
|
||||||
|
public int needAmount;
|
||||||
|
}
|
||||||
|
|
||||||
|
[Serializable]
|
||||||
|
public sealed class PartTimerData
|
||||||
|
{
|
||||||
|
public int id;
|
||||||
|
public int cityId;
|
||||||
|
public int level;
|
||||||
|
public int needHeartCityId;
|
||||||
|
public int needHeart;
|
||||||
|
public int needAmount;
|
||||||
|
public int sales;
|
||||||
|
public int heart;
|
||||||
|
public int maxSales;
|
||||||
|
public int maxHeart;
|
||||||
|
public string prefabName;
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue