hi, I wanted to update an old system of mine. But I don't get what you mean in the review.
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Current order of t_unit) Equal to (Order(<Empty String>))
Then - Actions
Set t_loc_2 = (t_loc_3 offset by (Random real number between 1.00 and AI_move[AI_mode]) towards (Random real number between 1.00 and 360.00) degrees)
Custom script: call SaveLocationHandle(udg_AI_hash, h, 1, udg_t_loc_2)
Unit - Order t_unit to Move To t_loc_2
"You leak in AI loop, if the order is null. Don't overwrite hashtable data"
the only leak I can think of is this
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Current order of t_unit) Equal to (Order(<Empty String>))
Then - Actions
Set t_loc_2 = (t_loc_3 offset by (Random real number between 1.00 and AI_move[AI_mode]) towards (Random real number between 1.00 and 360.00) degrees)
Custom script: call RemoveLocation(LoadLocationHandle(udg_AI_hash, h, 1))
Custom script: call SaveLocationHandle(udg_AI_hash, h, 1, udg_t_loc_2)
Unit - Order t_unit to Move To t_loc_2
Else - Actions