Breaking up the Pathfinding algorythm that I would send to the drone!!! Going good so far need to scrape last dataset
This commit is contained in:
@@ -157,23 +157,44 @@ func FoundGoal():
|
|||||||
#Mark(Prev_dir)
|
#Mark(Prev_dir)
|
||||||
#TrackIntersections()
|
#TrackIntersections()
|
||||||
#BackToStart()
|
#BackToStart()
|
||||||
|
var LastStep = []
|
||||||
|
var IndividualStepsCopy = []
|
||||||
|
LastStep = Ordered_Commands_Backward.duplicate(true)
|
||||||
|
LastStep.reverse()
|
||||||
|
LastStep.push_front(Prev_dir_Opp)
|
||||||
|
IndividualStepsCopy = Individual_Steps.duplicate(true)
|
||||||
|
IndividualStepsCopy.push_front(LastStep)
|
||||||
TargetsArray.push_back(Current_Position)
|
TargetsArray.push_back(Current_Position)
|
||||||
AllSetsToGoal.push_back(Individual_Steps)
|
|
||||||
|
AllSetsToGoal.push_back(IndividualStepsCopy)
|
||||||
print(BackTrack_Array)
|
print(BackTrack_Array)
|
||||||
AllSetsToGoal.push_back(" BUFFER ")
|
|
||||||
var TargetCopy = TargetsArray.duplicate(true)
|
var TargetCopy = TargetsArray.duplicate(true)
|
||||||
var SetsCopy = AllSetsToGoal.duplicate(true)
|
var SetsCopy = AllSetsToGoal.duplicate(true)
|
||||||
TargetsArray = TargetCopy
|
TargetsArray = TargetCopy
|
||||||
AllSetsToGoal = SetsCopy
|
AllSetsToGoal = SetsCopy
|
||||||
|
|
||||||
print("Here is the Set to go to young bull: ",AllSetsToGoal)
|
print("Here is the Set to go to young bull: ")
|
||||||
|
|
||||||
Done = move
|
Done = move
|
||||||
|
|
||||||
func AllObjectsFound():
|
func AllObjectsFound():
|
||||||
if Tree_Array_SetStart != Tree_Array[0]:
|
if Tree_Array_SetStart != Tree_Array[0]:
|
||||||
if Move_Check1 != move:
|
if Move_Check1 != move:
|
||||||
print("We Done!!!!!!!!!!!!!!!!!")
|
print("We Done!!!!!!!!!!!!!!!!!")
|
||||||
print("This is all the sets to goal gango", AllSetsToGoal)
|
print()
|
||||||
|
#for n in AllSetsToGoal.size():
|
||||||
|
# print(n ," set is equal to : ", AllSetsToGoal[n] )
|
||||||
|
# print()
|
||||||
|
|
||||||
|
for n in AllSetsToGoal.size():
|
||||||
|
var PrimaryPlaceHolder = AllSetsToGoal[n]
|
||||||
|
if n + 1 < AllSetsToGoal.size():
|
||||||
|
var SearchPlaceHolder = AllSetsToGoal[n + 1]
|
||||||
|
print("Search Placeholder ",n, " is : ", SearchPlaceHolder )
|
||||||
|
for i in SearchPlaceHolder:
|
||||||
|
print("The Broken up pieces is: ",i)
|
||||||
|
|
||||||
|
|
||||||
Move_Check1 = move
|
Move_Check1 = move
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user