CTK calculator

Discussion of all aspects of the game engine, including development of new and existing features.

Moderator: Forum Moderators

Post Reply
User avatar
ERROR1025
Posts: 46
Joined: February 23rd, 2020, 10:18 am

CTK calculator

Post by ERROR1025 »

I'm makeing a CTK calculator
the calculator work:
input:can attack units
input:can attack units damage and attacks
input:defencer's hp,defence
input:can attack defencer hexs
output:attacker High CTK for defencer
code in attachment

I'm stuck while writing calculation code,need help.
Attachments
UnitsHighCTKv0.1.cpp
(1.14 KiB) Downloaded 77 times
User avatar
Pentarctagon
Project Manager
Posts: 5564
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: CTK calculator

Post by Pentarctagon »

What exactly do you need help with?
99 little bugs in the code, 99 little bugs
take one down, patch it around
-2,147,483,648 little bugs in the code
User avatar
ERROR1025
Posts: 46
Joined: February 23rd, 2020, 10:18 am

Re: CTK calculator

Post by ERROR1025 »

Pentarctagon wrote: March 31st, 2023, 5:45 pm What exactly do you need help with?
calculation code,i don't know how calculation data
User avatar
Pentarctagon
Project Manager
Posts: 5564
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: CTK calculator

Post by Pentarctagon »

That'd just be calculating the chance of each possible outcome and then the CTK is the sum of the outcomes that result in the unit have 0 or less hp.
99 little bugs in the code, 99 little bugs
take one down, patch it around
-2,147,483,648 little bugs in the code
Post Reply