feature/ai-but-cooler #35

Merged
PeaAshMeter merged 9 commits from feature/ai-but-cooler into main 2026-04-17 00:31:11 +03:00
Showing only changes of commit a16b279e44 - Show all commits

View File

@ -75,7 +75,7 @@ local function circleVectors(center, radius)
end
for _, v in pairs(vecs) do
local i = 1
while i <= #res and (res[i].x ~= v.x or res[i].y ~= v.y) do
while i <= #res and (res[i].x ~= v.x or res[i].y ~= v.y) and v.x >= 0 and v.y >= 0 do
i = i + 1
end
if i == #res + 1 or #res == 0 then
@ -112,7 +112,7 @@ local aiNature = {
["dev_warrior"] = function(self)
return function(callback) -- почему так, описано в Task
self.owner:try(Tree.behaviors.spellcaster, function(spellB)
self.target = pathToClosestCharacter(self.owner, 1)
self.target = pathToClosestCharacter(self.owner, 2)
local task1 = spellB.spellbook[1]:cast(self.owner, self.target)
if task1 then
task1(