Fixed issue where spawn packets were sent on zone out. Added all npcs to Camp Bearded Rock. Rewrote how mapobjs get loaded in, no more hardcodes. Added tons mapobjs to the DB. Added ferry npcs.

This commit is contained in:
Filip Maj 2017-06-14 22:24:09 -04:00
parent 52cacb1ded
commit d96d5b29a5
63 changed files with 883 additions and 284 deletions

View file

@ -15,4 +15,15 @@ end
function getAngleFacing(x, y, targetX, targetY)
angle = math.atan2(targetX - x, targetY - y);
return angle;
end
function getDistanceBetweenActors(actor1, actor2)
local pos1 = actor1:GetPos();
local pos2 = actor2:GetPos();
local dx = pos1[0] - pos2[0];
local dy = pos1[1] - pos2[1]
local dz = pos1[2] - pos2[2]
return math.sqrt(dx * dx + dy * dy + dz *dz);
end