Warsong combat algorithms

  • Topic Archived
You're browsing the GameFAQs Message Boards as a guest. Sign Up for free (or Log In if you already have an account) to be able to post messages, change how messages are displayed, and view media in posts.
  1. Boards
  2. Warsong
  3. Warsong combat algorithms

User Info: Amuseum

4 years ago#1
I believe I have reverse engineered Warsong's combat. If not completely, at least in spirit. I will use this knowledge to make a Warsong-ese game. in HTML5. blog of game progress at http://www.shenafu.com/wp/tag/conscript/

Actually it’s really simple, but also very exciting, like Warsong was.

When two units engage in combat, this is the order of sequence.
(1) Get the number of shots for each unit, based on HP and unit type.
(2) If both units are alive and at least one unit still has shots left, go into attack phase for each unit that has shots left.

A) For each shot, there are 2 sub rounds:
B) First round, see if defending unit evaded from terrain bonus. If evaded, then round is over.
C) If terrain had no effect, continue to second round.

(i) Attacker tries to hit defender using this formula: 5 < (unit1.attack – unit2.defense) * 5 + 50 < 95
(ii) If miss, try again using restrike chance formula: Math.random() * 100 < unit1.level * RESTRIKE , where RESTRIKE is set at 5%
(iii) Keep trying until the shot hits or restrike chance failed. Higher level units have more chances to get restrike chains.

(3) Combat repeats with Step 2 until both units run of shots or one or both units die.
5-suited Draw Poker for Android http://goo.gl/KhmXi 5-suited Solitaire for Android http://goo.gl/wXwlJ
  1. Boards
  2. Warsong
  3. Warsong combat algorithms

Report Message

Terms of Use Violations:

Etiquette Issues:

Notes (optional; required for "Other"):
Add user to Ignore List after reporting

Topic Sticky

You are not allowed to request a sticky.

Update Topic Flair

You are not allowed to update this topic's flair.

  • Topic Archived