equation

0

Please login or register to vote for this query.

(click on this box to dismiss)

Anime and Manga

Q&A for anime and manga fans

DECLARE @troopstrength INT = 180000
DECLARE @troopbonushealth REAL = 332
DECLARE @troopbonusstrength REAL = 344
DECLARE @troopbonusstrength2 REAL = 0
DECLARE @troopnumber INT = 6

/*
--level 18 barb

DECLARE @enemy1strength real = 360 * 1.45
DECLARE @enemy1number INT   =  4600
DECLARE @enemy2strength real = 28 -- archers has bonus vs my troops
DECLARE @enemy2number INT   =  26000
*/

--level 18 elf
DECLARE @enemy1strength INT = 900
DECLARE @enemy1number INT   = 1500 * 1.25
DECLARE @enemy2strength INT = 28
DECLARE @enemy2number INT   = 20000

/*
--level 17 inferno
DECLARE @enemy1strength INT = 4100
DECLARE @enemy1number INT   = 260
DECLARE @enemy2strength INT = 720
DECLARE @enemy2number INT   = 640
*/

/*
--level 17 special
DECLARE @enemy1strength real = 400
DECLARE @enemy1number INT   = 3012
DECLARE @enemy2strength real = 400
DECLARE @enemy2number INT   = 1291
*/
/*
--level 17 undead

DECLARE @enemy1strength real = 360
DECLARE @enemy1number INT   = 4200
DECLARE @enemy2strength real = 270 -- archers has bonus vs my troops
DECLARE @enemy2number INT   = 2400
*/
/*
--level 17 undead

DECLARE @enemy1strength real = 1100
DECLARE @enemy1number INT   = 1100
DECLARE @enemy2strength real = 720 * 1.50 -- archers has bonus vs my troops
DECLARE @enemy2number INT   = 710
*/
/*
--level 17 barb

DECLARE @enemy1strength real = 360*1.45
DECLARE @enemy1number INT   =  2700
DECLARE @enemy2strength real = 150 -- archers has bonus vs my troops
DECLARE @enemy2number INT   =  2700
*/
SELECT
  case when @enemy1strength * @enemy1number + @enemy2strength * @enemy2number < (@troopbonushealth + 100)/100*@troopstrength*3 then 'SAFE' ELSE 'KILL' END status,
  case when @troopstrength * (@troopbonusstrength + @troopbonusstrength2 + 100)/100*@troopnumber <@enemy1strength * @enemy1number * 3 then 'not killing monster1' else 'ok' end,
  case when @troopstrength * (@troopbonusstrength + 100)/100*@troopnumber < @enemy2strength * @enemy2number * 3 then 'not killing monster2' else 'ok' end,
  mydamage1   = @troopstrength * (@troopbonusstrength + @troopbonusstrength2 + 100)/100*@troopnumber,
  mydamage2   = @troopstrength * (@troopbonusstrength + 100)/100*@troopnumber,
  monster1health = @enemy1strength * @enemy1number * 3 ,
  monster2health = @enemy2strength * @enemy2number * 3 ,
  monster1damage = @enemy1strength * @enemy1number,
  monster2damage = @enemy2strength * @enemy2number,
  totaldamage = @enemy1strength * @enemy1number + @enemy2strength * @enemy2number,
  myhealth   = (@troopbonushealth + 100)/100*@troopstrength*3

Enter Parameters

Options:
Switch to meta site
loading Hold tight while we fetch your results