This commit is contained in:
anjufin
2026-06-06 16:34:53 +02:00
20 changed files with 268 additions and 23 deletions
+93
View File
@@ -0,0 +1,93 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &3724115605263402928
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7100472280186483774}
- component: {fileID: 8707174864638790277}
m_Layer: 0
m_Name: MiniDroplet
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &7100472280186483774
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3724115605263402928}
serializedVersion: 2
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: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &8707174864638790277
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3724115605263402928}
m_Enabled: 1
m_CastShadows: 0
m_ReceiveShadows: 0
m_DynamicOccludee: 1
m_StaticShadowCaster: 0
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 0
m_RayTraceProcedural: 0
m_RayTracingAccelStructBuildFlagsOverride: 0
m_RayTracingAccelStructBuildFlags: 1
m_SmallMeshCulling: 1
m_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 1
m_SelectedEditorRenderState: 0
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -2413806693520163455, guid: a86470a33a6bf42c4b3595704624658b, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 1, y: 1}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 5bb8206709807ff4cae9583b3ee3e67d
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
+95
View File
@@ -1894,6 +1894,38 @@ Transform:
m_CorrespondingSourceObject: {fileID: 2163867978973577705, guid: 2f44dc6d6adb9ae7f9b4f644da0e3485, type: 3}
m_PrefabInstance: {fileID: 991606099}
m_PrefabAsset: {fileID: 0}
--- !u!1 &1006275183
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1006275184}
m_Layer: 0
m_Name: MiniDroplets
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1006275184
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1006275183}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 2.07426, y: 3.48276, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1194303349371580766}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &1124127124 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 2163867978973577705, guid: 2f44dc6d6adb9ae7f9b4f644da0e3485, type: 3}
@@ -3291,6 +3323,68 @@ Transform:
m_CorrespondingSourceObject: {fileID: 2163867978973577705, guid: 2f44dc6d6adb9ae7f9b4f644da0e3485, type: 3}
m_PrefabInstance: {fileID: 2145117925}
m_PrefabAsset: {fileID: 0}
--- !u!1001 &1194303349371580765
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1006275184}
m_Modifications:
- target: {fileID: 3724115605263402928, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_Name
value: MiniDroplet1
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
--- !u!4 &1194303349371580766 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 7100472280186483774, guid: 5bb8206709807ff4cae9583b3ee3e67d, type: 3}
m_PrefabInstance: {fileID: 1194303349371580765}
m_PrefabAsset: {fileID: 0}
--- !u!1001 &4353227734250816225
PrefabInstance:
m_ObjectHideFlags: 0
@@ -3796,3 +3890,4 @@ SceneRoots:
- {fileID: 1681788161}
- {fileID: 1445156949}
- {fileID: 750131492}
- {fileID: 1006275184}
+3 -1
View File
@@ -1,6 +1,7 @@
using System;
using UnityEngine;
using Object = System.Object;
using UnityEngine.SceneManagement;
public class DamageHandler : MonoBehaviour
{
@@ -69,6 +70,7 @@ public class DamageHandler : MonoBehaviour
public void Die()
{
Destroy(gameObject);
SceneManager.LoadScene(3, LoadSceneMode.Single);
Destroy(gameObject);
}
}
+13 -6
View File
@@ -1,5 +1,6 @@
using UnityEngine;
using System.Collections;
using UnityEngine.SceneManagement;
public class DropletMovement : MonoBehaviour
{
@@ -86,9 +87,18 @@ public class DropletMovement : MonoBehaviour
if (isDashing || isDropping)
{
return;
}
} // was here before
rb.linearVelocity = new Vector2(movement.x * moveSpeed, rb.linearVelocity.y);
float windForce = 0f;
if (WindManager.Instance != null)
{
windForce = WindManager.Instance.CurrentWindForce;
}
rb.linearVelocity = new Vector2(movement.x * moveSpeed + windForce, rb.linearVelocity.y);
//used to be rb.linearVelocity = new Vector2(movement.x * moveSpeed, rb.linearVelocity.y);
}
private void OnTriggerEnter2D(Collider2D other)
@@ -97,6 +107,7 @@ public class DropletMovement : MonoBehaviour
//Hole
if (other.CompareTag("Hole"))
{
SceneManager.LoadScene(2, LoadSceneMode.Single);
Destroy(gameObject);
Debug.Log("Fell in hole!");
}
@@ -138,10 +149,6 @@ public class DropletMovement : MonoBehaviour
isGrounded = true;
}
private void OnCollisionExit2D(Collision2D col)
{
isGrounded = false;
}
private void DropDown()
{
+8
View File
@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: c75792f2507b4ad4193b0d02e0f844bb
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
-14
View File
@@ -1,14 +0,0 @@
using UnityEngine;
using UnityEngine.SceneManagement;
public class SceneController : MonoBehaviour
{
// Start is called once before the first execution of Update after the MonoBehaviour is created
public int sceneIndex;
private void OggerEnter2D(Collider2D collision)
{
Debug.Log("Hole");
SceneManager.LoadScene(sceneIndex, LoadSceneMode.Single);
}
}
@@ -1,2 +0,0 @@
fileFormatVersion: 2
guid: bbf8ab4673d6bf447aab098a12320431
+47
View File
@@ -0,0 +1,47 @@
using UnityEngine;
using System.Collections;
public class WindManager : MonoBehaviour
{
public static WindManager Instance;
public float windStrength = 5f;
public float windDuration = 10f;
public float minTimeBetweenWind = 5f;
public float maxTimeBetweenWind = 20f;
public float CurrentWindForce { get; private set; }
void Awake()
{
Instance = this;
}
void Start()
{
StartCoroutine(WindRoutine());
}
IEnumerator WindRoutine()
{
while (true)
{
float waitTime = Random.Range(
minTimeBetweenWind,
maxTimeBetweenWind
);
yield return new WaitForSeconds(waitTime);
CurrentWindForce =
Random.value < 0.5f
? -windStrength
: windStrength;
yield return new WaitForSeconds(windDuration);
CurrentWindForce = 0f;
}
}
}
+2
View File
@@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: 77a372e261eab9a4b9b6cf05e6c6e576