mirror of
https://github.com/ConjureETS/VZ.git
synced 2026-03-24 02:11:15 +00:00
- Added Tag manager
- Added Class ZombieUnit (extends the Unit class) - Added class VampireUnit (extends the Unit class)
This commit is contained in:
parent
18c585cd29
commit
5837a7f2c9
138
Assets/Materials/vampire_color.mat
Normal file
138
Assets/Materials/vampire_color.mat
Normal file
@ -0,0 +1,138 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!21 &2100000
|
||||
Material:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_Name: vampire_color
|
||||
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_ShaderKeywords:
|
||||
m_LightmapFlags: 5
|
||||
m_CustomRenderQueue: -1
|
||||
stringTagMap: {}
|
||||
m_SavedProperties:
|
||||
serializedVersion: 2
|
||||
m_TexEnvs:
|
||||
data:
|
||||
first:
|
||||
name: _MainTex
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _BumpMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _DetailNormalMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _ParallaxMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _OcclusionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _EmissionMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _DetailMask
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _DetailAlbedoMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
data:
|
||||
first:
|
||||
name: _MetallicGlossMap
|
||||
second:
|
||||
m_Texture: {fileID: 0}
|
||||
m_Scale: {x: 1, y: 1}
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_Floats:
|
||||
data:
|
||||
first:
|
||||
name: _SrcBlend
|
||||
second: 1
|
||||
data:
|
||||
first:
|
||||
name: _DstBlend
|
||||
second: 0
|
||||
data:
|
||||
first:
|
||||
name: _Cutoff
|
||||
second: .5
|
||||
data:
|
||||
first:
|
||||
name: _Parallax
|
||||
second: .0199999996
|
||||
data:
|
||||
first:
|
||||
name: _ZWrite
|
||||
second: 1
|
||||
data:
|
||||
first:
|
||||
name: _Glossiness
|
||||
second: .5
|
||||
data:
|
||||
first:
|
||||
name: _BumpScale
|
||||
second: 1
|
||||
data:
|
||||
first:
|
||||
name: _OcclusionStrength
|
||||
second: 1
|
||||
data:
|
||||
first:
|
||||
name: _DetailNormalMapScale
|
||||
second: 1
|
||||
data:
|
||||
first:
|
||||
name: _UVSec
|
||||
second: 0
|
||||
data:
|
||||
first:
|
||||
name: _Mode
|
||||
second: 0
|
||||
data:
|
||||
first:
|
||||
name: _Metallic
|
||||
second: 0
|
||||
m_Colors:
|
||||
data:
|
||||
first:
|
||||
name: _EmissionColor
|
||||
second: {r: 0, g: 0, b: 0, a: 1}
|
||||
data:
|
||||
first:
|
||||
name: _Color
|
||||
second: {r: .963235319, g: .035413038, b: .035413038, a: 1}
|
||||
8
Assets/Materials/vampire_color.mat.meta
Normal file
8
Assets/Materials/vampire_color.mat.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 975becc44691fa643872575fe45a0f2e
|
||||
timeCreated: 1439299878
|
||||
licenseType: Free
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
BIN
Assets/New Terrain.asset
Normal file
BIN
Assets/New Terrain.asset
Normal file
Binary file not shown.
8
Assets/New Terrain.asset.meta
Normal file
8
Assets/New Terrain.asset.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: cc285f3696aa7d5449dcd631a7166155
|
||||
timeCreated: 1439299972
|
||||
licenseType: Free
|
||||
NativeFormatImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@ -87,6 +87,211 @@ NavMeshSettings:
|
||||
cellSize: .166666672
|
||||
manualCellSize: 0
|
||||
m_NavMeshData: {fileID: 0}
|
||||
--- !u!1 &90076749
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 4
|
||||
m_Component:
|
||||
- 4: {fileID: 90076750}
|
||||
- 33: {fileID: 90076754}
|
||||
- 135: {fileID: 90076753}
|
||||
- 23: {fileID: 90076752}
|
||||
- 114: {fileID: 90076751}
|
||||
m_Layer: 0
|
||||
m_Name: CollisionField
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &90076750
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 90076749}
|
||||
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_Children: []
|
||||
m_Father: {fileID: 209133699}
|
||||
m_RootOrder: 0
|
||||
--- !u!114 &90076751
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 90076749}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 8a1ccd1ad32d6bc4fb600c5b5720e01c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
--- !u!23 &90076752
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 90076749}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_Materials:
|
||||
- {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_SubsetIndices:
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_UseLightProbes: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_ImportantGI: 0
|
||||
m_AutoUVMaxDistance: .5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!135 &90076753
|
||||
SphereCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 90076749}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 1
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_Radius: 3
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
--- !u!33 &90076754
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 90076749}
|
||||
m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!1 &209133695
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 4
|
||||
m_Component:
|
||||
- 4: {fileID: 209133699}
|
||||
- 33: {fileID: 209133698}
|
||||
- 65: {fileID: 209133697}
|
||||
- 23: {fileID: 209133696}
|
||||
- 143: {fileID: 209133700}
|
||||
- 54: {fileID: 209133701}
|
||||
- 114: {fileID: 209133702}
|
||||
m_Layer: 0
|
||||
m_Name: Vampire
|
||||
m_TagString: VampirePlayer
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!23 &209133696
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 1
|
||||
m_ReceiveShadows: 1
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: 975becc44691fa643872575fe45a0f2e, type: 2}
|
||||
m_SubsetIndices:
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_UseLightProbes: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_PreserveUVs: 1
|
||||
m_ImportantGI: 0
|
||||
m_AutoUVMaxDistance: .5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingOrder: 0
|
||||
--- !u!65 &209133697
|
||||
BoxCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_Size: {x: 1, y: 1, z: 1}
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
--- !u!33 &209133698
|
||||
MeshFilter:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!4 &209133699
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 5, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 90076750}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
--- !u!143 &209133700
|
||||
CharacterController:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
m_Material: {fileID: 0}
|
||||
m_IsTrigger: 0
|
||||
m_Enabled: 1
|
||||
serializedVersion: 2
|
||||
m_Height: 1
|
||||
m_Radius: .5
|
||||
m_SlopeLimit: 45
|
||||
m_StepOffset: .300000012
|
||||
m_SkinWidth: .0799999982
|
||||
m_MinMoveDistance: .00100000005
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
--- !u!54 &209133701
|
||||
Rigidbody:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
serializedVersion: 2
|
||||
m_Mass: 1
|
||||
m_Drag: 0
|
||||
m_AngularDrag: .0500000007
|
||||
m_UseGravity: 1
|
||||
m_IsKinematic: 0
|
||||
m_Interpolate: 0
|
||||
m_Constraints: 0
|
||||
m_CollisionDetection: 0
|
||||
--- !u!114 &209133702
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 209133695}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: c1cd93867b8a1d7459a4fb92cac63854, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
--- !u!1 &215281597
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -146,7 +351,7 @@ Transform:
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 1
|
||||
m_RootOrder: 2
|
||||
--- !u!1 &370620261
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -231,7 +436,7 @@ Transform:
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_RootOrder: 1
|
||||
--- !u!1 &1674696785
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -243,9 +448,10 @@ GameObject:
|
||||
- 33: {fileID: 1674696789}
|
||||
- 65: {fileID: 1674696788}
|
||||
- 23: {fileID: 1674696787}
|
||||
- 114: {fileID: 1674696790}
|
||||
m_Layer: 0
|
||||
m_Name: Human
|
||||
m_TagString: Untagged
|
||||
m_TagString: Human
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
@ -257,12 +463,12 @@ Transform:
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1674696785}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalPosition: {x: 0, y: 5, z: 25}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 2081975386}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 2
|
||||
m_RootOrder: 3
|
||||
--- !u!23 &1674696787
|
||||
MeshRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -306,6 +512,87 @@ MeshFilter:
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1674696785}
|
||||
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||
--- !u!114 &1674696790
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1674696785}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 8a1ccd1ad32d6bc4fb600c5b5720e01c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
--- !u!1 &1780458434
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
serializedVersion: 4
|
||||
m_Component:
|
||||
- 4: {fileID: 1780458437}
|
||||
- 218: {fileID: 1780458436}
|
||||
- 154: {fileID: 1780458435}
|
||||
m_Layer: 0
|
||||
m_Name: Terrain
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 4294967295
|
||||
m_IsActive: 1
|
||||
--- !u!154 &1780458435
|
||||
TerrainCollider:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1780458434}
|
||||
m_Material: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_TerrainData: {fileID: 15600000, guid: cc285f3696aa7d5449dcd631a7166155, type: 2}
|
||||
m_EnableTreeColliders: 1
|
||||
--- !u!218 &1780458436
|
||||
Terrain:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1780458434}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 3
|
||||
m_TerrainData: {fileID: 15600000, guid: cc285f3696aa7d5449dcd631a7166155, type: 2}
|
||||
m_TreeDistance: 5000
|
||||
m_TreeBillboardDistance: 50
|
||||
m_TreeCrossFadeLength: 5
|
||||
m_TreeMaximumFullLODCount: 50
|
||||
m_DetailObjectDistance: 80
|
||||
m_DetailObjectDensity: 1
|
||||
m_HeightmapPixelError: 5
|
||||
m_SplatMapDistance: 1000
|
||||
m_HeightmapMaximumLOD: 0
|
||||
m_CastShadows: 1
|
||||
m_DrawHeightmap: 1
|
||||
m_DrawTreesAndFoliage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_MaterialType: 0
|
||||
m_LegacySpecular:
|
||||
serializedVersion: 2
|
||||
rgba: 4286545791
|
||||
m_LegacyShininess: .078125
|
||||
m_MaterialTemplate: {fileID: 0}
|
||||
m_BakeLightProbesForTrees: 1
|
||||
m_ScaleInLightmap: .0511999987
|
||||
m_LightmapParameters: {fileID: 15203, guid: 0000000000000000f000000000000000, type: 0}
|
||||
--- !u!4 &1780458437
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 1780458434}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: -200, y: 0, z: -200}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 4
|
||||
--- !u!1 &2081975382
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@ -6,13 +6,13 @@ public class Command : MonoBehaviour
|
||||
|
||||
// Use this for initialization
|
||||
void Start ()
|
||||
{
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update ()
|
||||
{
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
14
Assets/Scripts/TagManager.cs
Normal file
14
Assets/Scripts/TagManager.cs
Normal file
@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
using System.Linq;
|
||||
|
||||
public class TagManager : MonoBehaviour
|
||||
{
|
||||
// Use this for initialization
|
||||
private static readonly String[] availableTags = UnityEditorInternal.InternalEditorUtility.tags;
|
||||
// TODO FIND A WAY TO ADD EXCEPTION ERROR IF THE USER OMMIT TO ADD TAGS!!!
|
||||
public static String Human = availableTags[7];
|
||||
public static String VampirePlayer = availableTags[8];
|
||||
public static String ZombiePlayer = availableTags[9];
|
||||
}
|
||||
12
Assets/Scripts/TagManager.cs.meta
Normal file
12
Assets/Scripts/TagManager.cs.meta
Normal file
@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b58258f2de3f66040b725bd920298179
|
||||
timeCreated: 1439302840
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@ -1,49 +1,55 @@
|
||||
using UnityEngine;
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
public class Unit : MonoBehaviour
|
||||
{
|
||||
public int HP { get; set; }
|
||||
public int Attack { get; set; }
|
||||
public bool isAlly { get; set; }
|
||||
public bool isHuman { get; set; }
|
||||
public bool isDead { get; set; }
|
||||
|
||||
private LinkedList<Command> commandList;
|
||||
// Use this for initialization
|
||||
void Start ()
|
||||
{
|
||||
// initialize default hp
|
||||
// initialize default attack
|
||||
// initialize default team
|
||||
// initialize default specie
|
||||
// initialize default hp
|
||||
// initialize default attack
|
||||
// initialize default team
|
||||
// initialize default specie
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update ()
|
||||
{
|
||||
//
|
||||
|
||||
if (isDead)
|
||||
{
|
||||
|
||||
}
|
||||
//
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Add a command at the end of the list
|
||||
/// </summary>
|
||||
/// <param name="c">The command to add</param>
|
||||
/// <summary>
|
||||
/// Add a command at the end of the list
|
||||
/// </summary>
|
||||
/// <param name="c">The command to add</param>
|
||||
public void addCommand(Command c)
|
||||
{
|
||||
this.commandList.AddLast(c);
|
||||
}
|
||||
|
||||
public void executeCommand()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void executeCommand()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
#region Unit properties
|
||||
|
||||
public int HP { get; set; }
|
||||
public int Attack { get; set; }
|
||||
//public bool isAlly { get; set; }
|
||||
//public bool isHuman { get; set; }
|
||||
public bool isDead { get; set; }
|
||||
|
||||
public String Tag
|
||||
{
|
||||
get { return this.gameObject.tag; }
|
||||
set { gameObject.tag = value; }
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
}
|
||||
|
||||
38
Assets/Scripts/VampireUnit.cs
Normal file
38
Assets/Scripts/VampireUnit.cs
Normal file
@ -0,0 +1,38 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
/// <summary>
|
||||
/// This class contains the information of the Vampire Units.
|
||||
/// </summary>
|
||||
public class VampireUnit : Unit
|
||||
{
|
||||
// Use this for initialization
|
||||
void Start ()
|
||||
{
|
||||
InitializeDefaultTag();
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update ()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void InitializeDefaultTag()
|
||||
{
|
||||
try
|
||||
{
|
||||
this.Tag = TagManager.VampirePlayer; // set the tag to player 1
|
||||
}
|
||||
catch (IndexOutOfRangeException ex)
|
||||
{
|
||||
Debug.LogError( "Please set a vampire Tag, check the Tag & layers in the inspector!\n" + ex );
|
||||
}
|
||||
|
||||
// set the tag of the gameObject to vampire
|
||||
if (this.gameObject.tag != Tag)
|
||||
{
|
||||
this.gameObject.tag = Tag;
|
||||
}
|
||||
}
|
||||
}
|
||||
12
Assets/Scripts/VampireUnit.cs.meta
Normal file
12
Assets/Scripts/VampireUnit.cs.meta
Normal file
@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c1cd93867b8a1d7459a4fb92cac63854
|
||||
timeCreated: 1439305303
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
36
Assets/Scripts/ZombieUnit.cs
Normal file
36
Assets/Scripts/ZombieUnit.cs
Normal file
@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
|
||||
public class ZombieUnit : Unit
|
||||
{
|
||||
// Use this for initialization
|
||||
void Start()
|
||||
{
|
||||
InitializeDefaultTag();
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void InitializeDefaultTag()
|
||||
{
|
||||
try
|
||||
{
|
||||
this.Tag = TagManager.ZombiePlayer; // set the tag to Zombie
|
||||
}
|
||||
catch (IndexOutOfRangeException ex)
|
||||
{
|
||||
Debug.LogError("Please set a zombie Tag, check the Tag & layers in the inspector!\n" + ex);
|
||||
}
|
||||
|
||||
// set the tag of the gameObject to zombie
|
||||
if (this.gameObject.tag != Tag)
|
||||
{
|
||||
this.gameObject.tag = Tag;
|
||||
}
|
||||
}
|
||||
}
|
||||
12
Assets/Scripts/ZombieUnit.cs.meta
Normal file
12
Assets/Scripts/ZombieUnit.cs.meta
Normal file
@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9346fd84c59bd7d42a27381aeed17dbf
|
||||
timeCreated: 1439305314
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@ -5,8 +5,8 @@ TagManager:
|
||||
serializedVersion: 2
|
||||
tags:
|
||||
- Human
|
||||
- Player1
|
||||
- Player2
|
||||
- VampirePlayer
|
||||
- ZombiePlayer
|
||||
layers:
|
||||
- Default
|
||||
- TransparentFX
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user