Compare commits
No commits in common. "master" and "loottable" have entirely different histories.
|
@ -1,6 +1,6 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 81799bac27ab6ed41a883ff29743cf2b
|
||||
PrefabImporter:
|
||||
guid: da52a93af762fab4ab9085821b0fb632
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 10f2e5d2e4dd2ba42b4dcf6195a74f02
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 8bc88477f037e96478019bba8de301fd
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -40,7 +40,7 @@ MeshFilter:
|
|||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 788300690735002878}
|
||||
m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!23 &9000270122588691705
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -61,7 +61,7 @@ MeshRenderer:
|
|||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: b16f64f428b405845a02e79478239092, type: 2}
|
||||
- {fileID: 2100000, guid: 883bbd715dd7e2e428aa32e0c388722a, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
|
|
|
@ -412,7 +412,6 @@ Transform:
|
|||
- {fileID: 2498142198288847795}
|
||||
- {fileID: 2498142196473246274}
|
||||
- {fileID: 2498142196498008887}
|
||||
- {fileID: 7144326527911497039}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
|
@ -499,128 +498,3 @@ MonoBehaviour:
|
|||
output: {fileID: 2498142196498008887}
|
||||
startWand: {fileID: 7748908063851026723, guid: d3af4ebc0ff721d4fbcc988713bb674c,
|
||||
type: 3}
|
||||
--- !u!1001 &832023859129202319
|
||||
PrefabInstance:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 4613100203587676735}
|
||||
m_Modifications:
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.size
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.data[0].m_Mode
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.data[0].m_Target
|
||||
value:
|
||||
objectReference: {fileID: 2498142198148501413}
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.data[0].m_CallState
|
||||
value: 2
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName
|
||||
value: Craft
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.data[0].m_TargetAssemblyTypeName
|
||||
value: CraftingTable, Assembly-CSharp
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554150911968, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: onDown.m_PersistentCalls.m_Calls.Array.data[0].m_Arguments.m_ObjectArgumentAssemblyTypeName
|
||||
value: UnityEngine.Object, UnityEngine
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355069, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_Name
|
||||
value: Lever (1)
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_RootOrder
|
||||
value: 3
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalScale.x
|
||||
value: 0.099999994
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalScale.y
|
||||
value: 0.10000001
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalScale.z
|
||||
value: 0.10000001
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: -0.96562576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 1.348712
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0.6680527
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 0.6532815
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0.27059805
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0.6532815
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0.27059805
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.y
|
||||
value: 90
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.z
|
||||
value: 45
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_SourcePrefab: {fileID: 100100000, guid: cb8b19b563b3d224897e3b3d94c353aa, type: 3}
|
||||
--- !u!4 &7144326527911497039 stripped
|
||||
Transform:
|
||||
m_CorrespondingSourceObject: {fileID: 7543052554475355072, guid: cb8b19b563b3d224897e3b3d94c353aa,
|
||||
type: 3}
|
||||
m_PrefabInstance: {fileID: 832023859129202319}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
|
|
|
@ -12,10 +12,9 @@ GameObject:
|
|||
- component: {fileID: 8183020133483952674}
|
||||
- component: {fileID: 8183020133484680894}
|
||||
- component: {fileID: 8183020133918107436}
|
||||
- component: {fileID: 5150078753582545515}
|
||||
m_Layer: 0
|
||||
m_Name: EssenceWell
|
||||
m_TagString: Portal
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
|
@ -104,16 +103,3 @@ MonoBehaviour:
|
|||
rightDistance: 0.1
|
||||
maxUp: 0.2
|
||||
minDown: -0.2
|
||||
--- !u!135 &5150078753582545515
|
||||
SphereCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8183020133482818824}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_Radius: 0.06824422
|
||||
m_Center: {x: -1.0587912e-21, y: 0.000000018626455, z: -4.4408925e-15}
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -28,21 +28,6 @@ public class CuttableTree : MonoBehaviour
|
|||
{
|
||||
if (other.tag == "Cutter")
|
||||
{
|
||||
Cut();
|
||||
}
|
||||
}
|
||||
void OnCollisionEnter(Collision collision)
|
||||
{
|
||||
if (collision.gameObject.tag == "Cutter")
|
||||
{
|
||||
Cut();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public void Cut()
|
||||
{
|
||||
Debug.LogWarning("CUT");
|
||||
rotation = transform.rotation;
|
||||
rotation *= Quaternion.AngleAxis(20, Vector3.up);
|
||||
Instantiate(stumpPrefab, transform.position, rotation);
|
||||
|
@ -51,3 +36,17 @@ public class CuttableTree : MonoBehaviour
|
|||
Destroy(gameObject);
|
||||
}
|
||||
}
|
||||
void OnCollisionEnter(Collision collision)
|
||||
{
|
||||
if (collision.gameObject.tag == "Cutter")
|
||||
{
|
||||
rotation = transform.rotation;
|
||||
rotation *= Quaternion.AngleAxis(20, Vector3.up);
|
||||
Instantiate(stumpPrefab, transform.position, rotation);
|
||||
Instantiate(logPrefab, transform.position + new Vector3(0, 1, 0), rotation);
|
||||
onCut.Invoke();
|
||||
Destroy(gameObject);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ public class SlimeAI : MonoBehaviour
|
|||
{
|
||||
animator = GetComponent<Animator>();
|
||||
player = GameObject.FindWithTag("Player");
|
||||
HP = 5;
|
||||
HP = 0;
|
||||
|
||||
}
|
||||
|
||||
|
@ -141,7 +141,6 @@ public class SlimeAI : MonoBehaviour
|
|||
{
|
||||
yield return new WaitForSeconds(0.2f);
|
||||
Debug.Log("Attack");
|
||||
PlayerInfo.Instance.AddHealth(-1);
|
||||
//do attack e.g check for player in range/hit collider
|
||||
}
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@ using System.Collections;
|
|||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class SlimeDeath : StateMachineBehaviour
|
||||
public class death : StateMachineBehaviour
|
||||
{
|
||||
// OnStateEnter is called when a transition starts and the state machine starts to evaluate this state
|
||||
//override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
|
||||
|
@ -17,10 +17,10 @@ public class SlimeDeath : StateMachineBehaviour
|
|||
//}
|
||||
|
||||
// OnStateExit is called when a transition ends and the state machine finishes evaluating this state
|
||||
override public void OnStateExit(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
|
||||
{
|
||||
Destroy(animator.gameObject);
|
||||
}
|
||||
//override public void OnStateExit(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
|
||||
//{
|
||||
//
|
||||
//}
|
||||
|
||||
// OnStateMove is called right after Animator.OnAnimatorMove()
|
||||
//override public void OnStateMove(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
|
|
@ -1,5 +1,5 @@
|
|||
fileFormatVersion: 2
|
||||
guid: aa7306c35f4c27d4daefb1259633b9d0
|
||||
guid: 6c7f89faf36f41b418e5105a12c34cdb
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
|
@ -27,6 +27,7 @@ public class ActionGestureInteraction : MonoBehaviour
|
|||
{
|
||||
Debug.LogWarning(action);
|
||||
|
||||
Debug.LogWarning(player.GetComponent<PlayerInfo>().GetRightHand());
|
||||
if (player.GetComponent<PlayerInfo>().GetRightHand() != null)
|
||||
{
|
||||
|
||||
|
@ -51,13 +52,7 @@ public class ActionGestureInteraction : MonoBehaviour
|
|||
}
|
||||
else
|
||||
{
|
||||
GameObject tree = FindTree();
|
||||
if (tree != null)
|
||||
{
|
||||
float distance = Vector3.Distance(transform.position, tree.transform.position);
|
||||
Debug.LogWarning("TREE FOUND: " + distance);
|
||||
if (distance < 6f) tree.GetComponent<CuttableTree>().Cut();
|
||||
}
|
||||
Debug.LogWarning("WOODCUTTING ACTION");
|
||||
}
|
||||
break;
|
||||
case "VerticalLine":
|
||||
|
@ -106,7 +101,7 @@ public class ActionGestureInteraction : MonoBehaviour
|
|||
}
|
||||
else
|
||||
{
|
||||
|
||||
Debug.LogWarning("WOODCUTTING ACTION");
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -177,22 +172,6 @@ public class ActionGestureInteraction : MonoBehaviour
|
|||
return null;
|
||||
}
|
||||
|
||||
GameObject FindTree()
|
||||
{
|
||||
Ray ray = playerCamera.ViewportPointToRay(new Vector3(0.5f, 0.5f, 0));
|
||||
RaycastHit hit;
|
||||
LayerMask playerLayerMask = LayerMask.GetMask("Player");
|
||||
if (Physics.Raycast(ray, out hit, playerLayerMask))
|
||||
{
|
||||
|
||||
if (hit.transform.gameObject.transform.name.StartsWith("Cuttable_Tree_"))
|
||||
{
|
||||
return hit.transform.gameObject;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
void ShootProjectile()
|
||||
{
|
||||
Ray ray = playerCamera.ViewportPointToRay(new Vector3(0.5f, 0.5f, 0));
|
||||
|
|
|
@ -26,7 +26,7 @@ public class EssenceNodeController : MonoBehaviour
|
|||
{
|
||||
nodeMaterial = GetComponent<Renderer>().material;
|
||||
playerInfo = PlayerInfo.Instance;
|
||||
//playerInventory = GameObject.Find("Inventory").GetComponent<Inventory>();
|
||||
playerInventory = GameObject.Find("Inventory").GetComponent<Inventory>();
|
||||
}
|
||||
|
||||
public void Touched()
|
||||
|
@ -65,7 +65,7 @@ public class EssenceNodeController : MonoBehaviour
|
|||
playerInfo.AddEssenceBasic(1);
|
||||
yield return new WaitForSeconds(2f);
|
||||
//TODO: Update value in player inventory
|
||||
//playerInventory.AddItem(GetComponent<ItemData>());
|
||||
playerInventory.AddItem(GetComponent<ItemData>());
|
||||
Destroy(gameObject);
|
||||
}
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ public class PlayerInfo : MonoBehaviour
|
|||
{
|
||||
Instance = this;
|
||||
health = 5;
|
||||
essence_basic = 1;
|
||||
essence_basic = 1000;
|
||||
rightHandHeld = null;
|
||||
leftHandHeld = null;
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 3829f2d229e9f9b44b6d3f85cb2d6653
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 2dc48376fb0fbaa4f93eb47a43ad6560
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -27,18 +27,15 @@ Material:
|
|||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorBlend:
|
||||
m_Texture: {fileID: 8715377698828041336, guid: b6bbea2e1167a7346822545139402874,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorByHeight:
|
||||
m_Texture: {fileID: 4117164932860373842, guid: b6bbea2e1167a7346822545139402874,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorByNormal:
|
||||
m_Texture: {fileID: 8483472128022604842, guid: b6bbea2e1167a7346822545139402874,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _DetailAlbedoMap:
|
||||
|
|
|
@ -40,18 +40,15 @@ Material:
|
|||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorBlend:
|
||||
m_Texture: {fileID: 7633147346474026742, guid: 726ce83d589353742be6b48ff467fc48,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorByHeight:
|
||||
m_Texture: {fileID: 3867667019844413430, guid: 726ce83d589353742be6b48ff467fc48,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorByNormal:
|
||||
m_Texture: {fileID: 1556245102416868720, guid: 726ce83d589353742be6b48ff467fc48,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _DetailAlbedoMap:
|
||||
|
|
|
@ -40,18 +40,15 @@ Material:
|
|||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorBlend:
|
||||
m_Texture: {fileID: 8453615220865481238, guid: 7f589c682d367b442b8cf75918f5aa55,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorByHeight:
|
||||
m_Texture: {fileID: -6360736566364471894, guid: 7f589c682d367b442b8cf75918f5aa55,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _ColorByNormal:
|
||||
m_Texture: {fileID: 71292903075132233, guid: 7f589c682d367b442b8cf75918f5aa55,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _DetailAlbedoMap:
|
||||
|
@ -76,8 +73,7 @@ Material:
|
|||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _MetallicGlossMap:
|
||||
m_Texture: {fileID: -1060774955752299741, guid: 7f589c682d367b442b8cf75918f5aa55,
|
||||
type: 2}
|
||||
m_Texture: {fileID: 2800000, guid: 47a91f8808e6f334a84f127655c54663, type: 3}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
- _OcclusionMap:
|
||||
|
|
Loading…
Reference in New Issue