update
parent
a9b489cc78
commit
9ad1495e4f
File diff suppressed because one or more lines are too long
|
@ -1,7 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 560a88da2bbc70140bed167f0ba7fe37
|
||||
DefaultImporter:
|
||||
guid: 001c7aa8d8d8e0c45a5c94c092d1eb4a
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,21 @@
|
|||
fileFormatVersion: 2
|
||||
guid: b8183dcbea2f7fc45828d49683613622
|
||||
TrueTypeFontImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 4
|
||||
fontSize: 16
|
||||
forceTextureCase: -2
|
||||
characterSpacing: 0
|
||||
characterPadding: 1
|
||||
includeFontData: 1
|
||||
fontNames:
|
||||
- Anton
|
||||
fallbackFontReferences: []
|
||||
customCharacters:
|
||||
fontRenderingMode: 0
|
||||
ascentCalculationMode: 1
|
||||
useLegacyBoundsCalculation: 0
|
||||
shouldRoundAdvanceValue: 1
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -535,6 +535,26 @@ PrefabInstance:
|
|||
serializedVersion: 3
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 1420233298793990163, guid: 99565b922ec123246acb5c52e20d4268, type: 3}
|
||||
propertyPath: _availableStates.Array.size
|
||||
value: 6
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 1420233298793990163, guid: 99565b922ec123246acb5c52e20d4268, type: 3}
|
||||
propertyPath: _availableStates.Array.data[2]
|
||||
value: GadGame.State.MainFlowState.EngageState
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 1420233298793990163, guid: 99565b922ec123246acb5c52e20d4268, type: 3}
|
||||
propertyPath: _availableStates.Array.data[3]
|
||||
value: GadGame.State.MainFlowState.WaitForImageState
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 1420233298793990163, guid: 99565b922ec123246acb5c52e20d4268, type: 3}
|
||||
propertyPath: _availableStates.Array.data[4]
|
||||
value: GadGame.State.MainFlowState.ShowImageState
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 1420233298793990163, guid: 99565b922ec123246acb5c52e20d4268, type: 3}
|
||||
propertyPath: _availableStates.Array.data[5]
|
||||
value: GadGame.State.MainFlowState.CTAState
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2776487287735717898, guid: 99565b922ec123246acb5c52e20d4268, type: 3}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
|
|
|
@ -352,8 +352,8 @@ MonoBehaviour:
|
|||
\u0111\u1EC3 ch\xFAng t\xF4i h\xE9 l\u1ED9 b\u1ECB m\u1EADt ch\u1EC9 qua 1 t\xE1ch
|
||||
c\xE0 ph\xEA nh\xE9"
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_fontAsset: {fileID: 11400000, guid: 001c7aa8d8d8e0c45a5c94c092d1eb4a, type: 2}
|
||||
m_sharedMaterial: {fileID: 1376761459422986731, guid: 001c7aa8d8d8e0c45a5c94c092d1eb4a, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
|
@ -708,7 +708,7 @@ MonoBehaviour:
|
|||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 0.19607843}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 0.39215687}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
|
@ -882,10 +882,10 @@ MonoBehaviour:
|
|||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: ....
|
||||
m_text: ...
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_fontAsset: {fileID: 11400000, guid: 001c7aa8d8d8e0c45a5c94c092d1eb4a, type: 2}
|
||||
m_sharedMaterial: {fileID: 1376761459422986731, guid: 001c7aa8d8d8e0c45a5c94c092d1eb4a, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
|
@ -1330,7 +1330,7 @@ MonoBehaviour:
|
|||
_process: {fileID: 1701610193}
|
||||
_hintText: {fileID: 1386430229}
|
||||
_loading: {fileID: 1087577779}
|
||||
_loadingSpeed: 50
|
||||
_loadingSpeed: 2
|
||||
_texts:
|
||||
- "Soi b\xF3ng b\u1EA1n trong t\xE1ch c\xE0 ph\xEA"
|
||||
- "Gi\u1EEF nguy\xEAn nh\u01B0 th\u1EBF nh\xE9"
|
||||
|
|
|
@ -33,6 +33,10 @@ namespace GadGame.Scripts.Coffee
|
|||
private void Awake()
|
||||
{
|
||||
_idleBg.alpha = 1;
|
||||
_loading.transform.DOLocalRotate(new Vector3(0, 0, 360), 10 / _loadingSpeed, RotateMode.FastBeyond360)
|
||||
.SetLoops(-1)
|
||||
.SetRelative(true)
|
||||
.SetEase(Ease.Linear);
|
||||
}
|
||||
|
||||
private void OnEnable()
|
||||
|
@ -79,7 +83,7 @@ namespace GadGame.Scripts.Coffee
|
|||
|
||||
private void OnGenerateImageSuccess()
|
||||
{
|
||||
_loading.DOFade(0, 0.5f);
|
||||
_loading.DOFade(0.255f, 0.5f);
|
||||
_hintText.text = "Mô tả";
|
||||
}
|
||||
|
||||
|
@ -94,10 +98,6 @@ namespace GadGame.Scripts.Coffee
|
|||
_isLoading = true;
|
||||
_hintText.text = _loadingTexts[_indexText];
|
||||
_loading.DOFade(1, 1f);
|
||||
_loading.transform.DOLocalRotate(new Vector3(0, 0, _loadingSpeed), 1, RotateMode.FastBeyond360)
|
||||
.SetLoops(-1)
|
||||
.SetRelative(true)
|
||||
.SetEase(Ease.Linear);
|
||||
}
|
||||
|
||||
private async void SetPlayVideo(bool value){
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
using UnityEngine;
|
||||
using UnityEngine.Serialization;
|
||||
|
||||
namespace GadGame.Network
|
||||
{
|
||||
|
@ -20,6 +21,6 @@ namespace GadGame.Network
|
|||
public int AgeMax;
|
||||
public Vector2[] PosPoints;
|
||||
public string StreamingData;
|
||||
public bool Success;
|
||||
[FormerlySerializedAs("Success")] public bool GenerateImageSuccess;
|
||||
}
|
||||
}
|
|
@ -36,13 +36,10 @@ namespace GadGame.State.MainFlowState
|
|||
if (_readyTimer <= 0)
|
||||
{
|
||||
_readyTimer = 0;
|
||||
Runner.EngageReady.Raise();
|
||||
UdpSocket.Instance.SendDataToPython("Begin");
|
||||
// Runner.SetState<PlayGameState>();
|
||||
Runner.SetState<WaitForImageState>();
|
||||
}
|
||||
if (time >= 2)
|
||||
{
|
||||
|
||||
// Runner.ReadyCountDown(_readyTimer);
|
||||
}
|
||||
|
||||
|
|
|
@ -15,6 +15,7 @@ namespace GadGame.State.MainFlowState
|
|||
|
||||
public override void Update(float time)
|
||||
{
|
||||
Runner.EncodeImage.Raise(UdpSocket.Instance.DataReceived.StreamingData);
|
||||
if(time < 2) return;
|
||||
if (!UdpSocket.Instance.DataReceived.PassBy)
|
||||
{
|
||||
|
@ -25,8 +26,6 @@ namespace GadGame.State.MainFlowState
|
|||
if (UdpSocket.Instance.DataReceived.Engage)
|
||||
{
|
||||
Runner.SetState<EngageState>();
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
using GadGame.Network;
|
||||
|
||||
namespace GadGame.State.MainFlowState
|
||||
{
|
||||
public class ShowImageState : State<MainFlow>
|
||||
{
|
||||
public override void Enter()
|
||||
{
|
||||
Runner.GenerateImageSuccess.Raise();
|
||||
}
|
||||
|
||||
public override void Update(float time)
|
||||
{
|
||||
Runner.EncodeImage.Raise(UdpSocket.Instance.DataReceived.StreamingData);
|
||||
}
|
||||
|
||||
public override void Exit()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 1e14faea09a5496e8e0a78dce8331d95
|
||||
timeCreated: 1718880013
|
|
@ -0,0 +1,27 @@
|
|||
using GadGame.Network;
|
||||
|
||||
namespace GadGame.State.MainFlowState
|
||||
{
|
||||
public class WaitForImageState : State<MainFlow>
|
||||
|
||||
{
|
||||
public override void Enter()
|
||||
{
|
||||
Runner.EngageReady.Raise();
|
||||
UdpSocket.Instance.SendDataToPython("Begin");
|
||||
}
|
||||
|
||||
public override void Update(float time)
|
||||
{
|
||||
if (UdpSocket.Instance.DataReceived.GenerateImageSuccess)
|
||||
{
|
||||
Runner.SetState<ShowImageState>();
|
||||
}
|
||||
}
|
||||
|
||||
public override void Exit()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 3f9a1c58b2414befa0f4a533b96fbf38
|
||||
timeCreated: 1718880084
|
|
@ -1,7 +0,0 @@
|
|||
fileFormatVersion: 2
|
||||
guid: fb01be13d6e88ca488dda82150319bfc
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -1,7 +0,0 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 117dcc671050f5247bd8743b91ecaab7
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Loading…
Reference in New Issue