Add pathing for enemies

This commit is contained in:
2023-02-16 19:07:21 -04:00
parent 3ceb5634df
commit 2dad7631dd
18 changed files with 673 additions and 424 deletions

View File

@ -12,6 +12,7 @@ GameObject:
- component: {fileID: 2981135554967256007}
- component: {fileID: 1540579659150390887}
- component: {fileID: 7146678828090736945}
- component: {fileID: 2294062540900002317}
m_Layer: 0
m_Name: Generation
m_TagString: Untagged
@ -98,7 +99,6 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 6d151e6102b72db4590ce83309573f1c, type: 3}
m_Name:
m_EditorClassIdentifier:
PathGameObject: {fileID: 0}
--- !u!50 &7146678828090736945
Rigidbody2D:
serializedVersion: 4
@ -107,7 +107,7 @@ Rigidbody2D:
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1458536803320539101}
m_BodyType: 0
m_BodyType: 1
m_Simulated: 1
m_UseFullKinematicContacts: 0
m_UseAutoMass: 0
@ -117,6 +117,32 @@ Rigidbody2D:
m_GravityScale: 0
m_Material: {fileID: 0}
m_Interpolate: 0
m_SleepingMode: 1
m_SleepingMode: 0
m_CollisionDetection: 0
m_Constraints: 0
--- !u!61 &2294062540900002317
BoxCollider2D:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1458536803320539101}
m_Enabled: 1
m_Density: 1
m_Material: {fileID: 0}
m_IsTrigger: 1
m_UsedByEffector: 0
m_UsedByComposite: 0
m_Offset: {x: 0, y: 0}
m_SpriteTilingProperty:
border: {x: 0, y: 0, z: 0, w: 0}
pivot: {x: 0.5, y: 0.5}
oldSize: {x: 1, y: 1}
newSize: {x: 1, y: 1}
adaptiveTilingThreshold: 0.5
drawMode: 0
adaptiveTiling: 0
m_AutoTiling: 0
serializedVersion: 2
m_Size: {x: 1, y: 1}
m_EdgeRadius: 0

View File

@ -10,7 +10,9 @@ GameObject:
m_Component:
- component: {fileID: 328858392699145925}
- component: {fileID: 4841795318599809648}
- component: {fileID: 2671460795696364852}
- component: {fileID: 8192986790885562340}
- component: {fileID: -834716027335084487}
- component: {fileID: 8406881250321231346}
m_Layer: 0
m_Name: PathNode
m_TagString: Untagged
@ -27,7 +29,7 @@ Transform:
m_GameObject: {fileID: 2624247600710686983}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.7311517, y: 0.074633844, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_LocalScale: {x: 0.1, y: 0.1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
@ -75,7 +77,7 @@ SpriteRenderer:
m_SortingLayer: 0
m_SortingOrder: 0
m_Sprite: {fileID: 7482667652216324306, guid: 311925a002f4447b3a28927169b83ea6, type: 3}
m_Color: {r: 0, g: 0, b: 0, a: 0}
m_Color: {r: 1, g: 0, b: 0, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
@ -85,16 +87,62 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!65 &2671460795696364852
BoxCollider:
--- !u!50 &8192986790885562340
Rigidbody2D:
serializedVersion: 4
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2624247600710686983}
m_BodyType: 2
m_Simulated: 1
m_UseFullKinematicContacts: 0
m_UseAutoMass: 0
m_Mass: 1
m_LinearDrag: 0
m_AngularDrag: 0.05
m_GravityScale: 1
m_Material: {fileID: 0}
m_Interpolate: 0
m_SleepingMode: 1
m_CollisionDetection: 0
m_Constraints: 0
--- !u!61 &-834716027335084487
BoxCollider2D:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2624247600710686983}
m_Enabled: 1
m_Density: 1
m_Material: {fileID: 0}
m_IsTrigger: 1
m_Enabled: 1
m_UsedByEffector: 0
m_UsedByComposite: 0
m_Offset: {x: 0, y: 0}
m_SpriteTilingProperty:
border: {x: 0, y: 0, z: 0, w: 0}
pivot: {x: 0.5, y: 0.5}
oldSize: {x: 1, y: 1}
newSize: {x: 1, y: 1}
adaptiveTilingThreshold: 0.5
drawMode: 0
adaptiveTiling: 0
m_AutoTiling: 0
serializedVersion: 2
m_Size: {x: 1, y: 1, z: 0.2}
m_Center: {x: 0, y: 0, z: 0}
m_Size: {x: 1, y: 1}
m_EdgeRadius: 0
--- !u!114 &8406881250321231346
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2624247600710686983}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 2346c6ef8f7f55541b5f27987d960a46, type: 3}
m_Name:
m_EditorClassIdentifier: