Added linear movement system
This commit is contained in:
parent
7e7e6c227b
commit
31f45646a6
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Before Width: | Height: | Size: 129 B After Width: | Height: | Size: 9.7 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -131,6 +131,7 @@ GameObject:
|
||||
- component: {fileID: 519420032}
|
||||
- component: {fileID: 519420031}
|
||||
- component: {fileID: 519420029}
|
||||
- component: {fileID: 519420030}
|
||||
m_Layer: 0
|
||||
m_Name: Main Camera
|
||||
m_TagString: MainCamera
|
||||
@ -146,6 +147,102 @@ AudioListener:
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 519420028}
|
||||
m_Enabled: 1
|
||||
--- !u!82 &519420030
|
||||
AudioSource:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 519420028}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 4
|
||||
OutputAudioMixerGroup: {fileID: 0}
|
||||
m_audioClip: {fileID: 0}
|
||||
m_PlayOnAwake: 1
|
||||
m_Volume: 1
|
||||
m_Pitch: 1
|
||||
Loop: 0
|
||||
Mute: 0
|
||||
Spatialize: 0
|
||||
SpatializePostEffects: 0
|
||||
Priority: 128
|
||||
DopplerLevel: 1
|
||||
MinDistance: 1
|
||||
MaxDistance: 500
|
||||
Pan2D: 0
|
||||
rolloffMode: 0
|
||||
BypassEffects: 0
|
||||
BypassListenerEffects: 0
|
||||
BypassReverbZones: 0
|
||||
rolloffCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
panLevelCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
spreadCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
reverbZoneMixCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
--- !u!20 &519420031
|
||||
Camera:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -173,7 +270,7 @@ Camera:
|
||||
far clip plane: 1000
|
||||
field of view: 60
|
||||
orthographic: 1
|
||||
orthographic size: 5
|
||||
orthographic size: 3.846261
|
||||
m_Depth: -1
|
||||
m_CullingMask:
|
||||
serializedVersion: 2
|
||||
@ -203,7 +300,7 @@ Transform:
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1001 &1093585190
|
||||
--- !u!1001 &902015224705780105
|
||||
PrefabInstance:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
@ -213,17 +310,17 @@ PrefabInstance:
|
||||
- target: {fileID: 902015223802321990, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
propertyPath: m_Name
|
||||
value: playerSprite
|
||||
value: player
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 902015223802322008, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0.09065782
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 902015223802322008, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: -0.80686015
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 902015223802322008, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
@ -253,7 +350,7 @@ PrefabInstance:
|
||||
- target: {fileID: 902015223802322008, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
propertyPath: m_RootOrder
|
||||
value: 1
|
||||
value: 2
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 902015223802322008, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
@ -272,39 +369,72 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_SourcePrefab: {fileID: 100100000, guid: 76a394fdf7248fa47bd4aa9e89fd70b3, type: 3}
|
||||
--- !u!4 &1640620845 stripped
|
||||
Transform:
|
||||
m_CorrespondingSourceObject: {fileID: 902015223802322008, guid: 76a394fdf7248fa47bd4aa9e89fd70b3,
|
||||
type: 3}
|
||||
m_PrefabInstance: {fileID: 1093585190}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
--- !u!1 &2050903086
|
||||
GameObject:
|
||||
--- !u!1001 &5632577434729200769
|
||||
PrefabInstance:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 2050903087}
|
||||
m_Layer: 0
|
||||
m_Name: GameObject
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &2050903087
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2050903086}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0.309, y: -0.027, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 1640620845}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 6643425741070780325, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_Name
|
||||
value: bullet
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 1.4065564
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: -0.055262655
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_RootOrder
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3715179575847562253, guid: 8ef48f5a22c887a4c8940dcc6586073a,
|
||||
type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_SourcePrefab: {fileID: 100100000, guid: 8ef48f5a22c887a4c8940dcc6586073a, type: 3}
|
||||
|
4
Assets/graphic/bullet.svg
Normal file
4
Assets/graphic/bullet.svg
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="7.5" width="42.5" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" id="330b1770-51ca-11ea-9856-0015830cbfeb">
|
||||
<rect width="21.25" height="7" fill="#ffed00" />
|
||||
</svg>
|
After Width: | Height: | Size: 262 B |
54
Assets/graphic/bullet.svg.meta
Normal file
54
Assets/graphic/bullet.svg.meta
Normal file
@ -0,0 +1,54 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7cac2d80606718c4ea29a0ecb60dd0bf
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: a57477913897c46af95d590f580878bd, type: 3}
|
||||
svgType: 0
|
||||
texturedSpriteMeshType: 0
|
||||
svgPixelsPerUnit: 100
|
||||
gradientResolution: 64
|
||||
alignment: 0
|
||||
customPivot: {x: 0, y: 0}
|
||||
generatePhysicsShape: 0
|
||||
viewportOptions: 0
|
||||
preserveViewport: 0
|
||||
advancedMode: 0
|
||||
predefinedResolutionIndex: 1
|
||||
targetResolution: 1080
|
||||
resolutionMultiplier: 1
|
||||
stepDistance: 10
|
||||
samplingStepDistance: 100
|
||||
maxCordDeviationEnabled: 0
|
||||
maxCordDeviation: 1
|
||||
maxTangentAngleEnabled: 0
|
||||
maxTangentAngle: 5
|
||||
keepTextureAspectRatio: 1
|
||||
textureSize: 256
|
||||
textureWidth: 256
|
||||
textureHeight: 256
|
||||
wrapMode: 0
|
||||
filterMode: 1
|
||||
sampleCount: 4
|
||||
preserveSVGImageAspect: 0
|
||||
spriteData:
|
||||
TessellationDetail: 0
|
||||
SpriteRect:
|
||||
name:
|
||||
originalName:
|
||||
pivot: {x: 0, y: 0}
|
||||
alignment: 0
|
||||
border: {x: 0, y: 0, z: 0, w: 0}
|
||||
rect:
|
||||
serializedVersion: 2
|
||||
x: 0
|
||||
y: 0
|
||||
width: 0
|
||||
height: 0
|
||||
spriteID: a161b18f895147344b194be1cf2b9eb6
|
||||
internalID: 0
|
||||
PhysicsOutlines: []
|
8
Assets/graphic/enemies.meta
Normal file
8
Assets/graphic/enemies.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b815acb92ca269f448b84b5b58774506
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/graphic/enemies/icosahedron.fbx
Normal file
BIN
Assets/graphic/enemies/icosahedron.fbx
Normal file
Binary file not shown.
BIN
Assets/graphic/icosahedron.fbx
(Stored with Git LFS)
BIN
Assets/graphic/icosahedron.fbx
(Stored with Git LFS)
Binary file not shown.
8
Assets/graphic/player.meta
Normal file
8
Assets/graphic/player.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ee3293973283e84488039ad1093fdd27
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Before Width: | Height: | Size: 402 B After Width: | Height: | Size: 402 B |
99
Assets/prefab/bullet.prefab
Normal file
99
Assets/prefab/bullet.prefab
Normal file
@ -0,0 +1,99 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &6643425741070780325
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 3715179575847562253}
|
||||
- component: {fileID: 5388942151301465772}
|
||||
- component: {fileID: 5632577436404948121}
|
||||
m_Layer: 0
|
||||
m_Name: bullet
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &3715179575847562253
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6643425741070780325}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 1.4065564, y: -0.055262655, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &5388942151301465772
|
||||
SpriteRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6643425741070780325}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: 73ddb2958e9cd451c82f37c26efa5eb0, 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_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
m_Sprite: {fileID: 3286163911610860551, guid: 7cac2d80606718c4ea29a0ecb60dd0bf,
|
||||
type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 0
|
||||
m_Size: {x: 0.2125, y: 0.07}
|
||||
m_AdaptiveModeThreshold: 0.5
|
||||
m_SpriteTileMode: 0
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!114 &5632577436404948121
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6643425741070780325}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 071da364fc12490499cc6365c2e7a7fc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
acc: 0
|
||||
lifespan: 1
|
||||
damage: 1
|
7
Assets/prefab/bullet.prefab.meta
Normal file
7
Assets/prefab/bullet.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8ef48f5a22c887a4c8940dcc6586073a
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -29,7 +29,8 @@ Transform:
|
||||
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_Children:
|
||||
- {fileID: 4714467358480855465}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
@ -123,4 +124,48 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: 4c9d76b1e7bbf2d498eca3de6f5f8d08, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
speed: 0
|
||||
speed: 0.2
|
||||
--- !u!1 &4883835456922246276
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 4714467358480855465}
|
||||
- component: {fileID: 1545767161970403452}
|
||||
m_Layer: 0
|
||||
m_Name: FirePoint1
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &4714467358480855465
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 4883835456922246276}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0.291, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 902015223802322008}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &1545767161970403452
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 4883835456922246276}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 8e01463dd85b2b64c8f7e54429a55e0d, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
b: {fileID: 6643425741070780325, guid: 8ef48f5a22c887a4c8940dcc6586073a, type: 3}
|
||||
|
13
Assets/script/Health.cs
Normal file
13
Assets/script/Health.cs
Normal file
@ -0,0 +1,13 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class Health : MonoBehaviour
|
||||
{
|
||||
public int hp;
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
if (hp <= 0) Destroy(gameObject);
|
||||
}
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0d44ecfac57ea864390136ef706f6ad3
|
||||
guid: 0e4afaf1f5cbbf349b1b3696f74e894c
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
@ -1,19 +0,0 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class Bullet : MonoBehaviour
|
||||
{
|
||||
Rigidbody2D rb;
|
||||
public float damage;
|
||||
public float time = 2f;
|
||||
|
||||
public void ApplyVel(Vector2 dir,float speed) {
|
||||
rb = GetComponent<Rigidbody2D>();
|
||||
rb.velocity = dir * speed;
|
||||
Destroy(gameObject, time);
|
||||
}
|
||||
private void OnCollisionEnter2D(Collision2D c) {
|
||||
Destroy(gameObject);
|
||||
}
|
||||
}
|
16
Assets/script/movement/Bullet1.cs
Normal file
16
Assets/script/movement/Bullet1.cs
Normal file
@ -0,0 +1,16 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class Bullet1 : Mover {
|
||||
public float lifespan = 1;
|
||||
public int damage = 1;
|
||||
public override float MoveX(float a) { return a; }
|
||||
public override float MoveY(float a) { return 0f; }
|
||||
private void OnCollisionEnter2D(Collision2D c) {
|
||||
var hh = gameObject.GetComponent<Health>();
|
||||
if(hh) hh.hp -= damage;
|
||||
Destroy(gameObject);
|
||||
}
|
||||
void OnEnable() => Destroy(gameObject, lifespan);
|
||||
}
|
11
Assets/script/movement/Bullet1.cs.meta
Normal file
11
Assets/script/movement/Bullet1.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 071da364fc12490499cc6365c2e7a7fc
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
16
Assets/script/movement/Bullet2.cs
Normal file
16
Assets/script/movement/Bullet2.cs
Normal file
@ -0,0 +1,16 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class Bullet2 : Mover {
|
||||
public float lifespan = 1;
|
||||
public int damage = 1;
|
||||
public override float MoveX(float a) { return a; }
|
||||
public override float MoveY(float a) { return a; }
|
||||
private void OnCollisionEnter2D(Collision2D c) {
|
||||
var hh = gameObject.GetComponent<Health>();
|
||||
if(hh) hh.hp -= damage;
|
||||
Destroy(gameObject);
|
||||
}
|
||||
void OnEnable() => Destroy(gameObject, lifespan);
|
||||
}
|
11
Assets/script/movement/Bullet2.cs.meta
Normal file
11
Assets/script/movement/Bullet2.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8eb38cc5f3c61944e973b6766e893473
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
16
Assets/script/movement/Bullet3.cs
Normal file
16
Assets/script/movement/Bullet3.cs
Normal file
@ -0,0 +1,16 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class Bullet3 : Mover {
|
||||
public float lifespan = 1;
|
||||
public int damage = 1;
|
||||
public override float MoveX(float a) { return a; }
|
||||
public override float MoveY(float a) { return -a; }
|
||||
private void OnCollisionEnter2D(Collision2D c) {
|
||||
var hh = gameObject.GetComponent<Health>();
|
||||
if(hh) hh.hp -= damage;
|
||||
Destroy(gameObject);
|
||||
}
|
||||
void OnEnable() => Destroy(gameObject, lifespan);
|
||||
}
|
11
Assets/script/movement/Bullet3.cs.meta
Normal file
11
Assets/script/movement/Bullet3.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c9feaf970a356774b86fa4c0dbadc15f
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
10
Assets/script/movement/FirePoint.cs
Normal file
10
Assets/script/movement/FirePoint.cs
Normal file
@ -0,0 +1,10 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class FirePoint : MonoBehaviour {
|
||||
public GameObject b;
|
||||
void Fire() {
|
||||
Instantiate(b);
|
||||
}
|
||||
}
|
11
Assets/script/movement/FirePoint.cs.meta
Normal file
11
Assets/script/movement/FirePoint.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8e01463dd85b2b64c8f7e54429a55e0d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
14
Assets/script/movement/Mover.cs
Normal file
14
Assets/script/movement/Mover.cs
Normal file
@ -0,0 +1,14 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public abstract class Mover : MonoBehaviour {
|
||||
public float acc;
|
||||
// Update is called once per frame
|
||||
void Update() {
|
||||
acc += Time.deltaTime;
|
||||
gameObject.transform.position = new Vector3(this.MoveX(acc), this.MoveY(acc), 0);
|
||||
}
|
||||
public abstract float MoveX(float a);
|
||||
public abstract float MoveY(float a);
|
||||
}
|
11
Assets/script/movement/Mover.cs.meta
Normal file
11
Assets/script/movement/Mover.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2310086e249e48a4dbd59fc708b4cd2f
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -5,7 +5,8 @@ using UnityEngine;
|
||||
|
||||
|
||||
public class PlayerController : MonoBehaviour {
|
||||
public float speed;
|
||||
Vector3 direction;
|
||||
public float speed = 0.5f;
|
||||
#if tmp
|
||||
public GameObject bullet;
|
||||
#endif
|
||||
@ -17,7 +18,7 @@ public class PlayerController : MonoBehaviour {
|
||||
|
||||
// Update is called once per frame
|
||||
void Update() {
|
||||
gameObject.transform.position += new Vector3(Input.GetAxisRaw("Horizontal"), Input.GetAxisRaw("Vertical"), 0);
|
||||
|
||||
gameObject.transform.position += new Vector3(Input.GetAxisRaw("Horizontal"), Input.GetAxisRaw("Vertical"), 0)*speed;
|
||||
if (Input.GetButton("Fire1")) gameObject.BroadcastMessage("Fire");
|
||||
}
|
||||
}
|
||||
|
BIN
Assets/sound/pulse-alarm.wav
Normal file
BIN
Assets/sound/pulse-alarm.wav
Normal file
Binary file not shown.
22
Assets/sound/pulse-alarm.wav.meta
Normal file
22
Assets/sound/pulse-alarm.wav.meta
Normal file
@ -0,0 +1,22 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5a4ca31e6e952b544be9daf15b8bf649
|
||||
AudioImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 6
|
||||
defaultSettings:
|
||||
loadType: 0
|
||||
sampleRateSetting: 0
|
||||
sampleRateOverride: 44100
|
||||
compressionFormat: 1
|
||||
quality: 1
|
||||
conversionMode: 0
|
||||
platformSettingOverrides: {}
|
||||
forceToMono: 0
|
||||
normalize: 1
|
||||
preloadAudioData: 1
|
||||
loadInBackground: 0
|
||||
ambisonic: 0
|
||||
3D: 1
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 424cbcc780f5ebe43aa8a95ad8460d54
|
||||
guid: 2668cf5fa562e9b4abd2f001844e2d02
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
|
@ -42,7 +42,7 @@ InputManager:
|
||||
descriptiveName:
|
||||
descriptiveNegativeName:
|
||||
negativeButton:
|
||||
positiveButton: left ctrl
|
||||
positiveButton: left shift
|
||||
altNegativeButton:
|
||||
altPositiveButton: mouse 0
|
||||
gravity: 1000
|
||||
|
@ -4,7 +4,7 @@
|
||||
PlayerSettings:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 18
|
||||
productGUID: 6cad107df9f67134b9847c69f3e29f73
|
||||
productGUID: 2e3cfe85a15a27644a40759a2d988d76
|
||||
AndroidProfiler: 0
|
||||
AndroidFilterTouchesWhenObscured: 0
|
||||
AndroidEnableSustainedPerformanceMode: 0
|
||||
@ -13,7 +13,7 @@ PlayerSettings:
|
||||
useOnDemandResources: 0
|
||||
accelerometerFrequency: 60
|
||||
companyName: DefaultCompany
|
||||
productName: technix-e
|
||||
productName: technix
|
||||
defaultCursor: {fileID: 0}
|
||||
cursorHotspot: {x: 0, y: 0}
|
||||
m_SplashScreenBackgroundColor: {r: 0.13725491, g: 0.12156863, b: 0.1254902, a: 1}
|
||||
@ -593,6 +593,7 @@ PlayerSettings:
|
||||
daydreamIconForeground: {fileID: 0}
|
||||
daydreamIconBackground: {fileID: 0}
|
||||
cloudServicesEnabled:
|
||||
Collab: 1
|
||||
UNet: 1
|
||||
luminIcon:
|
||||
m_Name:
|
||||
@ -613,11 +614,11 @@ PlayerSettings:
|
||||
facebookXfbml: 0
|
||||
facebookFrictionlessRequests: 1
|
||||
apiCompatibilityLevel: 6
|
||||
cloudProjectId:
|
||||
cloudProjectId: 0ca7fcaa-e8e4-4145-a938-c05989a2c43d
|
||||
framebufferDepthMemorylessMode: 0
|
||||
projectName:
|
||||
organizationId:
|
||||
projectName: technix
|
||||
organizationId: as8756m
|
||||
cloudEnabled: 0
|
||||
enableNativePlatformBackendsForNewInputSystem: 0
|
||||
enableNativePlatformBackendsForNewInputSystem: 1
|
||||
disableOldInputManagerSupport: 0
|
||||
legacyClampBlendShapeWeights: 1
|
||||
|
@ -12,14 +12,14 @@ UnityConnectSettings:
|
||||
m_TestInitMode: 0
|
||||
CrashReportingSettings:
|
||||
m_EventUrl: https://perf-events.cloud.unity3d.com
|
||||
m_Enabled: 0
|
||||
m_Enabled: 1
|
||||
m_LogBufferSize: 10
|
||||
m_CaptureEditorExceptions: 1
|
||||
UnityPurchasingSettings:
|
||||
m_Enabled: 0
|
||||
m_TestMode: 0
|
||||
UnityAnalyticsSettings:
|
||||
m_Enabled: 0
|
||||
m_Enabled: 1
|
||||
m_TestMode: 0
|
||||
m_InitializeOnStartup: 1
|
||||
UnityAdsSettings:
|
||||
|
Loading…
Reference in New Issue
Block a user