Skip to content

Commit

Permalink
Merge pull request A-Classe#362 from A-Classe/develop
Browse files Browse the repository at this point in the history
レスポンシブ対応
  • Loading branch information
harumas authored Aug 17, 2024
2 parents fe267f0 + f288945 commit 0bfab43
Show file tree
Hide file tree
Showing 10 changed files with 33 additions and 41 deletions.
18 changes: 14 additions & 4 deletions src/Assets/Prefabs/UI/View/MainUI.prefab
Original file line number Diff line number Diff line change
Expand Up @@ -1059,7 +1059,7 @@ RectTransform:
m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 0, y: 0.5}
m_AnchoredPosition: {x: 206, y: 0}
m_SizeDelta: {x: 370, y: 1011}
m_SizeDelta: {x: 370, y: 975}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!1 &3094168564290214271
GameObject:
Expand Down Expand Up @@ -4302,11 +4302,11 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_UiScaleMode: 0
m_UiScaleMode: 1
m_ReferencePixelsPerUnit: 100
m_ScaleFactor: 1
m_ReferenceResolution: {x: 800, y: 600}
m_ScreenMatchMode: 0
m_ReferenceResolution: {x: 1920, y: 1080}
m_ScreenMatchMode: 1
m_MatchWidthOrHeight: 0
m_PhysicalUnit: 3
m_FallbackScreenDPI: 96
Expand Down Expand Up @@ -5233,6 +5233,16 @@ PrefabInstance:
propertyPath: m_RootOrder
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2121982090214931107, guid: dbab9d59672ab4c908ac05bd518dfe9b,
type: 3}
propertyPath: m_SizeDelta.x
value: -140
objectReference: {fileID: 0}
- target: {fileID: 2121982090214931107, guid: dbab9d59672ab4c908ac05bd518dfe9b,
type: 3}
propertyPath: m_AnchoredPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2719373954449300561, guid: dbab9d59672ab4c908ac05bd518dfe9b,
type: 3}
propertyPath: m_AnchorMax.y
Expand Down
2 changes: 1 addition & 1 deletion src/Assets/Prefabs/UI/View/OptionUI.prefab
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &1462940678991408295
RectTransform:
m_ObjectHideFlags: 0
Expand Down
4 changes: 2 additions & 2 deletions src/Assets/Prefabs/UI/View/TitleUI.prefab
Original file line number Diff line number Diff line change
Expand Up @@ -2689,11 +2689,11 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_UiScaleMode: 0
m_UiScaleMode: 1
m_ReferencePixelsPerUnit: 100
m_ScaleFactor: 1
m_ReferenceResolution: {x: 1920, y: 1080}
m_ScreenMatchMode: 0
m_ScreenMatchMode: 1
m_MatchWidthOrHeight: 0
m_PhysicalUnit: 3
m_FallbackScreenDPI: 96
Expand Down
6 changes: 3 additions & 3 deletions src/Assets/Scenes/Other/AfterInGame.unity
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ RenderSettings:
m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 0}
m_IndirectSpecularColor: {r: 0.18028378, g: 0.22571412, b: 0.30692285, a: 1}
m_IndirectSpecularColor: {r: 0.18028326, g: 0.22571333, b: 0.30692202, a: 1}
m_UseRadianceAmbientProbe: 0
--- !u!157 &3
LightmapSettings:
Expand Down Expand Up @@ -171,10 +171,10 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_UiScaleMode: 0
m_UiScaleMode: 1
m_ReferencePixelsPerUnit: 100
m_ScaleFactor: 1
m_ReferenceResolution: {x: 800, y: 600}
m_ReferenceResolution: {x: 1920, y: 1080}
m_ScreenMatchMode: 0
m_MatchWidthOrHeight: 0
m_PhysicalUnit: 3
Expand Down
6 changes: 3 additions & 3 deletions src/Assets/Scenes/Other/BeforeInGame.unity
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ RenderSettings:
m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 0}
m_IndirectSpecularColor: {r: 0.18028378, g: 0.22571412, b: 0.30692285, a: 1}
m_IndirectSpecularColor: {r: 0.18028326, g: 0.22571333, b: 0.30692202, a: 1}
m_UseRadianceAmbientProbe: 0
--- !u!157 &3
LightmapSettings:
Expand Down Expand Up @@ -171,10 +171,10 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_UiScaleMode: 0
m_UiScaleMode: 1
m_ReferencePixelsPerUnit: 100
m_ScaleFactor: 1
m_ReferenceResolution: {x: 800, y: 600}
m_ReferenceResolution: {x: 1920, y: 1080}
m_ScreenMatchMode: 0
m_MatchWidthOrHeight: 0
m_PhysicalUnit: 3
Expand Down
6 changes: 3 additions & 3 deletions src/Assets/Scenes/Other/Result_Test.unity
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ RenderSettings:
m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 0}
m_IndirectSpecularColor: {r: 0.18028378, g: 0.22571412, b: 0.30692285, a: 1}
m_IndirectSpecularColor: {r: 0.18028326, g: 0.22571333, b: 0.30692202, a: 1}
m_UseRadianceAmbientProbe: 0
--- !u!157 &3
LightmapSettings:
Expand Down Expand Up @@ -398,10 +398,10 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_UiScaleMode: 0
m_UiScaleMode: 1
m_ReferencePixelsPerUnit: 100
m_ScaleFactor: 1
m_ReferenceResolution: {x: 800, y: 600}
m_ReferenceResolution: {x: 1920, y: 1080}
m_ScreenMatchMode: 0
m_MatchWidthOrHeight: 0
m_PhysicalUnit: 3
Expand Down
22 changes: 0 additions & 22 deletions src/Assets/Scenes/Other/Titles_Test.unity
Original file line number Diff line number Diff line change
Expand Up @@ -695,11 +695,6 @@ PrefabInstance:
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 3574018508568412557, guid: bd4ef44b6755d01419fd9c06f2e9a2e4,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8020704069567052177, guid: bd4ef44b6755d01419fd9c06f2e9a2e4,
type: 3}
propertyPath: m_Name
Expand Down Expand Up @@ -810,23 +805,6 @@ PrefabInstance:
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8020704070375467204, guid: bd4ef44b6755d01419fd9c06f2e9a2e4,
type: 3}
propertyPath: m_AnchorMax.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8020704070375467204, guid: bd4ef44b6755d01419fd9c06f2e9a2e4,
type: 3}
propertyPath: m_AnchorMax.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8020704071116649985, guid: bd4ef44b6755d01419fd9c06f2e9a2e4,
type: 3}
propertyPath: m_text
value: 'Planner
IchiharaYuuma TamuraAyane'
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: bd4ef44b6755d01419fd9c06f2e9a2e4, type: 3}
--- !u!114 &8020704071054321528 stripped
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ public class CursorController<T> : AnimationBehaviour where T : Enum

private bool isInitialize;
private readonly Dictionary<T, RectTransform> points = new();
private float scaleFactor;

public void AddPoint(T key, RectTransform rectT)
{
Expand All @@ -41,9 +42,10 @@ public void SetPoint(T key)

private void Animated(RectTransform rect)
{
scaleFactor = GetComponentInParent<Canvas>().scaleFactor;
var position = rect.position;
var leftX = position.x - rect.rect.width / 2f;
var rightX = position.x + rect.rect.width / 2f;
var leftX = position.x - rect.rect.width * scaleFactor / 2f;
var rightX = position.x + rect.rect.width * scaleFactor / 2f;

var leftT = left.transform.position;
left.OnCancel();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ private void Start()
rightAnchor.rectTransform.localPosition = fPosRight;
}

;
iPosLeft = leftAnchor.rectTransform.localPosition;
fPosLeft = iPosLeft - new Vector3(-bar.rectTransform.rect.size.x / 2f, 0f, 0f);
iPosRight = rightAnchor.rectTransform.localPosition;
Expand Down
3 changes: 3 additions & 0 deletions src/ProjectSettings/EditorBuildSettings.asset
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ EditorBuildSettings:
- enabled: 1
path: Assets/Scenes/Stages/Stage1/Stage1.unity
guid: 51340b3e2dc897a4db72f833b38075ff
- enabled: 1
path: Assets/Scenes/Stages/Stage2/Stage2.unity
guid: 9f542f1f1f8e35645adc3ce86129d44a
- enabled: 1
path: Assets/Scenes/Stages/Stage3/Stage3.unity
guid: facd8e5ea90dd3d4a93d515fe897de2e
Expand Down

0 comments on commit 0bfab43

Please sign in to comment.