diff --git a/Assets/MagicBook/Prefabs/Spells/Fireball/FireRange.prefab b/Assets/MagicBook/Prefabs/Spells/Fireball/FireRange.prefab index 7f1002d2..1f5f2f6b 100644 --- a/Assets/MagicBook/Prefabs/Spells/Fireball/FireRange.prefab +++ b/Assets/MagicBook/Prefabs/Spells/Fireball/FireRange.prefab @@ -80,7 +80,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 1 + m_IsActive: 0 --- !u!1 &1732161132606102 GameObject: m_ObjectHideFlags: 0 @@ -253,7 +253,7 @@ MonoBehaviour: m_EditorClassIdentifier: fireEffect: {fileID: 199894523801454330} smokeEffect: {fileID: 198456965011063730} - attackDamage: 15 + attackDamage: 0 totalBurnDuration: 3 --- !u!135 &135792272438208660 SphereCollider: @@ -1025,7 +1025,7 @@ ParticleSystem: m_Curve: - serializedVersion: 2 time: 0 - value: 0.18324476 + value: 0 inSlope: -0.07575034 outSlope: -0.07575034 tangentMode: 0 @@ -1275,9 +1275,9 @@ ParticleSystem: maxGradient: serializedVersion: 2 key0: {r: 1, g: 1, b: 1, a: 0} - key1: {r: 1, g: 1, b: 1, a: 0.7764706} - key2: {r: 0, g: 0, b: 0, a: 0.75686276} - key3: {r: 0, g: 0, b: 0, a: 0} + key1: {r: 1, g: 1, b: 1, a: 0.4890443} + key2: {r: 0, g: 0, b: 0, a: 0.7764706} + key3: {r: 0, g: 0, b: 0, a: 0.75686276} key4: {r: 0, g: 0, b: 0, a: 0} key5: {r: 0, g: 0, b: 0, a: 0} key6: {r: 0, g: 0, b: 0, a: 0} @@ -1291,16 +1291,16 @@ ParticleSystem: ctime6: 0 ctime7: 0 atime0: 0 - atime1: 11180 - atime2: 32575 - atime3: 65535 - atime4: 0 + atime1: 15420 + atime2: 34888 + atime3: 48766 + atime4: 65535 atime5: 0 atime6: 0 atime7: 0 m_Mode: 0 m_NumColorKeys: 2 - m_NumAlphaKeys: 4 + m_NumAlphaKeys: 5 minGradient: serializedVersion: 2 key0: {r: 1, g: 1, b: 1, a: 1} @@ -3733,7 +3733,7 @@ ParticleSystem: moveWithTransform: 0 moveWithCustomTransform: {fileID: 0} scalingMode: 0 - randomSeed: -486847166 + randomSeed: 622838997 InitialModule: serializedVersion: 3 enabled: 1 @@ -6359,7 +6359,7 @@ ParticleSystem: m_PreInfinity: 2 m_PostInfinity: 2 m_RotationOrder: 4 - maxLights: 4 + maxLights: 7 TrailModule: enabled: 0 mode: 0 diff --git a/Assets/MagicBook/Prefabs/Spells/Fireball/FireSmoke.mat b/Assets/MagicBook/Prefabs/Spells/Fireball/FireSmoke.mat index b7fbd585..cacfa842 100644 --- a/Assets/MagicBook/Prefabs/Spells/Fireball/FireSmoke.mat +++ b/Assets/MagicBook/Prefabs/Spells/Fireball/FireSmoke.mat @@ -7,7 +7,7 @@ Material: m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_Name: FireSmoke - m_Shader: {fileID: 203, guid: 0000000000000000f000000000000000, type: 0} + m_Shader: {fileID: 202, guid: 0000000000000000f000000000000000, type: 0} m_ShaderKeywords: m_LightmapFlags: 4 m_EnableInstancingVariants: 0 @@ -73,7 +73,7 @@ Material: - _GlossMapScale: 1 - _Glossiness: 0.5 - _GlossyReflections: 1 - - _InvFade: 3 + - _InvFade: 0.1 - _LightingEnabled: 1 - _Metallic: 0 - _Mode: 0 diff --git a/Assets/MagicBook/Prefabs/Spells/Fireball/Fireball.prefab b/Assets/MagicBook/Prefabs/Spells/Fireball/Fireball.prefab index 495aa177..a717c33e 100644 --- a/Assets/MagicBook/Prefabs/Spells/Fireball/Fireball.prefab +++ b/Assets/MagicBook/Prefabs/Spells/Fireball/Fireball.prefab @@ -42,6 +42,7 @@ GameObject: - component: {fileID: 54785709522886298} - component: {fileID: 82270390973700498} - component: {fileID: 114380002433175008} + - component: {fileID: 65590007657417784} m_Layer: 0 m_Name: Fireball m_TagString: Untagged @@ -164,6 +165,18 @@ Rigidbody: m_Interpolate: 0 m_Constraints: 0 m_CollisionDetection: 0 +--- !u!65 &65590007657417784 +BoxCollider: + m_ObjectHideFlags: 1 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 100100000} + m_GameObject: {fileID: 1740384599701424} + m_Material: {fileID: 0} + m_IsTrigger: 1 + m_Enabled: 0 + serializedVersion: 2 + m_Size: {x: 0.5, y: 0.5, z: 4} + m_Center: {x: 0, y: 0, z: -2} --- !u!82 &82270390973700498 AudioSource: m_ObjectHideFlags: 1 @@ -321,7 +334,7 @@ MonoBehaviour: delayBetweenSpawns: 1 playerHoldScalingDuration: 6 speed: 14 - damage: 15 + damage: 10 maxAdditionalDamage: 30 pointLight: {fileID: 108569519831283328} FireRangePrefab: {fileID: 1673509378881658, guid: 1f33a090d0a27e74f954abe39f8629cf, diff --git a/Assets/MagicBook/Prefabs/Spells/Iceball/SlowRange.prefab b/Assets/MagicBook/Prefabs/Spells/Iceball/SlowRange.prefab index faa1ad84..94efb2be 100644 --- a/Assets/MagicBook/Prefabs/Spells/Iceball/SlowRange.prefab +++ b/Assets/MagicBook/Prefabs/Spells/Iceball/SlowRange.prefab @@ -173,8 +173,8 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 052ce98025f80b144adf563b6fc44a54, type: 3} m_Name: m_EditorClassIdentifier: - slowAmount: 0.5 - slowDuration: 8 + slowAmount: 0.7 + slowDuration: 7 --- !u!135 &135285023128030578 SphereCollider: m_ObjectHideFlags: 1 diff --git a/Assets/MagicBook/Scripts/MagicBook_Animation.cs b/Assets/MagicBook/Scripts/MagicBook_Animation.cs index f910f932..d5e6f2ee 100644 --- a/Assets/MagicBook/Scripts/MagicBook_Animation.cs +++ b/Assets/MagicBook/Scripts/MagicBook_Animation.cs @@ -66,7 +66,7 @@ void Update() gestureTotalMoved = Vector2.zero; } gestureTotalMoved += diff; - if (gestureTotalMoved.magnitude > 0.65f && gestureTimeSpent < 0.3f) // if the gesture is so fast and so long. + if (gestureTotalMoved.magnitude > 0.5f && gestureTimeSpent < 0.33f) // if the gesture is so fast and so long. { var dir = Mathf.Sign(gestureTotalMoved.x) == 1 ? "right" : "left"; isSwiped = true; diff --git a/Assets/MagicBook/Scripts/Spells/Fireball/Fireball.cs b/Assets/MagicBook/Scripts/Spells/Fireball/Fireball.cs index 3eb6f35b..a58683c9 100644 --- a/Assets/MagicBook/Scripts/Spells/Fireball/Fireball.cs +++ b/Assets/MagicBook/Scripts/Spells/Fireball/Fireball.cs @@ -34,6 +34,7 @@ protected override void Update_Derived() OnPlayerHoldSpell(); if (fired) { + transform.Translate(direction * (speed * Time.deltaTime), Space.World); // TODO: edit gravity of fireball to get the moving feel } @@ -62,6 +63,7 @@ public override void OnPlayerHoldSpell() public override void Fire(Vector3 handDirection) { + GetComponent().enabled = true; transform.parent = null; direction = handDirection; fired = true; @@ -102,8 +104,8 @@ void OnTriggerEnter(Collider collider) fireRange.GetComponent().attackDamage = damage; fireRange.transform.position = transform.position; PlayImpactSound(); - print("damage:" + damage.ToString()); - print("radius:" + damageRadius.ToString()); + //print("damage:" + damage.ToString()); + //print("radius:" + damageRadius.ToString()); Destroy(gameObject); } diff --git a/Assets/MagicBook/Scripts/Spells/Iceball/SlowRange.cs b/Assets/MagicBook/Scripts/Spells/Iceball/SlowRange.cs index 21fc067b..c77db4fe 100644 --- a/Assets/MagicBook/Scripts/Spells/Iceball/SlowRange.cs +++ b/Assets/MagicBook/Scripts/Spells/Iceball/SlowRange.cs @@ -10,7 +10,7 @@ public class SlowRange : MonoBehaviour private float increaseDuration = 2f; private float staticDuration = 2f; - public float slowAmount = 0.5f; // slow till speed percentage (0.1 = 10%) on enemy hit + public float slowAmount = 0.7f; // slow till speed percentage (0.1 = 10%) on enemy hit public float slowDuration = 8f; //slow for seconds private static List allSlowedEnemies = new List(); @@ -81,6 +81,8 @@ void AddEffectToEnemy(Enemy enemy) void RemoveEffectOnEnemy(Enemy enemy) { + if (enemy == null) + return; var navMesh = enemy.GetComponent(); navMesh.speed /= slowAmount; }