チュートリアル用お客さん配置メソッド追加
This commit is contained in:
parent
0ba6b6fc01
commit
678e564968
|
|
@ -252,7 +252,7 @@ public class Market : SingletonMonoBehaviour<Market>
|
||||||
}).AddTo(controller);
|
}).AddTo(controller);
|
||||||
|
|
||||||
controller.State
|
controller.State
|
||||||
.Where(x => x == CustomerState.EatingLeave)
|
.Where(x => x != CustomerState.Order)
|
||||||
.Subscribe(c =>
|
.Subscribe(c =>
|
||||||
{
|
{
|
||||||
orderSubject.OnNext(default);
|
orderSubject.OnNext(default);
|
||||||
|
|
@ -269,6 +269,11 @@ public class Market : SingletonMonoBehaviour<Market>
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (gameData.isFirstPlay)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
// 一般客orセレブ
|
// 一般客orセレブ
|
||||||
var (isSpecial, orderCount) = GetCustomerData(isCustomer);
|
var (isSpecial, orderCount) = GetCustomerData(isCustomer);
|
||||||
|
|
||||||
|
|
@ -504,6 +509,25 @@ public class Market : SingletonMonoBehaviour<Market>
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public CustomerController SetTutorialCustomer()
|
||||||
|
{
|
||||||
|
var customerController = SpawnCustomer();
|
||||||
|
customerController.SetupCenter(orderPosisionObject.transform.GetComponentsInChildren<Transform>().ToList().Skip(1).ToList());
|
||||||
|
customerController.OrderCount = 1;
|
||||||
|
customerController.CustomerPrefab = customerData.ChooseNormalPrefab();
|
||||||
|
customerControllerList.Add(customerController);
|
||||||
|
|
||||||
|
// タップ後customerList.Add()
|
||||||
|
customerController.ChangeCustomerState(CustomerState.CenterStop);
|
||||||
|
customerController.TappedObservable
|
||||||
|
.Take(1)
|
||||||
|
.Subscribe(_ =>
|
||||||
|
{
|
||||||
|
customerList.Add(customerController);
|
||||||
|
}).AddTo(customerController);
|
||||||
|
return customerController;
|
||||||
|
}
|
||||||
|
|
||||||
private void CheckAndFixStock()
|
private void CheckAndFixStock()
|
||||||
{
|
{
|
||||||
if (GameDataManager.GameData.ShopStock.Count > ShopStockCount)
|
if (GameDataManager.GameData.ShopStock.Count > ShopStockCount)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue