This commit is contained in:
kawagiri 2025-11-03 18:39:49 +08:00
commit 9552cedb4b
33 changed files with 205 additions and 92 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: BT
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_position":{"x":498.9811,"y":132.3516},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_subTree":{"_value":1},"_tag":"\u5916\u4ea4\u9636\u6bb51","_position":{"x":-657.417,"y":359.7169},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"1"},{"_subTree":{"_value":2},"_tag":"\u9632\u5b88\u79d1\u6280","_position":{"x":-466.1357,"y":360.395},"_comment":"","$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"2"},{"_subTree":{"_value":3},"_tag":"\u82f1\u96c4\u76f8\u5173","_position":{"x":-275.4174,"y":364.7169},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"3"},{"_subTree":{"_value":4},"_tag":"\u57ce\u5e02","_position":{"x":-108.0461,"y":366.8103},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"4"},{"_subTree":{"_value":5},"_tag":"\u53d1\u5c55\u79d1\u6280","_position":{"x":85.8208,"y":368.8981},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"5"},{"_subTree":{"_value":6},"_tag":"\u81ea\u7531\u4eba","_position":{"x":266.637,"y":370.7299},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"6"},{"_subTree":{"_value":7},"_tag":"\u519b\u56e2","_position":{"x":437.7369,"y":370.7564},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"7"},{"_subTree":{"_value":8},"_tag":"\u57ce\u5e02\u907f\u9669","_position":{"x":614.9846,"y":366.9137},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"8"},{"_subTree":{"_value":9},"_tag":"\u5916\u4ea4\u9636\u6bb52","_position":{"x":811.4332,"y":366.9137},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"9"},{"_subTree":{"_value":10},"_tag":"\u514b\u5236\u79d1\u6280","_position":{"x":999.7469,"y":368.7354},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"10"},{"_subTree":{"_value":11},"_tag":"\u6361\u6f0f\u79d1\u6280\u53d1\u5c55","_position":{"x":1212.182,"y":367.5142},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"11"},{"_subTree":{"_value":12},"_position":{"x":1408.252,"y":366.883},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"12"},{"_action":{"nodeId":611,"$type":"NodeCanvas.Tasks.Actions.AIFinishAction"},"_tag":"<color=red>611</color>","_position":{"x":1598.987,"y":371.3896},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"13"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"10"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"11"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"12"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"13"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_position":{"x":498.9811,"y":132.3516},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_subTree":{"_value":1},"_tag":"\u5916\u4ea4\u9636\u6bb51","_position":{"x":-657.417,"y":359.7169},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"1"},{"_subTree":{"_value":2},"_tag":"\u9632\u5b88\u79d1\u6280","_position":{"x":-466.1357,"y":360.395},"_comment":"","$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"2"},{"_subTree":{"_value":3},"_tag":"\u82f1\u96c4\u76f8\u5173","_position":{"x":-275.4174,"y":364.7169},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"3"},{"_subTree":{"_value":4},"_tag":"\u57ce\u5e02","_position":{"x":-108.0461,"y":366.8103},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"4"},{"_subTree":{"_value":5},"_tag":"\u53d1\u5c55\u79d1\u6280","_position":{"x":85.8208,"y":368.8981},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"5"},{"_subTree":{"_value":6},"_tag":"\u81ea\u7531\u4eba","_position":{"x":266.637,"y":370.7299},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"6"},{"_subTree":{"_value":7},"_tag":"\u519b\u56e2","_position":{"x":437.7369,"y":370.7564},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"7"},{"_subTree":{"_value":8},"_tag":"\u57ce\u5e02\u907f\u9669","_position":{"x":614.9846,"y":366.9137},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"8"},{"_subTree":{"_value":9},"_tag":"\u5916\u4ea4\u9636\u6bb52","_position":{"x":811.4332,"y":366.9137},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"9"},{"_subTree":{"_value":10},"_tag":"\u514b\u5236\u79d1\u6280","_position":{"x":999.7469,"y":368.7354},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"10"},{"_subTree":{"_value":11},"_tag":"\u6361\u6f0f\u79d1\u6280\u53d1\u5c55","_position":{"x":1212.182,"y":367.5142},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"11"},{"_subTree":{"_value":12},"_position":{"x":1408.252,"y":366.883},"$type":"NodeCanvas.BehaviourTrees.SubTree","$id":"12"},{"_action":{"nodeId":617,"$type":"NodeCanvas.Tasks.Actions.AIFinishAction"},"_tag":"<color=red>617</color>","_position":{"x":1598.987,"y":371.3896},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"13"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"10"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"11"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"12"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"13"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences:
- {fileID: 0}
- {fileID: 11400000, guid: c4c07567ce3cb2440806f4a218691988, type: 2}
@ -31,7 +31,7 @@ MonoBehaviour:
_version: 3.33
_category:
_comments:
_translation: {x: 551.5631, y: 308.63004}
_zoomFactor: 0.6616123
_translation: {x: 383, y: 118}
_zoomFactor: 1
_haltSerialization: 0
_externalSerializationFile: {fileID: 0}

File diff suppressed because one or more lines are too long

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: CommonTech
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_position":{"x":497.1322,"y":549.8659},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"0"},{"_action":{"MarkStr":"DevelopmentTechFinal","CheckNotHave":true,"nodeId":587,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>587</color>","_position":{"x":113.4,"y":687.2},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"1"},{"_position":{"x":695.4,"y":644.2},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"2"},{"_position":{"x":554.0001,"y":759.6},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"3"},{"_action":{"ActionTypes":[9],"nodeId":588,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>588</color>","_position":{"x":349.4702,"y":902.9698},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"CalculateTypes":[34],"nodeId":589,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>589</color>","_position":{"x":522.9526,"y":905.599},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"nodeId":590,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>590</color>","_position":{"x":742.7128,"y":904.6901},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"MarkStr":"DevelopmentTechFinal","nodeId":591,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>591</color>","_position":{"x":800.4,"y":754.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"3"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"3"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"3"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_position":{"x":497.1322,"y":549.8659},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"0"},{"_action":{"MarkStr":"DevelopmentTechFinal","CheckNotHave":true,"nodeId":593,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>593</color>","_position":{"x":113.4,"y":687.2},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"1"},{"_position":{"x":695.4,"y":644.2},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"2"},{"_position":{"x":554.0001,"y":759.6},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"3"},{"_action":{"ActionTypes":[9],"nodeId":594,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>594</color>","_position":{"x":349.4702,"y":902.9698},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"CalculateTypes":[34],"nodeId":595,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>595</color>","_position":{"x":522.9526,"y":905.599},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"nodeId":596,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>596</color>","_position":{"x":742.7128,"y":904.6901},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"MarkStr":"DevelopmentTechFinal","nodeId":597,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>597</color>","_position":{"x":800.4,"y":754.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"3"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"3"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"3"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: DefendCity
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_position":{"x":233.1071,"y":784.5082},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"0"},{"_action":{"MarkStr":"CityCommonDefend","CheckNotHave":true,"nodeId":523,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>523</color>","_position":{"x":-82.50031,"y":884.0636},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"1"},{"_tag":"","_position":{"x":232.4085,"y":900.0037},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"2"},{"_action":{"Strategy":6,"IsCity":true,"ExtraName":"CommonDefend","nodeId":524,"$type":"NodeCanvas.Tasks.Actions.AIForeachCreate"},"_tag":"<color=red>524</color>","_position":{"x":-170.4937,"y":1009.99},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"nodeId":525,"$type":"NodeCanvas.Tasks.Actions.AIForeachStart"},"_tag":"<color=red>525</color>","_position":{"x":125.8932,"y":1022.25},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_tag":"","_position":{"x":256.9426,"y":1038.827},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"5"},{"_action":{"ActionTypes":[4],"nodeId":526,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>526</color>","_position":{"x":-0.5396254,"y":1226.149},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"nodeId":527,"$type":"NodeCanvas.Tasks.Actions.AIParamDefendTrainUnit"},"_tag":"<color=red>527</color>","_position":{"x":152.9659,"y":1227.126},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"},{"_action":{"CalculateTypes":[7],"nodeId":528,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>528</color>","_position":{"x":295.5356,"y":1225.331},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"},{"_action":{"nodeId":529,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>529</color>","_position":{"x":442.8104,"y":1228.461},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"9"},{"_action":{"nodeId":530,"$type":"NodeCanvas.Tasks.Actions.AIForeachEnd"},"_tag":"<color=red>530</color>","_position":{"x":383.6671,"y":1022.379},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"10"},{"_action":{"MarkStr":"CityCommonDefend","nodeId":531,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>531</color>","_position":{"x":542.803,"y":1020.333},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"11"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"10"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"11"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_position":{"x":233.1071,"y":784.5082},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"0"},{"_action":{"MarkStr":"CityCommonDefend","CheckNotHave":true,"nodeId":529,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>529</color>","_position":{"x":-82.50031,"y":884.0636},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"1"},{"_tag":"","_position":{"x":232.4085,"y":900.0037},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"2"},{"_action":{"Strategy":6,"IsCity":true,"ExtraName":"CommonDefend","nodeId":530,"$type":"NodeCanvas.Tasks.Actions.AIForeachCreate"},"_tag":"<color=red>530</color>","_position":{"x":-170.4937,"y":1009.99},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"nodeId":531,"$type":"NodeCanvas.Tasks.Actions.AIForeachStart"},"_tag":"<color=red>531</color>","_position":{"x":125.8932,"y":1022.25},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_tag":"","_position":{"x":256.9426,"y":1038.827},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"5"},{"_action":{"ActionTypes":[4],"nodeId":532,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>532</color>","_position":{"x":-0.5396254,"y":1226.149},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"nodeId":533,"$type":"NodeCanvas.Tasks.Actions.AIParamDefendTrainUnit"},"_tag":"<color=red>533</color>","_position":{"x":152.9659,"y":1227.126},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"},{"_action":{"CalculateTypes":[7],"nodeId":534,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>534</color>","_position":{"x":295.5356,"y":1225.331},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"},{"_action":{"nodeId":535,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>535</color>","_position":{"x":442.8104,"y":1228.461},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"9"},{"_action":{"nodeId":536,"$type":"NodeCanvas.Tasks.Actions.AIForeachEnd"},"_tag":"<color=red>536</color>","_position":{"x":383.6671,"y":1022.379},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"10"},{"_action":{"MarkStr":"CityCommonDefend","nodeId":537,"$type":"NodeCanvas.Tasks.Actions.MarkAction"},"_tag":"<color=red>537</color>","_position":{"x":542.803,"y":1020.333},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"11"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"10"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"2"},"_targetNode":{"$ref":"11"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"5"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: FlandreHero
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":-744.1326,"y":727.8265},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":-741.9317,"y":849.4288},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":14,"GiantType":1},"nodeId":322,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>322</color>","_position":{"x":-1119.547,"y":1047.07},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"ActionTypes":[11],"nodeId":323,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>323</color>","_position":{"x":-934.703,"y":1046.851},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"nodeId":324,"$type":"NodeCanvas.Tasks.Actions.AIParamIsTargetSelfUnit"},"_tag":"<color=red>324</color>","_position":{"x":-773.0,"y":1047.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"GreaterThan":false,"nodeId":325,"$type":"NodeCanvas.Tasks.Actions.AIParamTargetHealth"},"_tag":"<color=red>325</color>","_position":{"x":-612.0,"y":1046.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"CalculateTypes":[7],"nodeId":326,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>326</color>","_position":{"x":-444.3398,"y":1044.537},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"nodeId":327,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>327</color>","_position":{"x":-308.7517,"y":1043.507},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":-744.1326,"y":727.8265},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":-741.9317,"y":849.4288},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":14,"GiantType":1},"nodeId":325,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>325</color>","_position":{"x":-1119.547,"y":1047.07},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"ActionTypes":[11],"nodeId":326,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>326</color>","_position":{"x":-934.703,"y":1046.851},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"nodeId":327,"$type":"NodeCanvas.Tasks.Actions.AIParamIsTargetSelfUnit"},"_tag":"<color=red>327</color>","_position":{"x":-773.0,"y":1047.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"GreaterThan":false,"nodeId":328,"$type":"NodeCanvas.Tasks.Actions.AIParamTargetHealth"},"_tag":"<color=red>328</color>","_position":{"x":-612.0,"y":1046.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"CalculateTypes":[7],"nodeId":329,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>329</color>","_position":{"x":-444.3398,"y":1044.537},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"nodeId":330,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>330</color>","_position":{"x":-308.7517,"y":1043.507},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: MokouEggHero
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":-1316.633,"y":888.0853},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":-1804.262,"y":1135.337},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":23},"nodeId":248,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>248</color>","_position":{"x":-2165.109,"y":1329.058},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"GreaterThan":false,"Ratio":0.5,"nodeId":249,"$type":"NodeCanvas.Tasks.Actions.AIParamHealth"},"_tag":"<color=red>249</color>","_position":{"x":-1908.029,"y":1329.711},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"ActionTypes":[10],"nodeId":250,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>250</color>","_position":{"x":-1765.153,"y":1331.812},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"CalculateTypes":[40],"nodeId":251,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>251</color>","_position":{"x":-1607.146,"y":1330.971},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"nodeId":252,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>252</color>","_position":{"x":-1389.108,"y":1331.223},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_tag":"","_position":{"x":-834.7693,"y":1141.347},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"7"},{"_action":{"FullType":{"UnitType":23},"nodeId":253,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>253</color>","_position":{"x":-1219.304,"y":1329.9},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"},{"_action":{"Ratio":0.5,"nodeId":254,"$type":"NodeCanvas.Tasks.Actions.AIParamHealth"},"_tag":"<color=red>254</color>","_position":{"x":-980.4407,"y":1331.028},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"9"},{"_action":{"ActionTypes":[10],"nodeId":255,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>255</color>","_position":{"x":-847.6974,"y":1331.028},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"10"},{"_action":{"CalculateTypes":[41],"nodeId":256,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>256</color>","_position":{"x":-686.9867,"y":1330.846},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"11"},{"_action":{"nodeId":257,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>257</color>","_position":{"x":-465.122,"y":1329.055},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"12"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"10"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"11"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"12"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":-1316.633,"y":888.0853},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":-1804.262,"y":1135.337},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":23},"nodeId":251,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>251</color>","_position":{"x":-2165.109,"y":1329.058},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"GreaterThan":false,"Ratio":0.5,"nodeId":252,"$type":"NodeCanvas.Tasks.Actions.AIParamHealth"},"_tag":"<color=red>252</color>","_position":{"x":-1908.029,"y":1329.711},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"ActionTypes":[10],"nodeId":253,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>253</color>","_position":{"x":-1765.153,"y":1331.812},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"CalculateTypes":[40],"nodeId":254,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>254</color>","_position":{"x":-1607.146,"y":1330.971},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"nodeId":255,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>255</color>","_position":{"x":-1389.108,"y":1331.223},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_tag":"","_position":{"x":-834.7693,"y":1141.347},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"7"},{"_action":{"FullType":{"UnitType":23},"nodeId":256,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>256</color>","_position":{"x":-1219.304,"y":1329.9},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"},{"_action":{"Ratio":0.5,"nodeId":257,"$type":"NodeCanvas.Tasks.Actions.AIParamHealth"},"_tag":"<color=red>257</color>","_position":{"x":-980.4407,"y":1331.028},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"9"},{"_action":{"ActionTypes":[10],"nodeId":258,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>258</color>","_position":{"x":-847.6974,"y":1331.028},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"10"},{"_action":{"CalculateTypes":[41],"nodeId":259,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>259</color>","_position":{"x":-686.9867,"y":1330.846},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"11"},{"_action":{"nodeId":260,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>260</color>","_position":{"x":-465.122,"y":1329.055},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"12"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"10"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"11"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"7"},"_targetNode":{"$ref":"12"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: ReisenHeroTree
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":250.251,"y":499.2788},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":252.1619,"y":636.515},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":14,"GiantType":7},"nodeId":297,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>297</color>","_position":{"x":-53.4537,"y":789.1558},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"ActionTypes":[11],"nodeId":298,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>298</color>","_position":{"x":138.391,"y":785.9374},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"CalculateTypes":[31],"nodeId":299,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>299</color>","_position":{"x":321.7538,"y":787.623},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"nodeId":300,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>300</color>","_position":{"x":503.3424,"y":792.5932},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":250.251,"y":499.2788},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":252.1619,"y":636.515},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":14,"GiantType":7},"nodeId":300,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>300</color>","_position":{"x":-53.4537,"y":789.1558},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"ActionTypes":[11],"nodeId":301,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>301</color>","_position":{"x":138.391,"y":785.9374},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"CalculateTypes":[31],"nodeId":302,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>302</color>","_position":{"x":321.7538,"y":787.623},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"nodeId":303,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>303</color>","_position":{"x":503.3424,"y":792.5932},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: RemiliaHero
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":500.0,"y":479.0},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":501.9109,"y":616.2362},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":14,"GiantType":2},"nodeId":301,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>301</color>","_position":{"x":-186.7047,"y":750.877},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"Level":3,"nodeId":302,"$type":"NodeCanvas.Tasks.Actions.AIParamLevel"},"_tag":"<color=red>302</color>","_position":{"x":4.0,"y":752.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"ActionTypes":[8],"nodeId":303,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>303</color>","_position":{"x":140.14,"y":747.6586},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"ActionType":13,"nodeId":304,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitActionType"},"_tag":"<color=red>304</color>","_position":{"x":293.0,"y":750.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"Count":1.0,"nodeId":305,"$type":"NodeCanvas.Tasks.Actions.AIParamAroundSelfLeagueUnitCount"},"_tag":"<color=red>305</color>","_position":{"x":519.0,"y":749.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"GreaterThan":false,"Count":4.0,"SpType":1,"nodeId":306,"$type":"NodeCanvas.Tasks.Actions.AIParamAroundSpTypeGrid"},"_tag":"<color=red>306</color>","_position":{"x":677.0,"y":747.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"},{"_action":{"CalculateTypes":[7],"nodeId":307,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>307</color>","_position":{"x":927.5028,"y":746.3442},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"},{"_action":{"nodeId":308,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>308</color>","_position":{"x":1066.091,"y":748.3144},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"9"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":500.0,"y":479.0},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":501.9109,"y":616.2362},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"FullType":{"UnitType":14,"GiantType":2},"nodeId":304,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>304</color>","_position":{"x":-186.7047,"y":750.877},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"Level":3,"nodeId":305,"$type":"NodeCanvas.Tasks.Actions.AIParamLevel"},"_tag":"<color=red>305</color>","_position":{"x":4.0,"y":752.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"ActionTypes":[8],"nodeId":306,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>306</color>","_position":{"x":140.14,"y":747.6586},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"ActionType":13,"nodeId":307,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitActionType"},"_tag":"<color=red>307</color>","_position":{"x":293.0,"y":750.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"Count":1.0,"nodeId":308,"$type":"NodeCanvas.Tasks.Actions.AIParamAroundSelfLeagueUnitCount"},"_tag":"<color=red>308</color>","_position":{"x":519.0,"y":749.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"GreaterThan":false,"Count":4.0,"SpType":1,"nodeId":309,"$type":"NodeCanvas.Tasks.Actions.AIParamAroundSpTypeGrid"},"_tag":"<color=red>309</color>","_position":{"x":677.0,"y":747.0},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"},{"_action":{"CalculateTypes":[7],"nodeId":310,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>310</color>","_position":{"x":927.5028,"y":746.3442},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"},{"_action":{"nodeId":311,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>311</color>","_position":{"x":1066.091,"y":748.3144},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"9"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"9"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

File diff suppressed because one or more lines are too long

View File

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 7a686a47eee2fa44cb0a34b5d86e4d5e, type: 3}
m_Name: TewiHero
m_EditorClassIdentifier:
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":396.5577,"y":852.6248},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":400.5779,"y":972.1183},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"nodeId":206,"$type":"NodeCanvas.Tasks.Actions.AIParamHeroStrategy"},"_tag":"<color=red>206</color>","_position":{"x":-95.53619,"y":1258.83},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"FullType":{"UnitType":14,"GiantType":8},"nodeId":207,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>207</color>","_position":{"x":60.53963,"y":1258.391},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"ActionTypes":[8],"nodeId":208,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>208</color>","_position":{"x":247.1929,"y":1261.515},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"ActionType":11,"nodeId":209,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitActionType"},"_tag":"<color=red>209</color>","_position":{"x":410.3843,"y":1256.895},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"Count":1.0,"nodeId":210,"$type":"NodeCanvas.Tasks.Actions.AIParamAroundSelfLeagueUnitCount"},"_tag":"<color=red>210</color>","_position":{"x":599.418,"y":1252.771},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"CalculateTypes":[7],"nodeId":211,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>211</color>","_position":{"x":759.9159,"y":1254.685},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"},{"_action":{"nodeId":212,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>212</color>","_position":{"x":893.8396,"y":1253.894},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_serializedGraph: '{"type":"NodeCanvas.BehaviourTrees.BehaviourTree","nodes":[{"_tag":"","_position":{"x":396.5577,"y":852.6248},"$type":"NodeCanvas.BehaviourTrees.Selector","$id":"0"},{"_tag":"","_position":{"x":400.5779,"y":972.1183},"$type":"NodeCanvas.BehaviourTrees.Sequencer","$id":"1"},{"_action":{"nodeId":209,"$type":"NodeCanvas.Tasks.Actions.AIParamHeroStrategy"},"_tag":"<color=red>209</color>","_position":{"x":-95.53619,"y":1258.83},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"2"},{"_action":{"FullType":{"UnitType":14,"GiantType":8},"nodeId":210,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitFullType"},"_tag":"<color=red>210</color>","_position":{"x":60.53963,"y":1258.391},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"3"},{"_action":{"ActionTypes":[8],"nodeId":211,"$type":"NodeCanvas.Tasks.Actions.AIGeneratorAction"},"_tag":"<color=red>211</color>","_position":{"x":247.1929,"y":1261.515},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"4"},{"_action":{"ActionType":11,"nodeId":212,"$type":"NodeCanvas.Tasks.Actions.AIParamUnitActionType"},"_tag":"<color=red>212</color>","_position":{"x":410.3843,"y":1256.895},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"5"},{"_action":{"Count":1.0,"nodeId":213,"$type":"NodeCanvas.Tasks.Actions.AIParamAroundSelfLeagueUnitCount"},"_tag":"<color=red>213</color>","_position":{"x":599.418,"y":1252.771},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"6"},{"_action":{"CalculateTypes":[7],"nodeId":214,"$type":"NodeCanvas.Tasks.Actions.AICalculateAction"},"_tag":"<color=red>214</color>","_position":{"x":759.9159,"y":1254.685},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"7"},{"_action":{"nodeId":215,"$type":"NodeCanvas.Tasks.Actions.AIExecuteAction"},"_tag":"<color=red>215</color>","_position":{"x":893.8396,"y":1253.894},"$type":"NodeCanvas.BehaviourTrees.ActionNode","$id":"8"}],"connections":[{"_sourceNode":{"$ref":"0"},"_targetNode":{"$ref":"1"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"2"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"3"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"4"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"5"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"6"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"7"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"},{"_sourceNode":{"$ref":"1"},"_targetNode":{"$ref":"8"},"$type":"NodeCanvas.BehaviourTrees.BTConnection"}],"canvasGroups":[],"localBlackboard":{"_variables":{}},"derivedData":{"repeat":true,"$type":"NodeCanvas.BehaviourTrees.BehaviourTree+DerivedSerializationData"}}'
_objectReferences: []
_graphSource:
_version: 3.33

File diff suppressed because one or more lines are too long

View File

@ -1562,9 +1562,10 @@ namespace RuntimeData
}
}
public static List<string> FindDifferences<T>(T obj1, T obj2, string path = "")
public static List<string> FindDifferences<T>(T obj1, T obj2, string path = "", HashSet<object> visited = null)
{
var differences = new List<string>();
visited ??= new HashSet<object>();
if (obj1 == null && obj2 == null) return differences;
if (obj1 == null || obj2 == null)
@ -1573,7 +1574,21 @@ namespace RuntimeData
return differences;
}
var type = typeof(T);
// 防止循环引用
if (visited.Contains(obj1)) return differences;
visited.Add(obj1);
// 使用运行时类型
var type1 = obj1.GetType();
var type2 = obj2.GetType();
if (type1 != type2)
{
differences.Add($"{path}: type mismatch ({type1.Name} vs {type2.Name})");
return differences;
}
var type = type1;
// 处理基础类型
if (type.IsPrimitive || type == typeof(string) || type == typeof(decimal) || type.IsEnum)
@ -1597,7 +1612,7 @@ namespace RuntimeData
var minCount = Math.Min(list1.Count, list2.Count);
for (int i = 0; i < minCount; i++)
{
var itemDiffs = FindDifferences(list1[i], list2[i], $"{path}[{i}]");
var itemDiffs = FindDifferences(list1[i], list2[i], $"{path}[{i}]", new HashSet<object>(visited));
differences.AddRange(itemDiffs);
}
@ -1605,10 +1620,8 @@ namespace RuntimeData
}
// 处理字典类型
var isDictionary = type.GetInterfaces()
.Any(i => i.IsGenericType && i.GetGenericTypeDefinition() == typeof(IDictionary<,>));
if (isDictionary)
if (type.GetInterfaces()
.Any(i => i.IsGenericType && i.GetGenericTypeDefinition() == typeof(IDictionary<,>)))
{
var keysProperty = type.GetProperty("Keys");
var itemProperty = type.GetProperty("Item");
@ -1618,8 +1631,8 @@ namespace RuntimeData
var keys1 = (IEnumerable)keysProperty.GetValue(obj1);
var keys2 = (IEnumerable)keysProperty.GetValue(obj2);
var keysList1 = keys1.Cast<object>().ToList();
var keysList2 = keys2.Cast<object>().ToList();
var keysList1 = keys1.Cast<object>().ToHashSet();
var keysList2 = keys2.Cast<object>().ToHashSet();
var allKeys = keysList1.Union(keysList2);
foreach (var key in allKeys)
@ -1636,7 +1649,7 @@ namespace RuntimeData
var value1 = itemProperty.GetValue(obj1, new[] { key });
var value2 = itemProperty.GetValue(obj2, new[] { key });
var itemDiffs = FindDifferences(value1, value2, $"{path}[{key}]");
var itemDiffs = FindDifferences(value1, value2, $"{path}[{key}]", new HashSet<object>(visited));
differences.AddRange(itemDiffs);
}
}
@ -1656,7 +1669,7 @@ namespace RuntimeData
var value2 = prop.GetValue(obj2);
var propPath = string.IsNullOrEmpty(path) ? prop.Name : $"{path}.{prop.Name}";
var propDiffs = FindDifferences(value1, value2, propPath);
var propDiffs = FindDifferences(value1, value2, propPath, new HashSet<object>(visited));
differences.AddRange(propDiffs);
}
catch (Exception ex)
@ -1676,7 +1689,7 @@ namespace RuntimeData
var value2 = field.GetValue(obj2);
var fieldPath = string.IsNullOrEmpty(path) ? field.Name : $"{path}.{field.Name}";
var fieldDiffs = FindDifferences(value1, value2, fieldPath);
var fieldDiffs = FindDifferences(value1, value2, fieldPath, new HashSet<object>(visited));
differences.AddRange(fieldDiffs);
}
catch (Exception ex)
@ -1688,7 +1701,7 @@ namespace RuntimeData
return differences;
}
// 检查成员是否会被 MemoryPack 序列化
// 更完整的 MemoryPack 序列化检测
private static bool IsMemoryPackSerializable(System.Reflection.MemberInfo member)
{
// 检查是否有 MemoryPackIgnore 特性
@ -1710,7 +1723,7 @@ namespace RuntimeData
// 对于字段:必须是 public 且非 readonly
if (member is System.Reflection.FieldInfo field)
{
return field.IsPublic && !field.IsInitOnly;
return field.IsPublic && !field.IsInitOnly && !field.IsLiteral;
}
return false;

View File

@ -23,13 +23,24 @@ namespace RuntimeData
Single,
Multi,
}
public enum MemberNetState
{
None,
OK,
Leaved,
Disconnected,
Timeout,
Error,
}
public class PlayerConfirmData
{
public ulong MemberId;
public float ConfirmTime;
public float GameConfirmTime;
public bool NeedForceUpdate;
public MemberNetState State = MemberNetState.None;
public PlayerConfirmData(ulong id)
@ -37,7 +48,7 @@ namespace RuntimeData
MemberId = id;
ConfirmTime = Time.time;
GameConfirmTime = Time.time;
NeedForceUpdate = false;
State = MemberNetState.OK;
}
}
@ -168,6 +179,12 @@ namespace RuntimeData
return 0;
}
public PlayerConfirmData GetPlayerConfirmData(uint playerId)
{
var memberId = GetmemberIdId(playerId);
return PlayerConfirm.GetValueOrDefault(memberId);
}
public void CompareEqual(NetData net)
{
var differences = new List<string>();

View File

@ -1376,7 +1376,7 @@ namespace RuntimeData
if (unitLevel + 1 > MaxHeroCount)
MaxHeroCount = Mathf.Min(3, (int)unitLevel + 1);
}
//获取英雄的升级费用值
public int GetHeroFinishTaskCost(GiantType giant)
{

View File

@ -2029,7 +2029,7 @@ namespace Logic.AI
}
// 行为数据转发
// 行为数据本地
[MemoryPackable]
public partial class ActionNetData
{

View File

@ -115,7 +115,8 @@ namespace Logic.AI
{
if (AILogicState == AILogicState.Finished || AILogicState == AILogicState.Prepare) return;
if (AILogicState == AILogicState.Pausing && !PresentationManager.Busy)
//if (AILogicState == AILogicState.Pausing && !PresentationManager.Busy)
if (AILogicState == AILogicState.Pausing)
{
_targetTime -= Time.deltaTime;
if (_targetTime <= 0) AILogicState = AILogicState.Playing;
@ -151,7 +152,7 @@ namespace Logic.AI
{
_data.MaxAiAction.ActionLogic.CompleteExecute(_data.MaxAiAction.Param);
_data.MaxAiAction.CheckIsActionDuration();
_targetTime = _data.MaxAiAction.Duration;
_targetTime = Mathf.Max(_data.MaxAiAction.Duration, 1f);
#if UNITY_EDITOR
var records = GetCurrentAIRecords();

View File

@ -975,7 +975,7 @@ namespace Logic.Action
// 实际的执行逻辑
protected abstract bool Execute(CommonActionParams actionParams);
// 执行逻辑
// 执行逻辑
protected virtual void BeforeExecute(CommonActionParams actionParams)
{
// 必须在 action 执行之前记录

View File

@ -489,8 +489,7 @@ namespace TH1_Logic.Action
var can = heroD.ForceFinishHeroTask(_actionId.GiantType);
if (can)
{
//如果是玩家,拿钱扣款
if (actionParams.PlayerData == actionParams.MapData.PlayerMap.SelfPlayerData)
if (actionParams.MapData.CheckIsPlayer(actionParams.PlayerData.Id))
{
actionParams.MapData.PlayerMap.SelfPlayerData.PlayerWealth -= cost;
}

View File

@ -35,6 +35,7 @@ namespace Logic
private Main _main;
private AILogic _aiLogic;
private Dictionary<GameState, GameStateBase> _gameStateDict;
private float _reconnectTime;
private float _confirmTime;
private float _heartbeatTime;
private float _forceUpdateTime;
@ -58,7 +59,9 @@ namespace Logic
public void Update()
{
UpdateReconnect();
SendHeartbeat();
UpdateConnectState();
_gameStateDict[_curState].Update();
if (Main.MapData == null) return;
@ -79,7 +82,7 @@ namespace Logic
else ChangeState(GameState.OtherPlayerRound);
UpdateAI();
UpdateConfirm();
UpdateForceUpdate();
RefreshReconnect();
}
public void ChangeState(GameState newState)
@ -101,13 +104,16 @@ namespace Logic
if (Main.MapData.CurPlayer == null) return;
foreach (var kv in Main.MapData.Net.Players)
{
continue;
if (Main.MapData.Net.CurPlayerId != kv.Value) continue;
if (!LobbyManager.Instance.Lobby.IsMemberInLobby(kv.Key)) continue;
if (Main.MapData.Net.PlayerConfirm.ContainsKey(kv.Key) &&
Main.MapData.Net.PlayerConfirm[kv.Key].State != MemberNetState.OK) continue;
return;
}
#if !GAME_AUTO_DEBUG
if (Main.MapData.CurPlayer == Main.MapData.PlayerMap.SelfPlayerData) return;
//if (Main.MapData.CurPlayer == Main.MapData.PlayerMap.SelfPlayerData) return;
#endif
if (_aiLogic.PlayerData == null || _aiLogic.PlayerData != Main.MapData.CurPlayer)
@ -127,16 +133,17 @@ namespace Logic
}
}
}
// 游戏校验
private void UpdateConfirm()
// 重连校验
private void UpdateReconnect()
{
if (Main.MapData.Net.Mode != NetMode.Multi || LobbyManager.Instance.Lobby.IsLobbyOwner()) return;
_confirmTime += Time.deltaTime;
if (_confirmTime < 5f) return;
_confirmTime = 0;
GameNetSender.Instance.MapConfirm();
}
if (!LobbyManager.Instance.Lobby.IsInLobby()) return;
if (LobbyManager.Instance.Lobby.IsLobbyOwner()) return;
_reconnectTime += Time.deltaTime;
if (_reconnectTime < 2f) return;
_reconnectTime = 0;
LobbyManager.Instance.Lobby.CheckConnectionStatus();
}
// 心跳校验
private void SendHeartbeat()
@ -149,25 +156,66 @@ namespace Logic
GameNetSender.Instance.SendHeartbeat();
}
// 检查强制更新
private void UpdateForceUpdate()
// 游戏校验
private void UpdateConfirm()
{
if (Main.MapData.Net.Mode != NetMode.Multi || LobbyManager.Instance.Lobby.IsLobbyOwner()) return;
_confirmTime += Time.deltaTime;
if (_confirmTime < 5f) return;
_confirmTime = 0;
GameNetSender.Instance.MapConfirm();
}
// 检查连接状态
private void UpdateConnectState()
{
if (Main.MapData?.Net == null) return;
if (!LobbyManager.Instance.Lobby.IsLobbyOwner()) return;
_reconnectTime += Time.deltaTime;
if (_reconnectTime < 2f) return;
_reconnectTime = 0;
foreach (var kv in Main.MapData.Net.PlayerConfirm)
{
if (kv.Key == LobbyManager.Instance.Lobby.GetSelfMemberId()) continue;
if (!LobbyManager.Instance.Lobby.IsMemberInLobby(kv.Key))
{
kv.Value.State = MemberNetState.Leaved;
continue;
}
// 10s 无校验为超时 AI 接管
if (Time.time - kv.Value.ConfirmTime >= 10f)
{
kv.Value.State = MemberNetState.Timeout;
continue;
}
// 有校验无游戏内校验差值为 10s 判定重连
else if (kv.Value.ConfirmTime - kv.Value.GameConfirmTime >= 10f)
{
kv.Value.State = MemberNetState.Disconnected;
continue;
}
kv.Value.State = MemberNetState.OK;
}
}
// 发起重连
private void RefreshReconnect()
{
if (Main.MapData.Net.Mode != NetMode.Multi || !LobbyManager.Instance.Lobby.IsLobbyOwner()) return;
_forceUpdateTime += Time.deltaTime;
if (_forceUpdateTime < 3f) return;
if (_forceUpdateTime < 10f) return;
_forceUpdateTime = 0;
foreach (var kv in Main.MapData.Net.PlayerConfirm)
{
if (!LobbyManager.Instance.Lobby.IsMemberInLobby(kv.Key)) continue;
if (Time.time - kv.Value.ConfirmTime >= 20f)
if (kv.Key == LobbyManager.Instance.Lobby.GetSelfMemberId()) continue;
if (kv.Value.State == MemberNetState.Error || kv.Value.State == MemberNetState.Disconnected)
{
LobbyManager.Instance.Lobby.KickMember(kv.Key);
continue;
GameNetSender.Instance.ForceUpdate(kv.Key);
}
if (Time.time - kv.Value.GameConfirmTime < 10f && !kv.Value.NeedForceUpdate) continue;
GameNetSender.Instance.ForceUpdate(kv.Key);
kv.Value.NeedForceUpdate = false;
}
}
}

View File

@ -170,6 +170,11 @@ namespace TH1_Logic.HeroTask
{
}
public virtual void OnMeetOtherPlayers(MapData mapData, PlayerData self)
{
}
}
@ -458,12 +463,11 @@ namespace TH1_Logic.HeroTask
return newContent;
}
public override bool CheckFinished(MapData map, PlayerData self)
public override void OnMeetOtherPlayers(MapData mapData, PlayerData self)
{
var max = Mathf.CeilToInt(map.PlayerMap.PlayerDataList.Count / 3f);
var max = Mathf.CeilToInt(mapData.PlayerMap.PlayerDataList.Count / 3f);
if (TargetLevel > max) TargetLevel = (uint)max;
Level = (uint)Mathf.Max(0, self.MeetPlayers.Count - 1);
return base.CheckFinished(map, self);
}
}

View File

@ -76,14 +76,15 @@ namespace TH1_Logic.Net
// 获取自己在不在房间中
public bool IsInLobby();
// 检查和房主的连接状态, 断开需要重连
public void CheckConnectionStatus();
// 发送P2P消息
public bool SendMessageToPeer(ulong member, byte[] data, bool reliable = true);
// 广播P2P消息
public void BroadcastMessage(byte[] data, bool reliable = true);
}
@ -195,6 +196,11 @@ namespace TH1_Logic.Net
return false;
}
public void CheckConnectionStatus()
{
}
public bool SendMessageToPeer(ulong member, byte[] data, bool reliable = true)
{
return false;

View File

@ -850,6 +850,7 @@ namespace Logic
if (p1.MeetPlayers.Contains(p2.Id)) return;
//step #1 meetlist增加
p1.MeetPlayers.Add(p2.Id);
foreach (var kv in p1.PlayerHeroData.HeroTaskDict) kv.Value.OnMeetOtherPlayers(map, p1);
//step #2 加钱
var coin = GetFirstMeetCoin(map,p2);
p1.PlayerWealth += coin;

View File

@ -124,11 +124,11 @@ namespace TH1_Logic.Steam
if (NetData.GetMapDataHash(Main.MapData) != message.ActionData.MapHash)
{
LogSystem.LogError($"OnReceivedActionExecute maphash 不一致");
// TODO 这里来校验不同之处
if (message.Map != null)
{
Main.MapData.CompareEqual(message.Map);
MapData.FindDifferences(Main.MapData, message.Map);
}
// MapData.CompareWithDetails(Main.MapData, message.Map);
}
@ -156,7 +156,7 @@ namespace TH1_Logic.Steam
Main.PlayerLogic.EndPlayerTurn(Main.MapData, message.PlayerId);
}
// 只有房主会收到 心跳校验
// 只有房主会收到心跳校验
private void OnReceivedMapConfirm(MapConfirmMessage message)
{
if (message == null)
@ -169,30 +169,24 @@ namespace TH1_Logic.Steam
if (!LobbyManager.Instance.Lobby.IsLobbyOwner()) return;
if (Main.MapData.Net.Actions.Count == 0 || message.Index == 0) return;
if (!Main.MapData.Net.PlayerConfirm.TryGetValue(message.MemberId, out var value)) return;
value.NeedForceUpdate = false;
value.GameConfirmTime = Time.time;
if (message.Index > Main.MapData.Net.Actions.Count)
{
LogSystem.LogError($"action index error message.Index : {message.Index}, Main.MapData.Net.Actions.Count : {Main.MapData.Net.Actions.Count}");
value.NeedForceUpdate = true;
value.State = MemberNetState.Error;
return;
}
if (!Main.MapData.Net.Actions[message.Index - 1].IsEqual(message.ActionData))
else if (!Main.MapData.Net.Actions[message.Index - 1].IsEqual(message.ActionData))
{
LogSystem.LogError($"self action hash : {Main.MapData.Net.Actions[message.Index - 1].MapHash}, message map hash : {message.ActionData.MapHash}");
value.NeedForceUpdate = true;
value.State = MemberNetState.Error;
}
else
{
value.State = MemberNetState.OK;
LogSystem.LogInfo($"self action hash : {Main.MapData.Net.Actions[message.Index - 1].MapHash}, message map hash : {message.ActionData.MapHash}");
}
if (Main.MapData.Net.Actions.Count - message.Index > 5)
{
LogSystem.LogError($"Main.MapData.Net.Actions.Count - message.Index > 5");
value.NeedForceUpdate = true;
}
}
// 只有玩家会收到
@ -216,6 +210,7 @@ namespace TH1_Logic.Steam
// Main.MapData = message.MapData;
Main.MapData.CompareEqual(message.MapData);
MapData.FindDifferences(Main.MapData, message.MapData);
// Main.Instance.NetContinueGame(message.MapData);
for (int i = 0; i < Main.MapData.Net.Actions.Count; i++)
{

View File

@ -12,6 +12,7 @@ using Logic.CrashSight;
using RuntimeData;
using TH1_Logic.Core;
using TH1_Logic.Net;
using UnityEngine;
namespace TH1_Logic.Steam
@ -19,6 +20,7 @@ namespace TH1_Logic.Steam
public class GameNetSender
{
public static GameNetSender Instance { get; } = new GameNetSender();
private static float RecordTime;
// 发送消息给房主
public void SendMessage(BaseMessage message)
@ -91,7 +93,13 @@ namespace TH1_Logic.Steam
var data = new ActionExcuteMessage();
data.ActionData = actionData;
// data.Map = Main.MapData;
// TODO 这里是测试,每帧最多只发送一次
if (RecordTime < Time.time)
{
data.Map = Main.MapData;
RecordTime = Time.time;
}
BroadcastMessage(data);
}

View File

@ -47,6 +47,7 @@ namespace TH1_Logic.Steam
private Dictionary<ulong, MemberInfo> _memberInfos;
private Dictionary<ulong, CSteamID> _membersCache;
private float _onlineFriendsIdUpdateRecord;
private float _kickInfoUpdateRecord;
// 事件委托
public event System.Action<CSteamID> OnLobbyCreatedEvent; // 房间创建成功
@ -60,7 +61,7 @@ namespace TH1_Logic.Steam
// LobbyCreated_t
// 谁会收到:只有调用 CreateLobby 的本机(创建者)。
// 何时触发:SteamMatchmaking.CreateLobby 异步完成后。
// 何时触发:_kickInfoUpdateRecord.CreateLobby 异步完成后。
// 成功判定data.m_eResult == k_EResultOK。失败则不会进入房间也不会再收到 LobbyEnter_t。
// 用途:确认为房主,保存 LobbyID设置 LobbyData / Rich Presence然后等别人加入。
private Callback<LobbyCreated_t> _cbLobbyCreated;
@ -86,6 +87,7 @@ namespace TH1_Logic.Steam
{
_steamSDKUpdateRecord = 2;
_onlineFriendsIdUpdateRecord = 2;
_kickInfoUpdateRecord = 2;
_onlineFriendsId = new Dictionary<ulong, CSteamID>();
_onlineFriendsInfo = new Dictionary<ulong, MemberInfo>();
_memberInfos = new Dictionary<ulong, MemberInfo>();
@ -229,6 +231,17 @@ namespace TH1_Logic.Steam
}
}
}
// 定时刷新踢人信息
private void RefreshKickInfo()
{
_kickInfoUpdateRecord += Time.deltaTime;
if (_kickInfoUpdateRecord > 2)
{
_kickInfoUpdateRecord = 0;
CheckIfKicked();
}
}
// 定时更新
public void Update()
@ -243,6 +256,7 @@ namespace TH1_Logic.Steam
SimpleP2P.Instance.PollMessages();
RefreshOnlineFriends();
RefreshKickInfo();
}
// 检查 steam_appid.txt 文件
@ -604,14 +618,21 @@ namespace TH1_Logic.Steam
// 房间准备完毕时内部处理
private void OnLobbyReadyInternal()
{
CheckConnectionStatus();
}
// 检查连接状态
public void CheckConnectionStatus()
{
// 如果不是房主,连接到房主
if (!IsLobbyOwner() && CachedOwner.IsValid())
if (!IsLobbyOwner() && CachedOwner.IsValid() && !SimpleP2P.Instance.IsConnectedTo(CachedOwner))
{
LogSystem.LogInfo($"Reconnecting to host: {CachedOwner}");
SimpleP2P.Instance.ConnectToPeer(CachedOwner);
}
}
// 有成员变化时内部处理
private void OnLobbyMembersChangedInternal()
{