diff --git a/Just_A_Training_Map.miz b/Just_A_Training_Map.miz index e2f3681..f3138fe 100644 Binary files a/Just_A_Training_Map.miz and b/Just_A_Training_Map.miz differ diff --git a/Scripts/Range.lua b/Scripts/Range.lua index cdf643f..4deb294 100644 --- a/Scripts/Range.lua +++ b/Scripts/Range.lua @@ -124,6 +124,9 @@ do self.removePlayerProfile(playerName) end end + if not playerUnit then + self.removePlayerProfile(playerName) + end if data.activeTarget then if data.activeTarget:isExist() then @@ -350,7 +353,7 @@ do self.playerList[playerName] = nil - local leaveText = Localizations:translate('You have left rang area.','cn') + -- local leaveText = Localizations:translate('You have left rang area.','cn') -- if self.playerList[playerName].group:isExist() then -- trigger.action.outTextForGroup(self.playerList[playerName].groupID,leaveText,10) @@ -469,6 +472,8 @@ do for k=2,#groupData.units,1 do local tDir = math.random(0,359) local spawnPoint = {} + spawnPoint.x = centerPoint.x+200 + spawnPoint.y = centerPoint.z or centerPoint.y for i=1,100,1 do local tPoint = Utils.vecTranslate(centerPoint,tDir,math.random(100,1000)) --Spawn range @@ -480,12 +485,6 @@ do end end - if not spawnPoint then - spawnPoint.x = centerPoint.x+50 - spawnPoint.y = centerPoint.z or centerPoint.y - spawnPoint.y = spawnPoint.y+50 - end - groupData.units[k].x = spawnPoint.x groupData.units[k].y = spawnPoint.z or spawnPoint.y end