럭키게임 리필 추가
This commit is contained in:
parent
49ccd30825
commit
7cef99de09
|
|
@ -1 +1 @@
|
|||
[{"s_ID": "LuckyPoint", "n_Value": "100", "exception": "럭키 포인트 100% 필요량"}, {"s_ID": "LuckyBlockWithdMin", "n_Value": "250", "exception": "럭키 블록 최소 크기 (가로)"}, {"s_ID": "LuckyBlockWithdMax", "n_Value": "400", "exception": "럭키 블록 최대 크기 (가로)"}, {"s_ID": "LuckyBlockHeightMin", "n_Value": "120", "exception": "럭키 블록 최소 크기 (세로)"}, {"s_ID": "LuckyBlockHeightMax", "n_Value": "120", "exception": "럭키 블록 최대 크기 (세로)"}, {"s_ID": "LuckyBlockSpeedMin", "n_Value": "320", "exception": "럭키 블록 최소 스피드"}, {"s_ID": "LuckyBlockSpeedMax", "n_Value": "540", "exception": "럭키 블록 최대 스피드"}, {"s_ID": "GachaAmount", "n_Value": "5", "exception": "가챠에 필요한 가챠 코인 개수"}, {"s_ID": "GachaAD_Reward", "n_Value": "30", "exception": "가챠 광고 가챠 코인 보상 개수"}, {"s_ID": "GachaAutoRefill_DelayTime", "n_Value": "60", "exception": "가챠 광고 딜레이 시간 (초)"}, {"s_ID": "GachaAutoRefill_Amount", "n_Value": "5", "exception": "가챠 자동 획득 가챠 코인 보상 개수"}, {"s_ID": "ADSec_Gacha", "n_Value": "600", "exception": "가챠 광고 시간 (초)"}, {"s_ID": "ADSec_Shop", "n_Value": "600", "exception": "상점 광고 시간 (초)"}, {"s_ID": "MiniGameHP", "n_Value": "10", "exception": "미니 게임 HP"}, {"s_ID": "MiniGameSpeedMin", "n_Value": "0.25", "exception": "미니 게임 방해물 최소 속도"}, {"s_ID": "MiniGameSpeedMax", "n_Value": "1", "exception": "미니 게임 방해물 최대 속도"}, {"s_ID": "MiniGameWeight_White", "n_Value": "6500", "exception": "미니 게임 흰 액체 등장 확률"}, {"s_ID": "MiniGameWeight_Red", "n_Value": "1500", "exception": "미니 게임 빨간 액체 등장 확률"}, {"s_ID": "MiniGameWeight_HpHeal", "n_Value": "60", "exception": "미니 게임 체력 회복 등장 확률"}, {"s_ID": "MiniGameWeight_AlbumOpen", "n_Value": "15", "exception": "미니 게임 앨범 오픈 재화 등장 확률"}, {"s_ID": "MiniGameWeight_ChatCoin", "n_Value": "5", "exception": "미니 게임 채팅 코인 등장 확률"}, {"s_ID": "MiniGameWeight_GachaCoin", "n_Value": "1800", "exception": "미니 게임 가챠 코인 등장 확률"}, {"s_ID": "MiniGameWeight_ItemBomb", "n_Value": "40", "exception": "미니 게임 폭탄 아이템 등장 확률"}, {"s_ID": "MiniGameWeight_ItemUmbrella", "n_Value": "40", "exception": "미니 게임 우산 아이템 등장 확률"}, {"s_ID": "MiniGameWeight_ItemDildo", "n_Value": "40", "exception": "미니 게임 딜도 아이템 등장 확률"}, {"s_ID": "MiniGamePCSpeed", "n_Value": "550", "exception": "미니 게임 PC 스피드"}, {"s_ID": "MiniGame_White_DMG", "n_Value": "2", "exception": "미니 게임 흰 액체 데미지"}, {"s_ID": "MiniGame_Red_DMG", "n_Value": "5", "exception": "미니 게임 빨간 액체 데미지"}, {"s_ID": "MiniGame_Heal", "n_Value": "3", "exception": "미니 게임 체력 회복량"}, {"s_ID": "MiniGame_Heart_Amount", "n_Value": "1", "exception": "미니 게임 앨범 오픈 재화 획득량"}, {"s_ID": "MiniGame_ChatCoin_Amount", "n_Value": "1", "exception": "미니 게임 채팅 코인 획득량"}, {"s_ID": "MiniGame_GachaCoin_Amount", "n_Value": "1", "exception": "미니 게임 가챠 코인 획득량"}, {"s_ID": "MiniGame_Obtacle_Create_Gap", "n_Value": "0.9", "exception": "1. 최초 생성 시간 (초)"}, {"s_ID": "MiniGame_Obtacle_Gap_Reduce", "n_Value": "0.01", "exception": "2. 생성시간 감소 값 (초)"}, {"s_ID": "MiniGame_Obtacle_Gap_Time", "n_Value": "1", "exception": "3. 생성 시간 감소 주기 (초)"}, {"s_ID": "MiniGame_Obtacle_Gap_LimitTime", "n_Value": "0.085", "exception": "4. 최대 생성 제한 시간 (초)"}, {"s_ID": "MiniGame_TotalEnterMoney", "n_Value": "5", "exception": "미니게임 체력 총 개수"}, {"s_ID": "MiniGame_EnterMoney_Time", "n_Value": "30", "exception": "미니게임 체력 재충전 시간 (초)"}, {"s_ID": "ShieldTime", "n_Value": "5", "exception": "미니게임 우산 보호막 시간 (초)"}, {"s_ID": "PreviewADTime", "n_Value": "180", "exception": "훔쳐보기 광고 쿨타임 (초)"}]
|
||||
[{"s_ID": "LuckyPoint", "n_Value": "100", "exception": "럭키 포인트 100% 필요량"}, {"s_ID": "LuckyBlockWithdMin", "n_Value": "250", "exception": "럭키 블록 최소 크기 (가로)"}, {"s_ID": "LuckyBlockWithdMax", "n_Value": "400", "exception": "럭키 블록 최대 크기 (가로)"}, {"s_ID": "LuckyBlockHeightMin", "n_Value": "120", "exception": "럭키 블록 최소 크기 (세로)"}, {"s_ID": "LuckyBlockHeightMax", "n_Value": "120", "exception": "럭키 블록 최대 크기 (세로)"}, {"s_ID": "LuckyBlockSpeedMin", "n_Value": "320", "exception": "럭키 블록 최소 스피드"}, {"s_ID": "LuckyBlockSpeedMax", "n_Value": "540", "exception": "럭키 블록 최대 스피드"}, {"s_ID": "LuckyGame_RefillAmount", "n_Value": "5", "exception": "리필 시 추가 오브젝트 개수"}, {"s_ID": "GachaAmount", "n_Value": "5", "exception": "가챠에 필요한 가챠 코인 개수"}, {"s_ID": "GachaAD_Reward", "n_Value": "30", "exception": "가챠 광고 가챠 코인 보상 개수"}, {"s_ID": "GachaAutoRefill_DelayTime", "n_Value": "60", "exception": "가챠 광고 딜레이 시간 (초)"}, {"s_ID": "GachaAutoRefill_Amount", "n_Value": "5", "exception": "가챠 자동 획득 가챠 코인 보상 개수"}, {"s_ID": "ADSec_Gacha", "n_Value": "600", "exception": "가챠 광고 시간 (초)"}, {"s_ID": "ADSec_Shop", "n_Value": "600", "exception": "상점 광고 시간 (초)"}, {"s_ID": "MiniGameHP", "n_Value": "10", "exception": "미니 게임 HP"}, {"s_ID": "MiniGameSpeedMin", "n_Value": "0.25", "exception": "미니 게임 방해물 최소 속도"}, {"s_ID": "MiniGameSpeedMax", "n_Value": "1", "exception": "미니 게임 방해물 최대 속도"}, {"s_ID": "MiniGameWeight_White", "n_Value": "6500", "exception": "미니 게임 흰 액체 등장 확률"}, {"s_ID": "MiniGameWeight_Red", "n_Value": "1500", "exception": "미니 게임 빨간 액체 등장 확률"}, {"s_ID": "MiniGameWeight_HpHeal", "n_Value": "60", "exception": "미니 게임 체력 회복 등장 확률"}, {"s_ID": "MiniGameWeight_AlbumOpen", "n_Value": "15", "exception": "미니 게임 앨범 오픈 재화 등장 확률"}, {"s_ID": "MiniGameWeight_ChatCoin", "n_Value": "5", "exception": "미니 게임 채팅 코인 등장 확률"}, {"s_ID": "MiniGameWeight_GachaCoin", "n_Value": "1800", "exception": "미니 게임 가챠 코인 등장 확률"}, {"s_ID": "MiniGameWeight_ItemBomb", "n_Value": "40", "exception": "미니 게임 폭탄 아이템 등장 확률"}, {"s_ID": "MiniGameWeight_ItemUmbrella", "n_Value": "40", "exception": "미니 게임 우산 아이템 등장 확률"}, {"s_ID": "MiniGameWeight_ItemDildo", "n_Value": "40", "exception": "미니 게임 딜도 아이템 등장 확률"}, {"s_ID": "MiniGamePCSpeed", "n_Value": "550", "exception": "미니 게임 PC 스피드"}, {"s_ID": "MiniGame_White_DMG", "n_Value": "2", "exception": "미니 게임 흰 액체 데미지"}, {"s_ID": "MiniGame_Red_DMG", "n_Value": "5", "exception": "미니 게임 빨간 액체 데미지"}, {"s_ID": "MiniGame_Heal", "n_Value": "3", "exception": "미니 게임 체력 회복량"}, {"s_ID": "MiniGame_Heart_Amount", "n_Value": "1", "exception": "미니 게임 앨범 오픈 재화 획득량"}, {"s_ID": "MiniGame_ChatCoin_Amount", "n_Value": "1", "exception": "미니 게임 채팅 코인 획득량"}, {"s_ID": "MiniGame_GachaCoin_Amount", "n_Value": "1", "exception": "미니 게임 가챠 코인 획득량"}, {"s_ID": "MiniGame_Obtacle_Create_Gap", "n_Value": "0.9", "exception": "1. 최초 생성 시간 (초)"}, {"s_ID": "MiniGame_Obtacle_Gap_Reduce", "n_Value": "0.01", "exception": "2. 생성시간 감소 값 (초)"}, {"s_ID": "MiniGame_Obtacle_Gap_Time", "n_Value": "1", "exception": "3. 생성 시간 감소 주기 (초)"}, {"s_ID": "MiniGame_Obtacle_Gap_LimitTime", "n_Value": "0.085", "exception": "4. 최대 생성 제한 시간 (초)"}, {"s_ID": "MiniGame_TotalEnterMoney", "n_Value": "5", "exception": "미니게임 체력 총 개수"}, {"s_ID": "MiniGame_EnterMoney_Time", "n_Value": "30", "exception": "미니게임 체력 재충전 시간 (초)"}, {"s_ID": "ShieldTime", "n_Value": "5", "exception": "미니게임 우산 보호막 시간 (초)"}, {"s_ID": "PreviewADTime", "n_Value": "180", "exception": "훔쳐보기 광고 쿨타임 (초)"}]
|
||||
Binary file not shown.
|
|
@ -5701,6 +5701,41 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 159317135}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &163624061
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 163624062}
|
||||
m_Layer: 5
|
||||
m_Name: RefillObjs
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &163624062
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 163624061}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 1257193656}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &164670858
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
@ -45500,6 +45535,7 @@ RectTransform:
|
|||
- {fileID: 48983097}
|
||||
- {fileID: 1757808306}
|
||||
- {fileID: 1190514304}
|
||||
- {fileID: 163624062}
|
||||
- {fileID: 2127274534}
|
||||
- {fileID: 1950932324}
|
||||
- {fileID: 1534428862}
|
||||
|
|
@ -45541,10 +45577,12 @@ MonoBehaviour:
|
|||
- {fileID: 1281917608}
|
||||
- {fileID: 357209802}
|
||||
- {fileID: 1356841228}
|
||||
- {fileID: 2103258651}
|
||||
go_dropobj: {fileID: 6939998903098416576, guid: 762ff4ec5a22c6b45978c6b031b0e7e5, type: 3}
|
||||
tf_cup: {fileID: 995025953}
|
||||
tf_cupin: {fileID: 1836599685}
|
||||
tf_fallobjs: {fileID: 1190514304}
|
||||
tf_refillobjs: {fileID: 163624062}
|
||||
list_randomblock:
|
||||
- {fileID: 1007280070}
|
||||
- {fileID: 233736480}
|
||||
|
|
@ -49955,7 +49993,7 @@ GameObject:
|
|||
- component: {fileID: 1356841229}
|
||||
- component: {fileID: 1356841228}
|
||||
m_Layer: 5
|
||||
m_Name: t_refilecount
|
||||
m_Name: t_refillcount
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
|
|
@ -77966,7 +78004,7 @@ GameObject:
|
|||
- component: {fileID: 2103258652}
|
||||
- component: {fileID: 2103258651}
|
||||
m_Layer: 5
|
||||
m_Name: New TMP
|
||||
m_Name: t_refillamount
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
|
|
|
|||
|
|
@ -12,11 +12,12 @@ public class Game_Lucky : MonoBehaviour
|
|||
public Game_Lucky_Result m_Game_Lucky_Result;
|
||||
public Image i_girl, i_girlsd, i_refillbtn;
|
||||
public GameObject[] gos_boobs;
|
||||
public TextMeshProUGUI[] texts; // 0 시간, 1 획득 재화, 2 컵안 오브젝트 갯수, 3 리필 횟수
|
||||
public TextMeshProUGUI[] texts; // 0 시간, 1 획득 재화, 2 컵안 오브젝트 갯수, 3 리필 횟수, 4 리필 갯수
|
||||
public GameObject go_dropobj; // 떨어질 공 prefab
|
||||
public Transform tf_cup; // 컵 (움직이고 회전하는 부분)
|
||||
public Transform tf_cupin; // 컵 안 (공들이 들어가는 위치 부모)
|
||||
public Transform tf_fallobjs; // 컵 안에서 밖으로 떨어지는 공들의 부모
|
||||
public Transform tf_refillobjs; // 리필 공들
|
||||
|
||||
List<GameObject> list_dropobj = new List<GameObject>();
|
||||
public List<LuckyRandomBlock> list_randomblock;
|
||||
|
|
@ -29,7 +30,7 @@ public class Game_Lucky : MonoBehaviour
|
|||
float Cup_minX, Cup_maxX;
|
||||
[SerializeField] private float cupMargin = 128.5f; // 간격
|
||||
|
||||
bool bRotCup = false, updateTime = false;
|
||||
bool bRotCup = false, updateTime = false, isRefill = false;
|
||||
ProtectedFloat m_Time;
|
||||
ProtectedInt32 _get; public int m_Amount { get { return _get; } set { _get = value; _get.Obfuscate(); } }
|
||||
ProtectedInt32 _bb; public int m_BubbleAmount { get { return _bb; } set { _bb = value; _bb.Obfuscate(); } }
|
||||
|
|
@ -51,6 +52,14 @@ public class Game_Lucky : MonoBehaviour
|
|||
|
||||
Cup_minX = leftWorld.x;
|
||||
Cup_maxX = rightWorld.x;
|
||||
|
||||
var refill = table_GlobalValue.Ins.Get_Int("LuckyGame_RefillAmount") << 1;
|
||||
for (int i = 0; i < refill; i++)
|
||||
{
|
||||
var obj = DSUtil.Get_Clone(go_dropobj, tf_refillobjs);
|
||||
obj.gameObject.SetActive(false);
|
||||
}
|
||||
texts[4].text = $"x{table_GlobalValue.Ins.Get_Int("LuckyGame_RefillAmount")}";
|
||||
}
|
||||
|
||||
public void Set()
|
||||
|
|
@ -61,7 +70,7 @@ public class Game_Lucky : MonoBehaviour
|
|||
m_Game_Lucky_Result.gameObject.SetActive(false);
|
||||
ADInfo.Ins.Set_Banner(false);
|
||||
|
||||
bRotCup = false;
|
||||
isRefill = bRotCup = false;
|
||||
curGirl = Random.Range(1, 9);
|
||||
|
||||
i_girl.enabled = false;
|
||||
|
|
@ -101,6 +110,17 @@ public class Game_Lucky : MonoBehaviour
|
|||
}
|
||||
}
|
||||
|
||||
if (list_dropobj.Count > TotalBubbleAmount)
|
||||
{
|
||||
var moveCount = list_dropobj.Count - TotalBubbleAmount;
|
||||
for (int i = 0; i < moveCount; i++)
|
||||
{
|
||||
list_dropobj[0].transform.SetParent(tf_refillobjs);
|
||||
list_dropobj[0].gameObject.SetActive(false);
|
||||
list_dropobj.RemoveAt(0);
|
||||
}
|
||||
}
|
||||
|
||||
StartCoroutine(Co_Block());
|
||||
|
||||
Set_Ball();
|
||||
|
|
@ -139,7 +159,7 @@ public class Game_Lucky : MonoBehaviour
|
|||
Set_Texts();
|
||||
|
||||
++m_BubbleAmount;
|
||||
if (m_BubbleAmount >= TotalBubbleAmount)
|
||||
if (m_BubbleAmount >= list_dropobj.Count)
|
||||
GameOver();
|
||||
}
|
||||
|
||||
|
|
@ -167,9 +187,9 @@ public class Game_Lucky : MonoBehaviour
|
|||
gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
Vector3 Get_CupInLocalPos()
|
||||
Vector3 Get_CupInLocalPos(float addy = 0f)
|
||||
{
|
||||
return new Vector3(Random.Range(-50f, 50f), Random.Range(-50f, 50f), 0f);
|
||||
return new Vector3(Random.Range(-50f, 50f), Random.Range(-50f, 50f) + addy, 0f);
|
||||
}
|
||||
|
||||
public void OnMyDrag()
|
||||
|
|
@ -221,6 +241,8 @@ public class Game_Lucky : MonoBehaviour
|
|||
|
||||
private void Update()
|
||||
{
|
||||
if (isRefill) return;
|
||||
|
||||
float currentZ = tf_cup.eulerAngles.z;
|
||||
if (currentZ > 180f) currentZ -= 360f; // -180~180 범위 보정
|
||||
|
||||
|
|
@ -273,6 +295,30 @@ public class Game_Lucky : MonoBehaviour
|
|||
--m_RefillCount;
|
||||
m_RefillCount.Obfuscate();
|
||||
Set_Texts();
|
||||
StartCoroutine(Co_Refill());
|
||||
}
|
||||
}
|
||||
|
||||
IEnumerator Co_Refill()
|
||||
{
|
||||
isRefill = true;
|
||||
tf_cup.rotation = Quaternion.Euler(0, 0, 0);
|
||||
|
||||
for (int i = 0; i < table_GlobalValue.Ins.Get_Int("LuckyGame_RefillAmount"); i++)
|
||||
{
|
||||
for (int j = 0; j < tf_refillobjs.childCount; j++)
|
||||
{
|
||||
var child = tf_refillobjs.GetChild(j);
|
||||
if (!child.gameObject.activeInHierarchy)
|
||||
{
|
||||
list_dropobj.Add(child.gameObject);
|
||||
child.GetComponent<LuckyGameObj>().Init(Get_CupInLocalPos(100f), tf_cupin, tf_fallobjs);
|
||||
yield return new WaitForSeconds(0.5f);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
isRefill = false;
|
||||
}
|
||||
}
|
||||
|
|
@ -40,6 +40,8 @@ public class LuckyGameObj : MonoBehaviour
|
|||
|
||||
public void Init(Vector3 pos, Transform tfcupin, Transform tffallobjs)
|
||||
{
|
||||
gameObject.SetActive(true);
|
||||
|
||||
transform.parent = tfcupin;
|
||||
transform.localPosition = pos;
|
||||
tf_fallobjs = tffallobjs;
|
||||
|
|
|
|||
Loading…
Reference in New Issue