Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function arenatest(twos, threes, fives)
- arena = 1
- while (arena <= 3) do
- teamName, teamSize, teamRating, teamPlayed, teamWins, seasonTeamPlayed, seasonTeamWins, playerPlayed, seasonPlayerPlayed, teamRank, playerRating = GetArenaTeam(arena)
- print(teamName, teamSize, arena)
- if (teamSize == 2) then
- rating = teamRating - playerRating
- if (teamRating > 1500) and (rating < 150) then
- fivespoints = math.floor(1511.26/(1+1639.28*math.pow(2.71828, -0.00412*teamRating)))
- total = math.ceil(fivespoints*0.76)
- twos = teamRating
- table.insert(arenapoints, total)
- elseif (teamRating > 1500) and (rating > 150) then
- fivespoints = math.floor(0.22*playerRating+14)
- total = math.floor(fivespoints*0.76)
- twos = playerRating
- table.insert(arenapoints, total)
- elseif (teamRating < 1500) then
- fivespoints = math.floor(0.22*teamRating+14)
- total = math.ceil(fivespoints*0.76)
- twos = teamRating
- table.insert(arenapoints, total)
- end
- arena = arena + arena
- end
- if (teamSize == 3) then
- rating = teamRating - playerRating
- if (teamRating > 1500) and (rating < 150) then
- fivespoints = math.floor(1511.26/(1+1639.28*math.pow(2.71828, -0.00412*teamRating)))
- total = math.ceil(fivespoints*0.88)
- threes = teamRating
- table.insert(arenapoints, total)
- elseif (teamRating > 1500) and (rating > 150) then
- fivespoints = math.floor(0.22*playerRating+14)
- total = math.floor(fivespoints*0.88)
- threes = playerRating
- table.insert(arenapoints, total)
- elseif (teamRating < 1500) then
- fivespoints = math.floor(0.22*teamRating+14)
- total = math.ceil(fivespoints*0.88)
- threes = teamRating
- table.insert(arenapoints, total)
- end
- arena = arena + arena
- end
- if (teamSize == 5) then
- rating = teamRating - playerRating
- if (teamRating > 1500) and (rating < 150) then
- total = math.floor(1511.26/(1+1639.28*math.pow(2.71828, -0.00412*teamRating)))
- fives = teamRating
- print(fives.. " > 1500")
- table.insert(arenapoints, total)
- elseif (teamRating > 1500) and (rating > 150) then
- total = math.floor(0.22*playerRating+14)
- fives = playerRating
- print(fives.. " < 1500")
- table.insert(arenapoints, total)
- elseif (teamRating < 1500) then
- total = math.floor(0.22*teamRating+14)
- fives = teamRating
- print(fives)
- table.insert(arenapoints, total)
- end
- arena = arena + arena
- end
- if (teamSize == 0) then
- arena = arena + arena
- end
- end
- Totalpoints(twos, threes, fives)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement